This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

[ANY] Server Redirect - A full featured server listing/hoper (v0.2.6, 24/01/2016)


Post New Thread Reply   
 
Thread Tools Display Modes
h3bus
AlliedModders Donor
Join Date: Nov 2013
Old 01-20-2016 , 06:03   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #381

Result is OK (minus the Err which is unsignificant for the issue.
It seems that the code is unable to locate the ":" just before sending teh A2S query, but only when advertising.

It works when refreshing server for !hop listing, but the SQL query is essentially the same. :/

As for the timing, this is due to cooldown, if a server is refreshed by !hop, when the advertise system queries the DB in less than 5 seconds, it uses the data directly from DB instead of sending another A2S query.
h3bus is offline
EMKO
Junior Member
Join Date: Jan 2016
Old 01-20-2016 , 06:07   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #382

Quote:
Originally Posted by h3bus View Post
Result is OK (minus the Err which is unsignificant for the issue.
It seems that the code is unable to locate the ":" just before sending teh A2S query, but only when advertising.

It works when refreshing server for !hop listing, but the SQL query is essentially the same. :/

As for the timing, this is due to cooldown, if a server is refreshed by !hop, when the advertise system queries the DB in less than 5 seconds, it uses the data directly from DB instead of sending another A2S query.
new log using your latest
Attached Files
File Type: log L20160120.log (13.1 KB, 86 views)
EMKO is offline
h3bus
AlliedModders Donor
Join Date: Nov 2013
Old 01-20-2016 , 06:48   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #383

I'm baffled.

Here are the two queries, the first works, the second don't
Code:
SELECT ip, IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS query_ip, (last_refresh BETWEEN NOW() - INTERVAL 5 SECOND AND NOW()) AS up_to_date,hostname,short_hostname,private,players,bots,maxplayers,map,advertise_min_players,advertise_min_slots            FROM `redirect_servers` WHERE ip!='162.248.88.212:27025' AND game='csgo' AND advertise_in_groups REGEXP '[A]'                                                                             ORDER BY `order`
SELECT ip, IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS query_ip, (last_refresh BETWEEN NOW() - INTERVAL 5 SECOND AND NOW()) AS up_to_date,hostname,short_hostname,private,players,bots,maxplayers,map,pw, (expose_pw_for_groups REGEXP '[A]') as expose_pw FROM `redirect_servers` WHERE ip!='162.248.88.212:27025' AND game='csgo' AND show_in_groups      REGEXP '[A]' AND (refresh_failures <= 10 OR last_online >= (NOW() - INTERVAL 20 MINUTE)) ORDER BY `order`
When I say don't work, the following SQL statement:
Code:
IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS  query_ip
Shall return the ip field as query_ip is void.

And we tested it with the query I asked you, it works.
But in the log, I can see that, only with second query the field query_ip is equal to '':
Code:
Querying 162.248.88.212:27045 @""
Thus the plugin tries to query a server with empty IP which inevitably fails.

The query I asked you to run was a bit shortened, can you try with the full query?
Code:
SELECT ip, IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS query_ip, (last_refresh BETWEEN NOW() - INTERVAL 5 SECOND AND NOW()) AS up_to_date,hostname,short_hostname,private,players,bots,maxplayers,map,advertise_min_players,advertise_min_slots FROM `redirect_servers` WHERE ip!='162.248.88.212:27025' AND game='csgo' AND advertise_in_groups REGEXP '[A]' ORDER BY `order`

Last edited by h3bus; 01-20-2016 at 06:50.
h3bus is offline
EMKO
Junior Member
Join Date: Jan 2016
Old 01-20-2016 , 07:12   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #384

Quote:
Originally Posted by h3bus View Post
I'm baffled.

Here are the two queries, the first works, the second don't
Code:
SELECT ip, IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS query_ip, (last_refresh BETWEEN NOW() - INTERVAL 5 SECOND AND NOW()) AS up_to_date,hostname,short_hostname,private,players,bots,maxplayers,map,advertise_min_players,advertise_min_slots            FROM `redirect_servers` WHERE ip!='162.248.88.212:27025' AND game='csgo' AND advertise_in_groups REGEXP '[A]'                                                                             ORDER BY `order`
SELECT ip, IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS query_ip, (last_refresh BETWEEN NOW() - INTERVAL 5 SECOND AND NOW()) AS up_to_date,hostname,short_hostname,private,players,bots,maxplayers,map,pw, (expose_pw_for_groups REGEXP '[A]') as expose_pw FROM `redirect_servers` WHERE ip!='162.248.88.212:27025' AND game='csgo' AND show_in_groups      REGEXP '[A]' AND (refresh_failures <= 10 OR last_online >= (NOW() - INTERVAL 20 MINUTE)) ORDER BY `order`
When I say don't work, the following SQL statement:
Code:
IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS  query_ip
Shall return the ip field as query_ip is void.

And we tested it with the query I asked you, it works.
But in the log, I can see that, only with second query the field query_ip is equal to '':
Code:
Querying 162.248.88.212:27045 @""
Thus the plugin tries to query a server with empty IP which inevitably fails.

The query I asked you to run was a bit shortened, can you try with the full query?
Code:
SELECT ip, IF(query_ip != '' AND query_ip_for_groups REGEXP '[A]', query_ip, ip) AS query_ip, (last_refresh BETWEEN NOW() - INTERVAL 5 SECOND AND NOW()) AS up_to_date,hostname,short_hostname,private,players,bots,maxplayers,map,advertise_min_players,advertise_min_slots FROM `redirect_servers` WHERE ip!='162.248.88.212:27025' AND game='csgo' AND advertise_in_groups REGEXP '[A]' ORDER BY `order`
sorry i took so long the result shows all the info for the request

Code:
"162.248.88.212:27045"	"162.248.88.212:27045"	"0"	"Eazy.GG | Chicago | 1v1 Multi-Arena | Stats + Drops | 128 Tick"	"Chicago 1v1 Arena"	"0"	"0"	"0"	"24"	"am_crashz_dust_v2"	"0"	"0"
this is strange bug are you able to reproduce the same bug?

Last edited by EMKO; 01-20-2016 at 07:19.
EMKO is offline
h3bus
AlliedModders Donor
Join Date: Nov 2013
Old 01-20-2016 , 07:42   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #385

Unfortunately no...

The debug version is running on my server to see if I can catch the bug at least once, but as adverts are working on my servs it's a bit desperate.
h3bus is offline
h3bus
AlliedModders Donor
Join Date: Nov 2013
Old 01-20-2016 , 07:43   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #386

Are you running a stable version of SM? There might be a bug in the DBI extension (although I doubt it)
h3bus is offline
EMKO
Junior Member
Join Date: Jan 2016
Old 01-20-2016 , 07:47   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #387

SourceMod Version Information:
SourceMod Version: 1.7.3-dev+5289
SourcePawn Engine: SourcePawn 1.7, jit-x86 (build 1.7.3-dev+5289)
SourcePawn API: v1 = 4, v2 = 6
Compiled on: Jan 7 2016 17:06:55
Built from: https://github.com/alliedmodders/sou...commit/b543cae
Build ID: 5289:b543cae
http://www.sourcemod.net/

[14] MySQL-DBI (1.7.3-dev+5289): MySQL driver implementation for DBI


what version are you using?

this so strange all the query you gave me work fine and work fine when doing !hop but just not for advertisements?

Last edited by EMKO; 01-20-2016 at 07:51.
EMKO is offline
h3bus
AlliedModders Donor
Join Date: Nov 2013
Old 01-20-2016 , 07:57   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #388

Quote:
Originally Posted by EMKO View Post
this so strange all the query you gave me work fine and work fine when doing !hop but just not for advertisements?
Yes :/

This might still be a plugin bug when fecthing data but again, the code is identical between the two queries.

However I've seen it happening in my logs, I'm investigating further!
h3bus is offline
EMKO
Junior Member
Join Date: Jan 2016
Old 01-20-2016 , 08:02   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #389

Quote:
Originally Posted by h3bus View Post
Yes :/

This might still be a plugin bug when fecthing data but again, the code is identical between the two queries.

However I've seen it happening in my logs, I'm investigating further!
before getting the info it should refresh the data correct? if that's true it does not do this as well, it only refresh the data when i do a !hop
EMKO is offline
h3bus
AlliedModders Donor
Join Date: Nov 2013
Old 01-20-2016 , 09:31   Re: [ANY] Server Redirect - A full featured server listing/hoper (v0.2.5, 29/12/2015)
Reply With Quote #390

Quote:
Originally Posted by EMKO View Post
before getting the info it should refresh the data correct? if that's true it does not do this as well, it only refresh the data when i do a !hop
The sequence is:
- Plugin get the server list to be advertised from DB
- Plugin check if data from current serv is up-to-date in DB
- If no, plugin sends A2S request to server (<= this step fails)
- Upon A2S response, plugin updates server info in DB
h3bus is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:37.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode