Opened 10 years ago

Closed 8 years ago

#813 closed defect (fixed)

Runtime communication error when sending multiple WCPS queries

Reported by: Marcus Sen Owned by: Vlad Merticariu
Priority: major Milestone: 9.2
Component: servercomm Version: development
Keywords: Cc: Peter Baumann
Complexity: Medium

Description

I'm getting a lot of failing queries when I run a few at a time. For example if I run the 3 requests in the attached files at the same time then, usually one of them fails. The tomcat catalina.out file has the error messages below and the rasmgr.044859.log file being used at the time has the error messages following that.

catalina.out extract:

rasj[0] RnpBaseClientComm.communicate: error: rcv io exception: null
 ERROR [15:01:30] PetascopeInterface@425: Runtime error : Internal client exception in class RnpBaseClientComm, method communicate(): (none).
 ERROR [15:01:30] PetascopeInterface@471: Error stack trace:
RuntimeError: Runtime error while processing request: Internal client exception in class RnpBaseClientComm, method communicate(): (none).
        at petascope.PetascopeInterface.doGet(PetascopeInterface.java:426)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:857)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
        at java.lang.Thread.run(Thread.java:701)
Caused by: rasj.RasClientInternalException: Internal client exception in class RnpBaseClientComm, method communicate(): (none).
        at rasj.rnp.RnpBaseClientComm.communicate(RnpBaseClientComm.java:194)
        at rasj.rnp.RnpBaseClientComm.sendRequestGetAnswer(RnpBaseClientComm.java:115)
        at rasj.rnp.RasRNPImplementation.executeQueryRequest(RasRNPImplementation.java:884)
        at rasj.rnp.RasRNPImplementation.queryRequest(RasRNPImplementation.java:403)
        at rasj.odmg.RasOQLQuery.execute(RasOQLQuery.java:254)
        at petascope.util.ras.RasUtil.executeRasqlQuery(RasUtil.java:134)
        at petascope.util.ras.RasUtil.executeRasqlQuery(RasUtil.java:77)
        at petascope.wcps.server.core.ProcessCoveragesRequest.execute(ProcessCoveragesRequest.java:194)
        at petascope.PetascopeInterface.handleProcessCoverages(PetascopeInterface.java:696)
        at petascope.PetascopeInterface.doGet(PetascopeInterface.java:389)
        ... 14 more
 DEBUG [15:01:30] PetascopeInterface@523: Done marshalling Error Report.

rasmgr.nnn.log extract:

rasdaman server process with pid 39220 has terminated.
Error: rasdaman server N1, pid 39220 terminated illegally, reason: uncaught signal 9
[2014-07-03 15:01:30] starting server N1, executable /usr/bin/rasserver; pid 40409...

I am using v9.0.3 RPMs

Attachments (8)

runXslice.sh (2.3 KB ) - added by Marcus Sen 10 years ago.
runYslice.sh (2.3 KB ) - added by Marcus Sen 10 years ago.
runZslice.sh (2.3 KB ) - added by Marcus Sen 10 years ago.
rasmgr.044859.log (3.1 KB ) - added by Marcus Sen 10 years ago.
Edited rasmgr log showing server termination
N1.032815.log (3.6 KB ) - added by Marcus Sen 10 years ago.
Edited rasserver log showing successful query
N2.010530.log (3.7 KB ) - added by Marcus Sen 10 years ago.
Edited rasserver log showing failed query
N3.010559.log (3.7 KB ) - added by Marcus Sen 10 years ago.
Edited rasserver log showing successful query
test.sh (1.2 KB ) - added by Bang Pham Huu 8 years ago.
script to test multiple WCPS queries

Download all attachments as: .zip

Change History (25)

by Marcus Sen, 10 years ago

Attachment: runXslice.sh added

by Marcus Sen, 10 years ago

Attachment: runYslice.sh added

by Marcus Sen, 10 years ago

Attachment: runZslice.sh added

comment:1 by Dimitar Misev, 10 years ago

Component: undecidedrasserver
Milestone: 9.0.x

comment:2 by Dimitar Misev, 10 years ago

Owner: changed from Dimitar Misev to Vlad Merticariu
Status: newassigned

Vlad can you look at this as well, it seems again related to the case statement?

Marcus, can you please post the rasserver (N*) log as well (including the rasql query)?

Here's one of the WCPS queries

http://earthserver.bgs.ac.uk/rasdaman/ows?query=for data in (tno_geotop_lithostrat)return encode(slice( switch case data = 0 return struct {red: (char) 0; green: (char) 0; blue: (char) 0} case data = 1 return struct {red: (char) 200; green: (char) 200; blue: (char) 200} case data = 7 return struct {red: (char) 255; green: (char) 0; blue: (char) 0} case data = 9 return struct {red: (char) 255; green: (char) 255; blue: (char) 255} case data = 14 return struct {red: (char) 149; green: (char) 0; blue: (char) 148} case data = 16 return struct {red: (char) 254; green: (char) 168; blue: (char) 0} case data = 20 return struct {red: (char) 23; green: (char) 250; blue: (char) 255} case data = 26 return struct {red: (char) 255; green: (char) 255; blue: (char) 0} case data = 33 return struct {red: (char) 255; green: (char) 235; blue: (char) 0} case data = 34 return struct {red: (char) 147; green: (char) 112; blue: (char) 219} case data = 39 return struct {red: (char) 176; green: (char) 48; blue: (char) 96} case data = 47 return struct {red: (char) 255; green: (char) 127; blue: (char) 80} case data = 48 return struct {red: (char) 231; green: (char) 142; blue: (char) 79} case data = 49 return struct {red: (char) 178; green: (char) 178; blue: (char) 178} case data = 59 return struct {red: (char) 255; green: (char) 165; blue: (char) 0} case data = 62 return struct {red: (char) 107; green: (char) 142; blue: (char) 35} default return struct {red: (char) 0; green: (char) 0; blue: (char) 255} , X(204000)),"png", "nodata=0,0,0" )&

