[MonetDB-users] XRPC problem: too many parameters
Hi, I caught an error (see attached file) at the remote method invocation of XRPC. While I'm not sure whether my query is correct or not, is there imitation of parameters in XRPC? The query and dataset used in the evaluation are put on here. http://db-www.naist.jp/~makoto-y/tmp/xrpc.tgz Thanks, Makoto YUI P.S. To: list-admin please ignore previous mail from wrong address MAPI = monetdb@localhost:50000 QUERY = import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq"; (: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result; (: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp"; let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit ERROR = !WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed. MAPI = monetdb@localhost:50000 QUERY = import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq"; (: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result; (: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp"; let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit ERROR = !ERROR: doLoopLiftedRPC: execution failed at all destinations mapi_query_part:1705:import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq"; (: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result; (: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp"; let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit where $hit/Hit_num = 1 and $hit/Hit_hsps/Hsp/Hsp_evalue/text() <= 1.0e-8 return $e), $uniprot_entry := (for $e in $blast-uniprot/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit where $hit/Hit_num = 1 and $hit/Hit_hsps/Hsp/Hsp_evalue/text() <= 1.0e-8 return $e) where $gb_entry/BlastOutput_query-def/text() = $uniprot_entry/BlastOutput_query-def/text() return <result> { let $gb-hit := $gb_entry/BlastOutput_iterations/Iteration/Iteration_hits/Hit, $gb-key := $gb-hit/Hit_gb/text() return let $genbank-remote-entries := execute at {$remote-endpoint} { test:q1($gb-key) } for $remote_entry at $pos in $genbank-remote-entries let $gb_definition := $remote_entry/INSDSeq_definition, $gb_feature := $remote_entry/INSDSeq_feature-table/INSDFeature, $blast_evalue := $gb-hit[Hit_gb/text() = $remote_entry/INSDSeq_accession-version/text()]/Hit_hsps/Hsp/Hsp_evalue return <genbank num="{ $pos }">{ $blast_evalue, $gb_definition, $gb_feature } </genbank> } </result> fetch next block: start at:2 got next block: length:269 text:XRPC_Client_Serialisation: 626 microsec !WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed. !ERROR: doLoopLiftedRPC: execution failed at all destinations got complete block: text:XRPC_Client_Serialisation: 626 microsec !WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed. !ERROR: doLoopLiftedRPC: execution failed at all destinations read_line:XRPC_Client_Serialisation: 626 microsec allocating new result set XRPC_Client_Serialisation: 626 microsec got complete block: text:!WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed. !ERROR: doLoopLiftedRPC: execution failed at all destinations read_line:!WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" allocating new result set got complete block: text:!ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed. !ERROR: doLoopLiftedRPC: execution failed at all destinations read_line:!ERROR: CMDhttp_post: too many parameters. got complete block: text:!ERROR: CMDhttp_post: operation failed. !ERROR: doLoopLiftedRPC: execution failed at all destinations read_line:!ERROR: CMDhttp_post: operation failed. got complete block: text: !ERROR: doLoopLiftedRPC: execution failed at all destinations read_line: closing result set got complete block: text:!ERROR: doLoopLiftedRPC: execution failed at all destinations read_line:!ERROR: doLoopLiftedRPC: execution failed at all destinations allocating new result set fetch next block: start at:271 got next block: length:0 text: got complete block: text: read_line: closing result set closing result set Timer 1014.527 msec
Hello Makoto, First of all, thanks for your interest in MonetDB. On Wed, May 16, 2007 at 12:16:39PM +0900, Makoto YUI wrote:
Hi,
I caught an error (see attached file) at the remote method invocation of XRPC.
While I'm not sure whether my query is correct or not, is there imitation of parameters in XRPC?
I can't see any problem in your query in a quick scan. There is indeed a limitation of the maximal number of parameters, which is only nr_iterations * 32. I should consider enlarging this limit and/or make it more flexible. An important information is missing in your e-mail. Can you please tell us which version of MonetDB/XQuery you are using?
The query and dataset used in the evaluation are put on here. http://db-www.naist.jp/~makoto-y/tmp/xrpc.tgz
Thanks! This will be very useful for debugging. Regards, Jennie Zhang
Hello Jennie, My test environment is MonetDB 4.16 on SuSE linux 10.2. I've used latest (nightly) stable RPMs then. $ rpm -aq | grep -i monetdb MonetDB-1.16.3-1_SuSE9.3.oid32 MonetDB4-XQuery-0.16.3-1_SuSE9.3.oid32 MonetDB4-server-4.16.3-1_SuSE9.3.oid32 MonetDB-client-1.16.3-1_SuSE9.3.oid32 Ying Zhang wrote:
I can't see any problem in your query in a quick scan. There is indeed a limitation of the maximal number of parameters, which is only nr_iterations * 32. I should consider enlarging this limit and/or make it more flexible.
BTW, what is meant by this 'nr_iterations'? Thanks, Makoto
Hello Makoto,
My test environment is MonetDB 4.16 on SuSE linux 10.2. I've used latest (nightly) stable RPMs then.
$ rpm -aq | grep -i monetdb
MonetDB-1.16.3-1_SuSE9.3.oid32 MonetDB4-XQuery-0.16.3-1_SuSE9.3.oid32 MonetDB4-server-4.16.3-1_SuSE9.3.oid32 MonetDB-client-1.16.3-1_SuSE9.3.oid32
Thank you very much for the infomation. I will have a look at the limited number of parameters problem a.s.a.p.!
Ying Zhang wrote:
I can't see any problem in your query in a quick scan. There is indeed a limitation of the maximal number of parameters, which is only nr_iterations * 32. I should consider enlarging this limit and/or make it more flexible.
BTW, what is meant by this 'nr_iterations'?
With 'nr_iterations' I mean that multiple iterations can be included in one XRPC (request/response) message. This typically happens if you use "execute at" in a for-loop. Regards, Jennie
Thanks,
Makoto
Hello Makoto, Sorry for the delay, but I have finally removed the limitation on the maximum number of parameters allowed. I hope it still helps. Your query now returns results, instead of error. Although I don't know what the expected output should it, I think it looks quite OK. My changes have just been checked in into the CVS HEAD branch. It should be available in the next nightly build. With kind regards, Jennie On Wed, May 16, 2007 at 12:16:39PM +0900, Makoto YUI wrote:
Hi,
I caught an error (see attached file) at the remote method invocation of XRPC.
While I'm not sure whether my query is correct or not, is there imitation of parameters in XRPC?
The query and dataset used in the evaluation are put on here. http://db-www.naist.jp/~makoto-y/tmp/xrpc.tgz
Thanks,
Makoto YUI
P.S. To: list-admin please ignore previous mail from wrong address
MAPI = monetdb@localhost:50000 QUERY = import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq";
(: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result;
(: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp";
let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit
ERROR = !WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed. MAPI = monetdb@localhost:50000 QUERY = import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq";
(: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result;
(: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp";
let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit
ERROR = !ERROR: doLoopLiftedRPC: execution failed at all destinations mapi_query_part:1705:import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq";
(: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result;
(: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp";
let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit where $hit/Hit_num = 1 and $hit/Hit_hsps/Hsp/Hsp_evalue/text() <= 1.0e-8 return $e), $uniprot_entry := (for $e in $blast-uniprot/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit where $hit/Hit_num = 1 and $hit/Hit_hsps/Hsp/Hsp_evalue/text() <= 1.0e-8 return $e) where $gb_entry/BlastOutput_query-def/text() = $uniprot_entry/BlastOutput_query-def/text() return <result> { let $gb-hit := $gb_entry/BlastOutput_iterations/Iteration/Iteration_hits/Hit, $gb-key := $gb-hit/Hit_gb/text() return let $genbank-remote-entries := execute at {$remote-endpoint} { test:q1($gb-key) } for $remote_entry at $pos in $genbank-remote-entries let $gb_definition := $remote_entry/INSDSeq_definition, $gb_feature := $remote_entry/INSDSeq_feature-table/INSDFeature, $blast_evalue := $gb-hit[Hit_gb/text() = $remote_entry/INSDSeq_accession-version/text()]/Hit_hsps/Hsp/Hsp_evalue return <genbank num="{ $pos }">{ $blast_evalue, $gb_definition, $gb_feature } </genbank> } </result>
fetch next block: start at:2 got next block: length:269 text:XRPC_Client_Serialisation: 626 microsec !WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed.
!ERROR: doLoopLiftedRPC: execution failed at all destinations
got complete block: text:XRPC_Client_Serialisation: 626 microsec !WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed.
!ERROR: doLoopLiftedRPC: execution failed at all destinations
read_line:XRPC_Client_Serialisation: 626 microsec allocating new result set XRPC_Client_Serialisation: 626 microsec got complete block: text:!WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" !ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed.
!ERROR: doLoopLiftedRPC: execution failed at all destinations
read_line:!WARNING: doLoopLiftedRPC: error occurred during RPC call to "xanadu.naist.jp" allocating new result set got complete block: text:!ERROR: CMDhttp_post: too many parameters. !ERROR: CMDhttp_post: operation failed.
!ERROR: doLoopLiftedRPC: execution failed at all destinations
read_line:!ERROR: CMDhttp_post: too many parameters. got complete block: text:!ERROR: CMDhttp_post: operation failed.
!ERROR: doLoopLiftedRPC: execution failed at all destinations
read_line:!ERROR: CMDhttp_post: operation failed. got complete block: text: !ERROR: doLoopLiftedRPC: execution failed at all destinations
read_line: closing result set
got complete block: text:!ERROR: doLoopLiftedRPC: execution failed at all destinations
read_line:!ERROR: doLoopLiftedRPC: execution failed at all destinations allocating new result set fetch next block: start at:271 got next block: length:0 text: got complete block: text:
read_line: closing result set closing result set Timer 1014.527 msec
------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
Hello Jennie, Thank you for correspondence. I've tried with the lastest current RPMs[20070602], but I unfortunately got another errors (trace is attached). Could you check it? thanks, Makoto [20070602] http://monetdb.cwi.nl/testing/projects/monetdb/Current/.DailyBuilds./2007060... On 6/2/2007 1:39 AM, Ying Zhang wrote:
Hello Makoto,
Sorry for the delay, but I have finally removed the limitation on the maximum number of parameters allowed. I hope it still helps. Your query now returns results, instead of error. Although I don't know what the expected output should it, I think it looks quite OK.
My changes have just been checked in into the CVS HEAD branch. It should be available in the next nightly build.
MAPI = monetdb@localhost:50000 QUERY = import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq"; (: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result; (: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp"; let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit ERROR = !ERROR: interpret_params: reverse(param 1): invalid BAT. !ERROR: interpret_params: reverse(param 1): evaluation error. !ERROR: interpret_params: insert(param 3): evaluation error. !ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. mapi_query_part:1714:import module namespace test = "xrpc-test-function" at "/usr/share/MonetDB/xrpc/export/xrpc-mod.xq"; (: local database :) declare variable $blast-gb := fn:doc("blast-gb.xml")/result; declare variable $blast-uniprot := fn:doc("blast-uniprot.xml")/result; (: remote basebase :) declare variable $remote-endpoint := "xanadu.naist.jp"; let $gb_entry := (for $e in $blast-gb/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit where $hit/Hit_num = 1 and $hit/Hit_hsps/Hsp/Hsp_evalue/text() <= 1.0e-8 return $e), $uniprot_entry := (for $e in $blast-uniprot/BlastOutput let $hit := $e/BlastOutput_iterations/Iteration/Iteration_hits/Hit where $hit/Hit_num = 1 and $hit/Hit_hsps/Hsp/Hsp_evalue/text() <= 1.0e-8 return $e) where $gb_entry/BlastOutput_query-def/text() = $uniprot_entry/BlastOutput_query-def/text() return <result> { let $gb-hit := $gb_entry/BlastOutput_iterations/Iteration/Iteration_hits/Hit, $gb-key := fn:data($gb-hit/Hit_gb/text()) return let $genbank-remote-entries := execute at {$remote-endpoint} { test:q1($gb-key) } for $remote_entry at $pos in $genbank-remote-entries let $gb_definition := $remote_entry/INSDSeq_definition, $gb_feature := $remote_entry/INSDSeq_feature-table/INSDFeature, $blast_evalue := $gb-hit[Hit_gb/text() = $remote_entry/INSDSeq_accession-version/text()]/Hit_hsps/Hsp/Hsp_evalue return <genbank num="{ $pos }">{ $blast_evalue, $gb_definition, $gb_feature } </genbank> } </result> fetch next block: start at:0 got next block: length:248 text:!ERROR: interpret_params: reverse(param 1): invalid BAT. !ERROR: interpret_params: reverse(param 1): evaluation error. !ERROR: interpret_params: insert(param 3): evaluation error. !ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. got complete block: text:!ERROR: interpret_params: reverse(param 1): invalid BAT. !ERROR: interpret_params: reverse(param 1): evaluation error. !ERROR: interpret_params: insert(param 3): evaluation error. !ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. read_line:!ERROR: interpret_params: reverse(param 1): invalid BAT. allocating new result set got complete block: text:!ERROR: interpret_params: reverse(param 1): evaluation error. !ERROR: interpret_params: insert(param 3): evaluation error. !ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. read_line:!ERROR: interpret_params: reverse(param 1): evaluation error. got complete block: text:!ERROR: interpret_params: insert(param 3): evaluation error. !ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. read_line:!ERROR: interpret_params: insert(param 3): evaluation error. got complete block: text:!ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. read_line:!ERROR: interpret_params: leftfetchjoin(param 2): evaluation error. fetch next block: start at:248 got next block: length:0 text: got complete block: text: read_line: closing result set
Hello Makoto,
let $gb-hit := $gb_entry/BlastOutput_iterations/Iteration/Iteration_hits/Hit, $gb-key := $gb-hit/Hit_gb/text() return let $genbank-remote-entries := execute at {$remote-endpoint} { test:q1($gb-key) }
I forgot to say that you need to wrap "$gb-hit/Hit_gb/text()" into the fn:data() function before those values can be passed to "test:q1". This is a restriction of the current implementation of XRPC. The values you get by selecting the "text()" child node are of the type "untypedAtomic". XRPC currently does not cast eash untypedAtomic to the expected atomic type, hence, you need to add a fn:data() to do this. I will add this cast later in XRPC's implementation. Sorry for the inconvenience! Jennie
participants (3)
-
Makoto YUI
-
Makoto YUI
-
Ying Zhang