Maybe there are other solutions... For example i try to start my traccar from IDEA and try to connect to server through mobile by address something like 192.168.1.2:8082?? And if i correctly understood when server get my lat and lon , it make request to geocoder server. So I try to debug this moment, so maybe i will see some problem with URL or parsing. There are something right in my words??
That makes sense. Debugging it should help.
But i don't how i can do next thing. I have idea with traccar at first computer. But my traccar server and nominatim at another one. So how i can connect my mobile to server in one network. Maybe something like 192.168.1.6:8082????
Something like that. Note that if you are talking about Traccar Client, then the port should be 5055.
I put in debug.xml necessary settings.But i don't know where i should put break point:) So I put it in JsonReverseGeocoder
Context.getAsyncHttpClient().prepareGet(String.format(url, latitude, longitude))
.execute(new AsyncCompletionHandler() {
@Override
public Object onCompleted(Response response) throws Exception {
try (JsonReader reader = Json.createReader(response.getResponseBodyAsStream())) {
Address address = parseAddress(reader.readObject());
if (address != null) {
String formattedAddress = format.format(address);
if (cache != null) {
cache.put(new AbstractMap.SimpleImmutableEntry<>(latitude, longitude), formattedAddress);
}
callback.onResult(formattedAddress);
} else {
callback.onResult(null);
}
}
return null;
}
at this line
Address address = parseAddress(reader.readObject());
and also i put breakpoint in NominatimReverseGeocoder. But I don't go to this breakpoint after parseAddress from JsonReverseGeocoder. In my config properties I have nominatim and my external ip...
So there is one problem which put me in a deadlock. I can't connect to my external my ip if I'm in same network...
Probably because parsing JSON fails. You should look at the response content.
I put breakpoint at all geocoder classes where is implemented parseAddress...But when try to continue debug from
this lineAddress address = parseAddress(reader.readObject());
I couldn't stopped at one of this geocoder....
So i get next error javax.json.stream.JsonParsingException: Unexpected char 60 at (line no=1, column no=1, offset=0)
You have to check what's coming from the geocoder. Obviously it won't get into "parseAddress" method if JSON is invalid and it fails before that.
http://joxi.ru/D2PKeyJSpwdzem
It's all that i have
You should probably find a way to display it in a human readable text format.
It's not possible. As result i have byte array.So i don't know protocol which define it
Everything is possible. You can either modify the code or use "evaluate expression" feature in IDEA.
So i use evaluate expression, you can see it at screen.But i have something like
0 = 60
1 = 104
2 = 116
....
With length 691. So when i try to readObject from reader i got an error that i sent you
I already answered that question. I am using different URL. Everything else is obviously the same.