XML Parsing Error: no element found

Added by SirCotare about 5 years ago

Hiho!

Once again it's me, but this time not really reporting a bug but more checking something out:

We are using a cronjob on the Ryzom Armory (www.3025-game.de/ryzom/) to load and cache every known character and guild every hour (once their API caching time has expired). In addition to that we also load things like realmstatus or ingame time.

Now, a few weeks ago, we startet to experience a strange bug:
Using PHP's CURL function, some API scripts startet to return empty. There was no code change or changes on the server that might have caused that (I checked). Mainly the character.php and the guild.php are acting strangely while the others still work. Reading the XML with a browser or on an other server works too.

My questions now would be:
Did you change something that might cause that bug? Did you lock out the Armory server (88.198.105.251) from those API scripts? I'm really desperate, since I can't think of any other reason why it suddely stopped to work on just the one server... I might be wrong of course :)

Please tell me if there is any reason from your side, that could be responsible for that bug. Many thanks in advance!

Yours Cotare


Replies (4)

RE: XML Parsing Error: no element found - Added by nimetu about 5 years ago

did you use too many 'bad key's ? api server does not like that ;-) speaking from experience lol.

my cron now only pulls one key every 3 sec and for unexpected errors extends the key expiry for random 1 to 2 hour. cron itself runs every 5 min and uses lock file so multiple instances will not fire.

RE: XML Parsing Error: no element found - Added by SirCotare about 5 years ago

Interesting thought, thx Nimetu! That might be... I disabled character removal (since the API had the bug which reportet "char not found" thought that was not the case).

My cron here runs every 10 min, collecting expired XML sheets. It skips invalid reponses (so the next time the cron runs, it will query again). I also prevent multiple instances.

I'll add a backup function and reenable character removal, so in the future there should no longer be extensive invalid key queries.... I wonder, since the API server does not like me now... how can I change that? I'm currently forwarding the API to the Armory server with another server... but that's not a permanent solution!

yours Cotare

RE: XML Parsing Error: no element found - Added by vl about 5 years ago

Indeed, you required too much bad key so the system auto ban your server (to avoid brute forcing api keys)

I removed the ban so it should works again.

RE: XML Parsing Error: no element found - Added by SirCotare about 5 years ago

Many thanks for the fast help :)

I adapted the system now, so it should no longer re- and re-query the same invalid api keys.

yours Cotare

(1-4/4)