Fail to get summary report from API but from traccar web its working

Parth7 years ago

Hello Anton,

I am facing the issue regarding fail to get summary details for a device and get below error logs. But same summary is working fine from Traccar web.

Below are the error logs:

2017-11-09 10:06:32  WARN: Can not construct instance of org.traccar.model.Network: no int/Int-argument constructor/factory method to deserialize from Number value (0)
 at [Source: 0; line: 1, column: 1] - JsonMappingException (... < QueryBuilder:402 < *:453 < DataManager:288 < Summary:42 < ...)
2017-11-09 10:06:32  WARN: Can not construct instance of org.traccar.model.Network: no int/Int-argument constructor/factory method to deserialize from Number value (0)
 at [Source: 0; line: 1, column: 1] - JsonMappingException (... < QueryBuilder:402 < *:453 < DataManager:288 < Summary:42 < ...)
2017-11-09 10:06:32  WARN: Can not construct instance of org.traccar.model.Network: no int/Int-argument constructor/factory method to deserialize from Number value (0)
...
 at [Source: 0; line: 1, column: 1] - JsonMappingException (... < QueryBuilder:402 < *:453 < DataManager:288 < Summary:42 < ...)
2017-11-09 10:06:32  WARN: Can not construct instance of org.traccar.model.Network: no int/Int-argument constructor/factory method to deserialize..

Thanks.

Anton Tananaev7 years ago

You have some invalid data in your database.

Parth7 years ago

Thanks for the response.

But how can identify what is wrong in DB? It looks all good in mysql. Can you guide me?

Anton Tananaev7 years ago

I don't know what's wrong, but it seems like you have some invalid values in network column.

Parth7 years ago
FINEST|2311/0|Service traccar|17-11-20 07:33:28|[qtp848958019-63] WARN org.eclipse.jetty.servlet.ServletHandler -
FINEST|2311/0|Service traccar|17-11-20 07:33:28|javax.servlet.ServletException: org.glassfish.jersey.server.ContainerException: java.lang.OutOfMemoryError: GC overhead limit exceeded
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:489)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:427)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:388)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:341)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:228)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:587)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:221)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1127)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:52)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.Server.handle(Server.java:499)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.io.AbstractConnection$2.run(AbstractConnection.java:544)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at java.lang.Thread.run(Thread.java:748)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|Caused by: org.glassfish.jersey.server.ContainerException: java.lang.OutOfMemoryError: GC overhead limit exceeded
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.internal.ResponseWriter.rethrow(ResponseWriter.java:278)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.internal.ResponseWriter.failure(ResponseWriter.java:260)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.server.ServerRuntime$Responder.process(ServerRuntime.java:509)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.server.ServerRuntime$2.run(ServerRuntime.java:334)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.internal.Errors.process(Errors.java:267)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:305)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:1154)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:473)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        ... 21 more
FINEST|2311/0|Service traccar|17-11-20 07:33:28|Caused by: java.lang.OutOfMemoryError: GC overhead limit exceeded
FINEST|2311/0|Service traccar|17-11-20 07:33:28|[qtp848958019-63] WARN org.eclipse.jetty.server.HttpChannel - /api/reports/summary?deviceId=173&from=2015-01-01T00%3A00%3A00Z&to=2017-11-20T13%3A02%3A19Z
FINEST|2311/0|Service traccar|17-11-20 07:33:28|javax.servlet.ServletException: org.glassfish.jersey.server.ContainerException: java.lang.OutOfMemoryError: GC overhead limit exceeded
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:489)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:427)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:388)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:341)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:228)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:587)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:221)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1127)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:52)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.server.Server.handle(Server.java:499)
FINEST|2311/0|Service traccar|17-11-20 07:33:28|        at org.eclipse.jetty.s...
Anton Tananaev7 years ago

Looks like you have low memory.

Parth7 years ago
Anton Tananaev7 years ago

You need to pass Accept header with format that you expect.

Parth7 years ago

Thank you so much and i want to know there are any option to add total engine hours like totalkm .

Anton Tananaev7 years ago

Not at the moment.