[Monetdb-developers] strange Mtest + Mapi problem

Jan Flokstra flokstra at cs.utwente.nl
Thu Jan 18 13:33:45 CET 2007


On Thursday 18 January 2007 12:57, Stefan Manegold wrote:
> On Thu, Jan 18, 2007 at 12:04:17PM +0100, Jan Flokstra wrote:
> > Stefan,
> >
> > Thanx for the help. I ran loaded() and sigs() in the failed state and
> > noticed the module was loaded but some functions were missing from the
> > sigs() list. When I added help through ADDHELP() they were listed in
> > sigs() and could also be executed. Without the ADDHELP the functions
> > cannot be executed in the failed state.
> > BUT now things get even weirder: the function tj_setCollName() accesses a
> > module variable collName and when it runs with the help of ADDHELP in the
> > failed state it does not know the collName module variable.
> > Does this ring a bell???
>
> nope. sorry.
>
> does it work in case you load module pftijah on the server before starting
> the client listener (instead of loading module pftijah only in the client
> session)?
>

Hi Stefan,

I modified the Mtest.py script (only because you asked:-)

Line 2162:
Srvr = '%s --dbinit="%s module(pathfinder);module(pftijah);"

So now the Mtest Mserver starts up with pftijah loaded. Now it works fine! But 
I think it should also work in the other cases and we cannot always load 
pftijah if people did not compile it,

Jan.
[PS. how do I ADDHELP() to a module variable:-)]

