Forward URL data loosing.

dneb2 years ago

Hello, so i was trying to forward incoming data from GPS to third party client. but some how I've noticed a performance issue when forwarding lots of data per second, currently there are around 4k devices sending data to traccar and i can see all the data in the traccar DB, but not all of it makes it to the other end after being forwarded. what should i check for or is there better ways i can forward incoming data to another server?

Anton Tananaev2 years ago

How much data are devices sending?

dneb2 years ago

between 768 bytes and 1280 bytes depending on device types. but at the same time i tried looking at the log and it says Position forwarding failed: 512 pending - Connection refused:

Anton Tananaev2 years ago

Looks like your forwarding endpoint refused connection.

dneb2 years ago

is it possible to forward on multiple endpoints to check?

Anton Tananaev2 years ago

No.

dneb2 years ago

by the way endpoint is localhost Anton.

<entry key='forward.url'>http://localhost/traccar/forward.php</entry>
SwayDev2 years ago

Optimize your script and web server, and after a certain point you may want to consider load balancer and deploying multiple endpoint instances behind the load balancer.

B.Ihaba year ago

Hi @SwayDev, the problem with Load balancer, is the internal cache, when the instance B receive data from the device, only the cache of the instance B are updated, all the other instance need to be refresh to get the new data from the DB, until there in the same Datacenter and under the same network and we're using the multicast.

SwayDeva year ago

The author of this post was referring to their endpoint and the config shared shows it's a php script, so the load balancer suggestion I made was for their endpoint and not Traccar.