comment:3 by Dimitar Misev, 10 years ago

Cc: Peter Baumann added

by Marcus Sen, 10 years ago

Attachment: rasmgr.044859.log added

Edited rasmgr log showing server termination

by Marcus Sen, 10 years ago

Attachment: N1.032815.log added

Edited rasserver log showing successful query

by Marcus Sen, 10 years ago

Attachment: N2.010530.log added

Edited rasserver log showing failed query

by Marcus Sen, 10 years ago

Attachment: N3.010559.log added

Edited rasserver log showing successful query

comment:4 by Marcus Sen, 10 years ago

I have added the log files (edited just to show the relevant parts) for a run where I sent X, Y and Z slice queries simultaneously. In this case the queries served by N1 and N3 returned successfully and the query served by N2 failed.

comment:5 by Dimitar Misev, 10 years ago

Vlad, what's the status of this ticket?

comment:6 by Vlad Merticariu, 10 years ago

This is a communication problem, I am waiting for the new protocol to close it.

comment:7 by Dimitar Misev, 10 years ago

Component: rasserverservercomm
Priority: blockermajor

comment:8 by Dimitar Misev, 9 years ago

Resolution: wontfix
Status: assignedclosed

wontfix in RNP, will be fixed with the new protocol in 9.1

comment:9 by Marcus Sen, 9 years ago

Resolution: wontfix
Status: closedreopened

comment:10 by Marcus Sen, 9 years ago

If tne new protocol does not have this problem then this bug can be closed when the behaviour is tested with that. It isn't appropriate to close it now as it is a legitimate problem that needs fixing.

comment:11 by Dimitar Misev, 9 years ago

The bug was opened for the current protocol, and the resolution is that it will not be fixed in the current protocol (9.0).

We can wait a bit until it's tested it with the new protocol though.

comment:12 by Marcus Sen, 9 years ago

No, the issue was opened by me to report the fact that when multiple queries are sent at once then often one or more would fail. The resolution will be when multiple queries cas be sent at once and they all succeed. How that is achieved (e.g. by replacing the current protocol with a newer protocol) is up to you. If you have a version of the software which uses your new protocol and can cope with multiple queries sent at once then you can close the bug reporting the fix version and I can check it myself later.

comment:13 by Dimitar Misev, 9 years ago

Milestone: 9.0.x9.1

comment:14 by Dimitar Misev, 9 years ago

Milestone: 9.19.2

in reply to:  12 comment:15 by Bang Pham Huu, 8 years ago

Replying to mase:

No, the issue was opened by me to report the fact that when multiple queries are sent at once then often one or more would fail. The resolution will be when multiple queries cas be sent at once and they all succeed. How that is achieved (e.g. by replacing the current protocol with a newer protocol) is up to you. If you have a version of the software which uses your new protocol and can cope with multiple queries sent at once then you can close the bug reporting the fix version and I can check it myself later.

Please, test the queries by yourself with the new Rasnet communication protocol. I also tried your queries as don't want to to waste your time to confirm but it has problem in translating WCPS syntax to Rasql in your server. Then, you can adjust it to run in your system, before we can close the ticket.

This is the query in runXslice.sh.

http://earthserver.bgs.ac.uk/rasdaman/ows?query=for data in (tno_geotop_lithostrat)return encode(slice( switch case data = 0 return struct {red: (char) 0; green: (char) 0; blue: (char) 0} case data = 1 return struct {red: (char) 200; green: (char) 200; blue: (char) 200} case data = 7 return struct {red: (char) 255; green: (char) 0; blue: (char) 0} case data = 9 return struct {red: (char) 255; green: (char) 255; blue: (char) 255} case data = 14 return struct {red: (char) 149; green: (char) 0; blue: (char) 148} case data = 16 return struct {red: (char) 254; green: (char) 168; blue: (char) 0} case data = 20 return struct {red: (char) 23; green: (char) 250; blue: (char) 255} case data = 26 return struct {red: (char) 255; green: (char) 255; blue: (char) 0} case data = 33 return struct {red: (char) 255; green: (char) 235; blue: (char) 0} case data = 34 return struct {red: (char) 147; green: (char) 112; blue: (char) 219} case data = 39 return struct {red: (char) 176; green: (char) 48; blue: (char) 96} case data = 47 return struct {red: (char) 255; green: (char) 127; blue: (char) 80} case data = 48 return struct {red: (char) 231; green: (char) 142; blue: (char) 79} case data = 49 return struct {red: (char) 178; green: (char) 178; blue: (char) 178} case data = 59 return struct {red: (char) 255; green: (char) 165; blue: (char) 0} case data = 62 return struct {red: (char) 107; green: (char) 142; blue: (char) 35} default return struct {red: (char) 0; green: (char) 0; blue: (char) 255} , X(204000)),"png", "nodata=0,0,0" )
Runtime error while processing request: Error translating parsed abstract WCPS query to XML format.

by Bang Pham Huu, 8 years ago

Attachment: test.sh added

script to test multiple WCPS queries

comment:16 by Bang Pham Huu, 8 years ago

All 3 old scripts have same WCPS query, except the slicing axis, which will return a 2D coverage, size (200 x 300) so I used mr covage as a test example and made a test.sh script http://rasdaman.org/attachment/ticket/813/test.sh to reproduce the author's queries. The script proof that rasdaman with rasnet protocol can accept multiple WCPS queries without error as the previous version, so we can close this ticket here.

comment:17 by Bang Pham Huu, 8 years ago

Resolution: fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.