> Stefan
>
> > JanF.
> >
> > On Thursday 18 January 2007 11:31, Stefan Manegold wrote:
> > > Jan,
> > >
> > > I did the following simple test:
> > >
> > > Shell 1 (server)
> > > ========
> > > $ Mserver --dbinit='module(mapi); mil_start();'
> > > --------
> > > # Monet Database Server V4.15.0
> > > # Copyright (c) 1993-2007, CWI. All rights reserved.
> > > # Compiled for x86_64-redhat-linux-gnu/64bit with 64bit OIDs;
> > > dynamically linked. # Visit http://monetdb.cwi.nl/ for further
> > > information. MonetDB>loaded();
> > > #---------------------------------#
> > > # module                usage_count       # name
> > > # str           int               # type
> > > #---------------------------------#
> > > [ "algebra",      1               ]
> > > [ "arith",        1               ]
> > > [ "bat",          1               ]
> > > [ "builtin",      1               ]
> > > [ "constant",     1               ]
> > > [ "main",         1               ]
> > > [ "mapi",         1               ]
> > > [ "str",          1               ]
> > > [ "streams",      1               ]
> > > [ "sys",          1               ]
> > > [ "trans",        1               ]
> > > MonetDB>
> > > ========
> > >
> > > Shell 2 (client)
> > > ========
> > > $ MapiClient
> > > --------
> > > mil>module(pftijah);
> > > MAPI  = monetdb at localhost:50000
> > > QUERY = module(pftijah);
> > > ERROR = !ERROR: pathfinder module must be loaded in Mserver console
> > > first. mil>
> > > ========
> > >
> > > and then
> > >
> > > Shell 1 (server)
> > > ========
> > > $ Mserver --dbinit='module(pathfinder); mil_start();'
> > > --------
> > > # Monet Database Server V4.15.0
> > > # Copyright (c) 1993-2007, CWI. All rights reserved.
> > > # Compiled for x86_64-redhat-linux-gnu/64bit with 64bit OIDs;
> > > dynamically linked. # Visit http://monetdb.cwi.nl/ for further
> > > information. MonetDB>loaded();
> > > #---------------------------------#
> > > # module                usage_count       # name
> > > # str           int               # type
> > > #---------------------------------#
> > > [ "aggrX3",       2               ]
> > > [ "alarm",        3               ]
> > > [ "algebra",      1               ]
> > > [ "arith",        1               ]
> > > [ "bat",          1               ]
> > > [ "bat_arith",    2               ]
> > > [ "builtin",      1               ]
> > > [ "constant",     1               ]
> > > [ "lock",         3               ]
> > > [ "logger",       3               ]
> > > [ "main",         1               ]
> > > [ "malalgebra",   3               ]
> > > [ "mapi",         1               ]
> > > [ "mmath",        2               ]
> > > [ "monettime",    3               ]
> > > [ "pathfinder",   1               ]
> > > [ "pcre",         2               ]
> > > [ "pf_support",   2               ]
> > > [ "str",          1               ]
> > > [ "streams",      3               ]
> > > [ "sys",          1               ]
> > > [ "trans",        1               ]
> > > [ "xtables",      2               ]
> > > MonetDB>
> > > ========
> > >
> > > Shell 2 (client)
> > > ========
> > > $ MapiClient
> > > --------
> > > mil>module(pftijah);
> > > mil>sigs("pftijah");
> > > #----------------------------------------------------------------------
> > >----
> > > -----------------------------------------------------------------------
> > >----- -------------------# # signature
> > >
> > >                                       # name # str
> > >
> > >                                                                # type
> > > #----------------------------------------------------------------------
> > >----
> > > -----------------------------------------------------------------------
> > >----- -------------------# [ "_tj_throw2collection(BAT[oid,BAT],
> > > BAT[oid,BAT], str, str) : void"
> > >                                           ] [
> > > "_tj_throw2collection_index(BAT[oid,BAT], str) : void"
> > >
> > >                 ] [ "indexfetchjoin(BAT[any,oid], BAT[void,oid],
> > > BAT[void,oid]) : BAT[void,oid]"
> > >                                                ] [
> > > "mergeindex(BAT[oid,oid], BAT[void,oid], BAT[void,oid], int) :
> > > BAT[void,BAT]"
> > >                              ] [ "mergeindex_old(BAT[any,oid],
> > > BAT[void,oid], BAT[void,oid], BAT[void,oid]) : BAT[oid,oid]"
> > >                                                               ] [
> > > "offsetindex(BAT[void,oid], int) : BAT[void,oid]"
> > >
> > >                 ] [ "pf2tijah_node(BAT[void,str], BAT[void,int],
> > > BAT[oid,oid], BAT[void,oid], BAT[void,int], BAT[void,str]) :
> > > BAT[void,oid]" ] [ "run_tijah_command(str)
> > >
> > > : bit"
> > >
> > >                                                                     ] [
> > > "run_tijah_query(BAT[str,str], BAT[void,oid], str) : BAT[oid,dbl]"
> > >
> > >                 ] [ "score_NLLR(BAT[oid,oid], BAT[void,int],
> > > BAT[oid,int], BAT[oid,int], BAT[oid,any], dbl, int) : BAT[oid,dbl]"
> > >                                      ] [
> > > "serialize_tijah_opt(BAT[void,BAT], int, BAT[void,oid], BAT[void,oid],
> > > BAT[void,oid], BAT[void,int], BAT[void,lng], BAT[void,dbl],
> > > BAT[void,str])
> > >
> > > : BAT[str,str]"       ] [ "tijah_tokenize(str) : str"
> > >
> > >                                           ] [ "tj_add2collection(str,
> > > BAT[str,str], bit) : void"
> > >                                                                     ] [
> > > "tj_add2collection(str, str, str, bit) : void"
> > >
> > >                 ] [ "tj_create_termdb(int, oid) : void"
> > >
> > >                                     ] [ "tj_delete_collection(str) :
> > > void"
> > >
> > >                                                         ] [
> > > "tj_delete_global() : void"
> > >
> > >                 ] [ "tj_dispose_termdb() : void"
> > >
> > >                                     ] [ "tj_finalize_collection(str) :
> > > void"
> > >                                                              ] [
> > > "tj_init_collection(str, BAT[str,str]) : void"
> > >
> > >                 ] [ "tj_init_global(BAT[str,str]) : void"
> > >
> > >                                     ] [ "tj_normalizeTerm(str, str) :
> > > str"
> > >
> > >                                                         ] [
> > > "treemergejoin_sort(BAT[void,oid], BAT[void,int], BAT[void,oid]) :
> > > BAT[oid,oid]"
> > >                          ] mil>
> > > ========
> > >
> > > does this help?
> > >
> > > otherwise (i.e., if you're running in/with Mtest) please send us all
> > > your test files for the failing test.
> > >
> > > Stefan
> > >
> > > On Thu, Jan 18, 2007 at 11:01:48AM +0100, Jan Flokstra wrote:
> > > > Hi All,
> > > >
> > > > We are experiencing module problems during XQUERY Mapi execution with
> > > > Mtest which we do not know how to solve. The problem is the Mserver
> > > > does not know any command from the pftijah module which is already
> > > > loaded en executing commands. Executing the same query through the
> > > > mil interface of Mtest works correct. Execution through the
> > > > MapiClient also works correct but execution through the Mapi
> > > > interface with Mtest fails.
> > > >
> > > > DETAIL:
> > > > Our XQUERY query containing pftijah functions is translated by
> > > > 'milprint_summer'to a MIL script containing a call to
> > > > run_tijah_query() which is in module(pftijah). This script is
> > > > executed and the run_tijah_query() function  is executed. This
> > > > function in its turn generates a new MIL script where the  first line
> > > > is 'module(pftijah);'. When we execute this script this script does
> > > > not kown any command from module(pftijah). It does however know
> > > > functions from module(pathfinder). And this all happens in the
> > > > Mtest/Mapi setting. In all other settings it works OK but here it
> > > > fails!
> > > >
> > > > Anybody any ideas??
> > > >
> > > > JanF
> > > >
> > > > ---------------------------------------------------------------------
> > > >---- Take Surveys. Earn Cash. Influence the Future of IT
> > > > Join SourceForge.net's Techsay panel and you'll get the chance to
> > > > share your opinions on IT & business topics through brief surveys -
> > > > and earn cash
> > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DE
> > > >VDEV _______________________________________________
> > > > Monetdb-developers mailing list
> > > > Monetdb-developers at lists.sourceforge.net
> > > > https://lists.sourceforge.net/lists/listinfo/monetdb-developers
> >
> > -------------------------------------------------------------------------
> > Take Surveys. Earn Cash. Influence the Future of IT
> > Join SourceForge.net's Techsay panel and you'll get the chance to share
> > your opinions on IT & business topics through brief surveys - and earn
> > cash
> > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> > _______________________________________________
> > Monetdb-developers mailing list
> > Monetdb-developers at lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/monetdb-developers




More information about the developers-list mailing list