MonetDB: default - Add abort keyword
Changeset: d3dda6f2a082 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d3dda6f2a082 Modified Files: monetdb5/optimizer/opt_prelude.c monetdb5/optimizer/opt_prelude.h Branch: default Log Message: Add abort keyword diffs (30 lines): diff --git a/monetdb5/optimizer/opt_prelude.c b/monetdb5/optimizer/opt_prelude.c --- a/monetdb5/optimizer/opt_prelude.c +++ b/monetdb5/optimizer/opt_prelude.c @@ -25,6 +25,7 @@ #include monetdb_config.h #include opt_prelude.h +str abortReft; str affectedRowsRef; str aggrRef; str alarmRef; @@ -249,6 +250,7 @@ int toriginProp;/* original oid source void optimizerInit(void){ if(batRef == NULL){ + abortRef = putName(abort,5); affectedRowsRef = putName(affectedRows,12); aggrRef = putName(aggr,4); alarmRef = putName(alarm,5); diff --git a/monetdb5/optimizer/opt_prelude.h b/monetdb5/optimizer/opt_prelude.h --- a/monetdb5/optimizer/opt_prelude.h +++ b/monetdb5/optimizer/opt_prelude.h @@ -24,6 +24,7 @@ /* cf., gdk/gdk.mx */ #define DEBUGoptimizersif (GDKdebug GRPoptimizers actions) +opt_export str abortRef; opt_export str affectedRowsRef; opt_export str aggrRef; opt_export str alarmRef; ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Enable MAL directed transaction rollback.
Changeset: 39a0d3f52d7e for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=39a0d3f52d7e Modified Files: sql/backends/monet5/sql.mx Branch: default Log Message: Enable MAL directed transaction rollback. diffs (42 lines): diff --git a/sql/backends/monet5/sql.mx b/sql/backends/monet5/sql.mx --- a/sql/backends/monet5/sql.mx +++ b/sql/backends/monet5/sql.mx @@ -61,6 +61,10 @@ pattern commit() address SQLcommit comment Trigger the commit operation for a MAL block; +pattern abort() +address SQLabort +comment Trigger the abort operation for a MAL block; + pattern catalog(type:int,sname:str,name:str,action:int):void address SQLcatalog comment a catalog statement; @@ -1278,6 +1282,7 @@ extern BAT *mvc_bind_idxbat(mvc *m, char sql5_export str SQLmvc(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); sql5_export str SQLtransaction(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); sql5_export str SQLcommit(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); +sql5_export str SQLabort(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); sql5_export str SQLtransaction2(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); sql5_export str SQLcatalog(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); @@ -1871,6 +1876,19 @@ SQLcommit(Client cntxt, MalBlkPtr mb, Ma } str +SQLabort(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci) +{ + mvc *sql = NULL; + str msg = getSQLContext(cntxt, mb, sql, NULL); + (void) stk; + (void) pci; + + if (sql-session-active) + mvc_rollback(sql, 0, NULL); + return msg; +} + +str SQLtransaction2(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci) { mvc *sql = NULL; ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Abort transactions upon errors
Changeset: 7b0820aa2e23 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=7b0820aa2e23 Modified Files: sql/backends/monet5/datacell/petrinet.c Branch: default Log Message: Abort transactions upon errors When a continuous query stops due to errors, we have to abort the transaction. diffs (41 lines): diff --git a/sql/backends/monet5/datacell/petrinet.c b/sql/backends/monet5/datacell/petrinet.c --- a/sql/backends/monet5/datacell/petrinet.c +++ b/sql/backends/monet5/datacell/petrinet.c @@ -466,7 +466,7 @@ PNcontroller(void *dummy) MalBlkPtr mb; Client cntxt; int k = -1; - int m = 0; + int m = 0, abortpc=0; str msg; lng t, analysis, now; char buf[BUFSIZ], *modnme, *fcnnme; @@ -499,14 +499,17 @@ reinit: p = newFcnCall(mb, modnme, fcnnme); pnet[i].pc = getPC(mb, p); } + p= newFcnCall(mb, sqlRef, abortRef); + abortpc = getPC(mb,p); pushEndInstruction(mb); /*printf(\n1 mb-vtop:%d\n,mb-vtop);*/ chkProgram(cntxt-fdout, cntxt-nspace, mb); + MT_lock_unset(dcLock, pncontroller); if (mb-errors) { + printFunction(cntxt-fdout, mb, 0, LIST_MAL_ALL); mnstr_printf(cntxt-fdout, #Petrinet Controller found errors\n); return; } - MT_lock_unset(dcLock, pncontroller); newStack(glb, mb-vtop); memset((char *) glb, 0, stackSize(mb-vtop)); glb-stktop = mb-vtop; @@ -599,6 +602,9 @@ reinit: } else GDKfree(msg); pnet[i].enabled = -1; + /* abort current transaction */ + if ( abortpc ) + msg = reenterMAL(cntxt, mb, abortpc, abortpc + 1, glb, 0, 0); } else { (void) MTIMEcurrent_timestamp(pnet[i].seen); for (j = 0; j pnet[i].srctop; j++) { ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Trim the temperature constraint.
Changeset: 1285d7d8919d for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1285d7d8919d Modified Files: sql/backends/monet5/datacell/Tests/emili.sql Branch: default Log Message: Trim the temperature constraint. diffs (12 lines): diff --git a/sql/backends/monet5/datacell/Tests/emili.sql b/sql/backends/monet5/datacell/Tests/emili.sql --- a/sql/backends/monet5/datacell/Tests/emili.sql +++ b/sql/backends/monet5/datacell/Tests/emili.sql @@ -75,7 +75,7 @@ BEGIN INSERT INTO datacell.hotsensors SELECT ip, time, value FROM datacell.sensors - WHERE kind LIKE 'temperature' AND value 25; + WHERE kind LIKE 'temperature' AND value 24; END; CALL datacell.query('datacell.hot'); ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Avoid assignments of multiple values
Changeset: 18b6191d7c09 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=18b6191d7c09 Modified Files: sql/backends/monet5/datacell/Tests/emili.sql Branch: default Log Message: Avoid assignments of multiple values In high-rate event arrival there is no guarantee that you have a single location to update. diffs (70 lines): diff --git a/sql/backends/monet5/datacell/Tests/emili.sql b/sql/backends/monet5/datacell/Tests/emili.sql --- a/sql/backends/monet5/datacell/Tests/emili.sql +++ b/sql/backends/monet5/datacell/Tests/emili.sql @@ -46,14 +46,14 @@ CALL datacell.receptor('datacell.observa CREATE PROCEDURE datacell.enrich() BEGIN DECLARE cnt INTEGER; - SET cnt = (SELECT count(*) FROM datacell.area A, datacell.istream I WHERE A.location = substring(I.location,0,3) ) ; + SET cnt = (SELECT count(distinct I.ip) FROM datacell.area A, datacell.istream I WHERE A.location = substring(I.location,0,3) ) ; INSERT INTO datacell.sensors(ip, location, kind,value) SELECT ip, substring(location,0,3), kind, value FROM datacell.istream; IF cnt = 0 THEN INSERT INTO datacell.area SELECT ip, substring(location,0,3) FROM datacell.istream; END IF; - SET cnt = (SELECT count(*) FROM datacell.states A, datacell.istream I WHERE A.location = substring(I.location,0,3) ) ; + SET cnt = (SELECT count(distinct I.ip) FROM datacell.states A, datacell.istream I WHERE A.location = substring(I.location,0,3) ) ; IF cnt = 0 THEN INSERT INTO datacell.states SELECT substring(location,0,3), now(), 'normal' FROM datacell.istream; @@ -98,21 +98,18 @@ call datacell.query('datacell.splitter') CREATE PROCEDURE datacell.firewarning() BEGIN DECLARE cnt INTEGER; - DECLARE loc varchar(5); SET cnt = ( SELECT count(*) FROM datacell.states S, datacell.area A, datacell.hotsensors1 H WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location); - SET loc = ( SELECT A.location - FROM datacell.states S, datacell.area A, datacell.hotsensors1 H - WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location); - IF cnt =1 THEN UPDATE datacell.states SET status = 'unconfirmed', time = now() - WHERE location = loc; + WHERE location IN (SELECT A.location + FROM datacell.states S, datacell.area A, datacell.hotsensors1 H + WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location)); END IF; END; CALL datacell.query('datacell.firewarning'); @@ -121,21 +118,18 @@ CALL datacell.query('datacell.firewarnin CREATE PROCEDURE datacell.firespotted() BEGIN DECLARE cnt INTEGER; - DECLARE loc varchar(5); SET cnt = ( SELECT count(*) FROM datacell.area A, datacell.states S, datacell.area B, datacell.hotsensors2 H WHERE S.status ='unconfirmed' AND A.ip H.ip AND B.ip = H.ip AND A.ip B.ip AND S.location = A.location); - SET loc = ( SELECT A.location - FROM datacell.area A, datacell.states S, datacell.area B, datacell.hotsensors2 H - WHERE S.status ='unconfirmed' AND A.ip H.ip AND B.ip = H.ip AND A.ip B.ip AND S.location = A.location); - IF cnt =1 THEN UPDATE datacell.states SET status = 'confirmed', time = now() - WHERE location = loc; + WHERE location IN (SELECT A.location + FROM datacell.states S, datacell.area A, datacell.hotsensors1 H + WHERE S.status ='unconfirmed' AND A.ip = H.ip and S.location = A.location)); END IF; END; CALL datacell.query('datacell.firespotted'); ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Simplify code and deal with speed
Changeset: d6e1922722b6 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d6e1922722b6 Modified Files: sql/backends/monet5/datacell/Tests/emili.sql Branch: default Log Message: Simplify code and deal with speed When there are many events arriving within a cycle, we triggered primary key violations. The current code is a simplified version diffs (88 lines): diff --git a/sql/backends/monet5/datacell/Tests/emili.sql b/sql/backends/monet5/datacell/Tests/emili.sql --- a/sql/backends/monet5/datacell/Tests/emili.sql +++ b/sql/backends/monet5/datacell/Tests/emili.sql @@ -46,18 +46,19 @@ CALL datacell.receptor('datacell.observa CREATE PROCEDURE datacell.enrich() BEGIN DECLARE cnt INTEGER; - SET cnt = (SELECT count(distinct I.ip) FROM datacell.area A, datacell.istream I WHERE A.location = substring(I.location,0,3) ) ; + INSERT INTO datacell.sensors(ip, location, kind,value) SELECT ip, substring(location,0,3), kind, value FROM datacell.istream; - IF cnt = 0 - THEN - INSERT INTO datacell.area SELECT ip, substring(location,0,3) FROM datacell.istream; - END IF; - SET cnt = (SELECT count(distinct I.ip) FROM datacell.states A, datacell.istream I WHERE A.location = substring(I.location,0,3) ) ; - IF cnt = 0 - THEN - INSERT INTO datacell.states SELECT substring(location,0,3), now(), 'normal' FROM datacell.istream; - END IF; + + INSERT INTO datacell.area + SELECT DISTINCT I.ip, substring(I.location,0,3) + FROM datacell.istream I + WHERE I.ip NOT IN (SELECT ip FROM datacell.area); + + INSERT INTO datacell.states + SELECT DISTINCT substring(location,0,3), now(), 'normal' + FROM datacell.istream + WHERE substring(location,0,3) NOT IN (SELECT location FROM datacell.states); END; CALL datacell.query('datacell.enrich'); @@ -97,40 +98,26 @@ call datacell.query('datacell.splitter') -- unconfirmed fire detection based CREATE PROCEDURE datacell.firewarning() BEGIN - DECLARE cnt INTEGER; - - SET cnt = ( SELECT count(*) - FROM datacell.states S, datacell.area A, datacell.hotsensors1 H - WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location); - - IF cnt =1 - THEN - UPDATE datacell.states - SET status = 'unconfirmed', time = now() - WHERE location IN (SELECT A.location - FROM datacell.states S, datacell.area A, datacell.hotsensors1 H - WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location)); - END IF; + UPDATE datacell.states + SET status = 'unconfirmed', time = now() + WHERE location IN (SELECT A.location + FROM datacell.states S, datacell.area A, datacell.hotsensors1 H + WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location)); END; CALL datacell.query('datacell.firewarning'); -- autoconfirm the fire warning CREATE PROCEDURE datacell.firespotted() BEGIN - DECLARE cnt INTEGER; - - SET cnt = ( SELECT count(*) - FROM datacell.area A, datacell.states S, datacell.area B, datacell.hotsensors2 H - WHERE S.status ='unconfirmed' AND A.ip H.ip AND B.ip = H.ip AND A.ip B.ip AND S.location = A.location); - - IF cnt =1 - THEN - UPDATE datacell.states - SET status = 'confirmed', time = now() - WHERE location IN (SELECT A.location - FROM datacell.states S, datacell.area A, datacell.hotsensors1 H - WHERE S.status ='unconfirmed' AND A.ip = H.ip and S.location = A.location)); - END IF; + UPDATE datacell.states + SET status = 'confirmed', time = now() + WHERE location IN (SELECT A.location + FROM datacell.states S, datacell.area A, datacell.area B, datacell.hotsensors1 H + WHERE S.status ='unconfirmed' + AND A.ip = H.ip + AND A.ip B.ip + AND S.location = A.location + AND S.location = B.location)); END; CALL datacell.query('datacell.firespotted'); ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Approved after changesets d3dda6f2a082 and 3a...
Changeset: 3de7faddd1a5 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3de7faddd1a5 Modified Files: clients/Tests/exports.stable.out Branch: default Log Message: Approved after changesets d3dda6f2a082 and 3aa46df1a623. diffs (11 lines): diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out --- a/clients/Tests/exports.stable.out +++ b/clients/Tests/exports.stable.out @@ -2470,6 +2470,7 @@ str ZORDencode_int_oid(oid *z, int *x, i str ZORDslice_int(int *r, int *xb, int *yb, int *xt, int *yt); str ZORDslice_int(int *r, int *xb, int *yb, int *xt, int *yt){ BAT *bn; void _initTrace(void); +str abortRef; str activateCounter(str name); str addOptimizerPipe(Client cntxt, MalBlkPtr mb, str name); str addPipeDefinition(Client cntxt, str name, str pipe); ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Fix typos and table reference
Changeset: 0eed9f30880d for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0eed9f30880d Modified Files: sql/backends/monet5/datacell/Tests/emili.sql sql/backends/monet5/datacell/petrinet.c Branch: default Log Message: Fix typos and table reference diffs (41 lines): diff --git a/sql/backends/monet5/datacell/Tests/emili.sql b/sql/backends/monet5/datacell/Tests/emili.sql --- a/sql/backends/monet5/datacell/Tests/emili.sql +++ b/sql/backends/monet5/datacell/Tests/emili.sql @@ -102,7 +102,7 @@ BEGIN SET status = 'unconfirmed', time = now() WHERE location IN (SELECT A.location FROM datacell.states S, datacell.area A, datacell.hotsensors1 H - WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location)); + WHERE S.status ='normal' AND A.ip = H.ip and S.location = A.location); END; CALL datacell.query('datacell.firewarning'); @@ -111,13 +111,13 @@ CREATE PROCEDURE datacell.firespotted() BEGIN UPDATE datacell.states SET status = 'confirmed', time = now() - WHERE location IN (SELECT A.location - FROM datacell.states S, datacell.area A, datacell.area B, datacell.hotsensors1 H + WHERE location IN (SELECT S.location + FROM datacell.states S, datacell.area A, datacell.area B, datacell.hotsensors2 H WHERE S.status ='unconfirmed' AND A.ip = H.ip AND A.ip B.ip AND S.location = A.location - AND S.location = B.location)); + AND S.location = B.location); END; CALL datacell.query('datacell.firespotted'); diff --git a/sql/backends/monet5/datacell/petrinet.c b/sql/backends/monet5/datacell/petrinet.c --- a/sql/backends/monet5/datacell/petrinet.c +++ b/sql/backends/monet5/datacell/petrinet.c @@ -117,7 +117,7 @@ int pnettop = 0; int *enabled; /*array that contains the id's of all queries that are enable to fire*/ static int status = BSKTINIT; -static int cycleDelay = 10; /* be careful, it affects response/throughput timings */ +static int cycleDelay = 1; /* be careful, it affects response/throughput timings */ str PNstartThread(int *ret); ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - merged
Changeset: ec877272914c for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ec877272914c Modified Files: clients/Tests/exports.stable.out Branch: default Log Message: merged diffs (11 lines): diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out --- a/clients/Tests/exports.stable.out +++ b/clients/Tests/exports.stable.out @@ -2470,6 +2470,7 @@ str ZORDencode_int_oid(oid *z, int *x, i str ZORDslice_int(int *r, int *xb, int *yb, int *xt, int *yt); str ZORDslice_int(int *r, int *xb, int *yb, int *xt, int *yt){ BAT *bn; void _initTrace(void); +str abortRef; str activateCounter(str name); str addOptimizerPipe(Client cntxt, MalBlkPtr mb, str name); str addPipeDefinition(Client cntxt, str name, str pipe); ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: Jul2012 - make check: remove
Changeset: f5e63d4d2bb7 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f5e63d4d2bb7 Removed Files: clients/RunMapprove.bat.in clients/RunMapprove.in clients/RunMtest.bat.in clients/RunMtest.in clients/Runmclient.bat.in geom/RunMapprove.bat.in geom/RunMapprove.in geom/RunMserver.bat.in geom/RunMtest.bat.in geom/RunMtest.in monetdb5/RunMapprove.bat.in monetdb5/RunMapprove.in monetdb5/RunMserver.bat.in monetdb5/RunMserver.in monetdb5/RunMtest.bat.in monetdb5/RunMtest.in sql/RunMapprove.bat.in sql/RunMapprove.in sql/RunMserver.bat.in sql/RunMserver.in sql/RunMtest.bat.in sql/RunMtest.in Modified Files: clients/Makefile.ag geom/Makefile.ag monetdb5/Makefile.ag sql/Makefile.ag Branch: Jul2012 Log Message: make check: remove make check was disfunctional since the migration to a single-configure tree, and before that it never really worked as make check should, since we always have failing tests, hence remove this functionality this should avoid suggesting people that `make check' is supposed to work diffs (truncated from 1355 to 300 lines): diff --git a/clients/Makefile.ag b/clients/Makefile.ag --- a/clients/Makefile.ag +++ b/clients/Makefile.ag @@ -17,25 +17,4 @@ SUBDIRS = mapilib mapiclient HAVE_ODBC?odbc HAVE_PERL?perl php HAVE_RUBYGEM?ruby examples HAVE_PYTHON?python NATIVE_WIN32?NT -EXTRA_DIST = RunMtest.in RunMtest.bat.in \ - RunMapprove.in \ - Runmclient.bat.in - EXTRA_DIST_DIR = Tests - -TESTS = RunMtest -TESTS_ENVIRONMENT = $(SHELL) - -scripts_sh = { - EXT = - COND = NOT_WIN32 - NOINST - SOURCES = RunMapprove.in RunMtest.in -} - -scripts_bat = { - EXT = bat - COND = NATIVE_WIN32 - NOINST - SOURCES = RunMapprove.bat.in Runmclient.bat.in RunMtest.bat.in -} diff --git a/clients/RunMapprove.bat.in b/clients/RunMapprove.bat.in deleted file mode 100644 --- a/clients/RunMapprove.bat.in +++ /dev/null @@ -1,26 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -r -goto end - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set builddir=%buildbase%\clients -set srcdir=@XSOURCE@\clients - -set PYTHONPATH=%buildbase%\testing;%srcdir%\..\testing;%PYTHONPATH% - -REM execute Mapprove.py in the source directory -pushd %srcdir% - -call %buildbase%\testing\Mapprove.py --package=%pkg% --TSTTRGBASE=%builddir% %* - -popd -endlocal - -:end diff --git a/clients/RunMapprove.in b/clients/RunMapprove.in deleted file mode 100755 --- a/clients/RunMapprove.in +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/sh - -# The contents of this file are subject to the MonetDB Public License -# Version 1.1 (the License); you may not use this file except in -# compliance with the License. You may obtain a copy of the License at -# http://www.monetdb.org/Legal/MonetDBLicense -# -# Software distributed under the License is distributed on an AS IS -# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the -# License for the specific language governing rights and limitations -# under the License. -# -# The Original Code is the MonetDB Database System. -# -# The Initial Developer of the Original Code is CWI. -# Portions created by CWI are Copyright (C) 1997-July 2008 CWI. -# Copyright August 2008-2012 MonetDB B.V. -# All Rights Reserved. - -pkg=clients -buildbase=@QBUILD@ -builddir=${buildbase}/clients -# make sure srcdir contains absolute path name -srcdir=`cd '@srcdir@'; pwd` - -PYTHONPATH=${buildbase}/testing:${srcdir}/../testing:${PYTHONPATH} -export PYTHONPATH - -# execute Mapprove.py in the source directory -cd $srcdir - -# execute the script. -# if no arguments, do a recursive approve (Mapprove.py -r), else pass -# on the arguments -exec python ${buildbase}/testing/Mapprove.py --package=${pkg} --TSTTRGBASE=${builddir} ${@--r} diff --git a/clients/RunMtest.bat.in b/clients/RunMtest.bat.in deleted file mode 100644 --- a/clients/RunMtest.bat.in +++ /dev/null @@ -1,41 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -rq -goto :EOF - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set srcdir=@XSOURCE@ - -rem binaries (.exe) -set PATH=%buildbase%\clients\examples\C;%PATH% -set PATH=%buildbase%\clients\mapiclient;%PATH% -set PATH=%buildbase%\clients\odbc\samples;%PATH% -set PATH=%buildbase%\testing;%PATH% - -rem libraries (.dll) -set PATH=%buildbase%\clients\mapilib;%PATH% -set PATH=%buildbase%\clients\perl\Cimpl;%PATH% -set PATH=%buildbase%\common\stream;%PATH% - -set PYTHONPATH=%buildbase%\clients\python\build\lib;%buildbase%\testing;%srcdir%\testing;%PYTHONPATH% - -set CLASSPATH=%buildbase%\java;%buildbase%\java\tests;%CLASSPATH% - -set perlib=%buildbase%\clients\perl;%srcdir%\clients\perl -set PERLLIB=%perlib%;%PERLLIB% -set PERL5LIB=%perlib%;%PERL5LIB% - -rem execute Mtest.py in the
MonetDB: Jul2012 - JDBC: update minor after 4c38eeec4944 and rel...
Changeset: 78b79c5ea342 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=78b79c5ea342 Modified Files: java/Makefile.ag java/build.properties java/pom.xml java/release.txt Branch: Jul2012 Log Message: JDBC: update minor after 4c38eeec4944 and release of Jul2012-SP1 diffs (50 lines): diff --git a/java/Makefile.ag b/java/Makefile.ag --- a/java/Makefile.ag +++ b/java/Makefile.ag @@ -27,7 +27,7 @@ JAVA_HOME = @JAVA_HOME@ ant_distjdbc = { COND = HAVE_JAVAJDBC DIR = datadir/monetdb/lib - FILES = monetdb-mcl-1.8.jar monetdb-jdbc-2.4.jar jdbcclient.jar + FILES = monetdb-mcl-1.8.jar monetdb-jdbc-2.5.jar jdbcclient.jar } ant_distmerocontrol = { diff --git a/java/build.properties b/java/build.properties --- a/java/build.properties +++ b/java/build.properties @@ -19,7 +19,7 @@ MCL_MINOR=8 # major release number JDBC_MAJOR=2 # minor release number -JDBC_MINOR=4 +JDBC_MINOR=5 # an additional identifying string JDBC_VER_SUFFIX=Liberica # the default port to connect on, if no port given when using SQL diff --git a/java/pom.xml b/java/pom.xml --- a/java/pom.xml +++ b/java/pom.xml @@ -6,7 +6,7 @@ modelVersion4.0.0/modelVersion groupIdmonetdb/groupId artifactIdmonetdb-jdbc/artifactId - version2.4/version + version2.5/version namemonetdb-jdbc/name descriptionMonetDB JDBC driver/description repositories diff --git a/java/release.txt b/java/release.txt --- a/java/release.txt +++ b/java/release.txt @@ -1,8 +1,8 @@ RELEASE NOTES -MonetDB JDBC driver version 2.4 (Liberica/MCL-1.8) +MonetDB JDBC driver version 2.5 (Liberica/MCL-1.8) Fabian Groffen fabian.grof...@cwi.nl -Release date: 2012-07-20 +Release date: 2012-08-23 This JDBC driver is designed for use with MonetDB, a main-memory ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Reduce number of Mx macros.
Changeset: a7a69be7f7a3 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=a7a69be7f7a3 Modified Files: monetdb5/modules/kernel/group.mx Branch: default Log Message: Reduce number of Mx macros. diffs (94 lines): diff --git a/monetdb5/modules/kernel/group.mx b/monetdb5/modules/kernel/group.mx --- a/monetdb5/modules/kernel/group.mx +++ b/monetdb5/modules/kernel/group.mx @@ -401,7 +401,8 @@ refine(BAT **res, BAT *b, BAT *a, int rv oid *hdst, *tdst, o, *op = o, id = 0; BATiter ai = bat_iterator(a), bi = bat_iterator(b); - /* create tmp BAT that holds one cluster; estimate required size using sampling */ + /* create tmp BAT that holds one cluster; estimate required +* size using sampling */ if (BATcount(b) DEFAULT_SIZE) { BAT *histo = NULL, *sample = BATsample(b, DEFAULT_SIZE); @@ -418,7 +419,8 @@ refine(BAT **res, BAT *b, BAT *a, int rv if (histo == NULL) return GDK_FAIL; } - /* create a temporary BAT of the estimated size holding pointers to the a tail atoms */ + /* create a temporary BAT of the estimated size holding +* pointers to the a tail atoms */ cur = 0; end = size; offp = (var_t*) GDKmalloc(size * sizeof(var_t)); @@ -451,20 +453,8 @@ refine(BAT **res, BAT *b, BAT *a, int rv hdst = (oid *) Hloc(bn,BUNfirst(bn)); tdst = (oid *) Tloc(bn,BUNfirst(bn)); - if (a_void) { - @:refine_loop(@:refine_void_1@,@:refine_void_2@,GDKfree(base);,this = base;)@ - } else { - @:refine_loop()@ - } -@= refine_void_2 - off = (BUN) (this - base); - base = (char*) GDKrealloc(base, size * sizeof(oid)); - this = base + off; -@= refine_void_1 - *(oid*)this = a-tseqbase+r; - r = (BUN) (this - base); -@= refine_loop - /* merge-scan tail of b, finding chunks with equal values; then sort each chunk on a */ + /* merge-scan tail of b, finding chunks with equal values; +* then sort each chunk on a */ BATloop(b, p, q) { if ((*cmp) (BUNtail(bi, last), BUNtail(bi, p))) { cnt = sort_flush(offp, ids, cur, tpe, base ? base : a-T-vheap-base, hdst, tdst, id, rv); @@ -473,7 +463,9 @@ refine(BAT **res, BAT *b, BAT *a, int rv last = p; cur = 0; - @4 + if (a_void) { + this = base; + } } o = *(oid *) BUNhead(bi, p); BUNfndOID(r, ai, op); @@ -483,23 +475,30 @@ refine(BAT **res, BAT *b, BAT *a, int rv BBPreclaim(bn); GDKfree(offp); GDKfree(ids); - @3 + if (a_void) { + GDKfree(base); + } return GDK_FAIL; } if (cur = end) { offp = (var_t*) GDKrealloc(offp, (size *= 2) * sizeof(var_t)); ids = (oid*) GDKrealloc(ids, size * sizeof(oid)); end = size; - @2 + if (a_void) { + off = (BUN) (this - base); + base = GDKrealloc(base, size * sizeof(oid)); + this = base + off; + } } - @1 + if (a_void) { + *(oid*)this = a-tseqbase+r; + r = (BUN) (this - base); + this += sizeof(oid); + } offp[cur] = (base) ? ra-T-shift : VarHeapValRaw(a-T-heap.base, r, a-T-width); ids[cur] = o; cur++; - this += sizeof(oid); } -@ -@c cnt = sort_flush(offp, ids, cur, tpe, base ? base : a-T-vheap-base, hdst, tdst, id, rv); hdst += cnt; tdst += cnt; ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - Implemented candidate lists in batcalc operat...
Changeset: 48387bd17298 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=48387bd17298 Added Files: gdk/gdk_calc_compare.h Modified Files: clients/Tests/exports.stable.out gdk/Makefile.ag gdk/gdk_calc.c gdk/gdk_calc.h monetdb5/modules/kernel/algebra.mx monetdb5/modules/mal/batcalc.c monetdb5/modules/mal/batcalc.mal monetdb5/modules/mal/batcalc.mal.sh monetdb5/modules/mal/batmtime.mal monetdb5/modules/mal/batmtime.mal.sh monetdb5/optimizer/Tests/AEexample.stable.out monetdb5/optimizer/Tests/inline02.stable.out monetdb5/optimizer/Tests/inline03.stable.out monetdb5/optimizer/Tests/inline04.stable.out monetdb5/optimizer/Tests/inline06.stable.out monetdb5/optimizer/Tests/inline07.stable.out monetdb5/optimizer/Tests/remap.stable.out monetdb5/optimizer/Tests/roberto1.stable.out monetdb5/optimizer/Tests/tst4800.stable.out monetdb5/optimizer/Tests/tst4820.stable.out monetdb5/optimizer/Tests/tst4900.stable.out Branch: default Log Message: Implemented candidate lists in batcalc operations. The candidate list is an extra, optional argument to all batcalc functions. The argument must be a dense-headed bat with in the tail a sorted list of OIDs without duplicates that refer to the head of the (first) input bat which must also be dense-headed. The referred-to tuples are used to operate on. The output bat contains NIL values for all tuples not operated on (and is thus still aligned with the input). Note that in case the candidates list is not provided, the other input bats don't need to be dense-headed (though still oid). This doubles the number of entries in batcalc.mal, but reduces the number of C functions used to implement all of this. ;-) diffs (truncated from 45069 to 300 lines): diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out --- a/clients/Tests/exports.stable.out +++ b/clients/Tests/exports.stable.out @@ -26,79 +26,79 @@ void BATassertProps(BAT *b); atomDesc BATatoms[]; BAT *BATattach(int tt, const char *heapfile); BAT *BATbandjoin(BAT *l, BAT *r, ptr mnus, ptr plus, bit li, bit hi); -BAT *BATcalcabsolute(BAT *b); -BAT *BATcalcadd(BAT *b1, BAT *b2, int tp, int abort_on_error); -BAT *BATcalcaddcst(BAT *b, const ValRecord *v, int tp, int abort_on_error); -BAT *BATcalcand(BAT *b1, BAT *b2); -BAT *BATcalcandcst(BAT *b, const ValRecord *v); -int BATcalcavg(BAT *b, dbl *avg, BUN *vals); -BAT *BATcalcbetween(BAT *b, BAT *lo, BAT *hi); -BAT *BATcalcbetweenbatcst(BAT *b, BAT *lo, const ValRecord *hi); -BAT *BATcalcbetweencstbat(BAT *b, const ValRecord *lo, BAT *hi); -BAT *BATcalcbetweencstcst(BAT *b, const ValRecord *lo, const ValRecord *hi); -BAT *BATcalccmp(BAT *b1, BAT *b2); -BAT *BATcalccmpcst(BAT *b, const ValRecord *v); -BAT *BATcalccstadd(const ValRecord *v, BAT *b, int tp, int abort_on_error); -BAT *BATcalccstand(const ValRecord *v, BAT *b); -BAT *BATcalccstcmp(const ValRecord *v, BAT *b); -BAT *BATcalccstdiv(const ValRecord *v, BAT *b, int tp, int abort_on_error); -BAT *BATcalccsteq(const ValRecord *v, BAT *b); -BAT *BATcalccstge(const ValRecord *v, BAT *b); -BAT *BATcalccstgt(const ValRecord *v, BAT *b); -BAT *BATcalccstle(const ValRecord *v, BAT *b); -BAT *BATcalccstlsh(const ValRecord *v, BAT *b, int abort_on_error); -BAT *BATcalccstlt(const ValRecord *v, BAT *b); -BAT *BATcalccstmod(const ValRecord *v, BAT *b, int tp, int abort_on_error); -BAT *BATcalccstmul(const ValRecord *v, BAT *b, int tp, int abort_on_error); -BAT *BATcalccstne(const ValRecord *v, BAT *b); -BAT *BATcalccstor(const ValRecord *v, BAT *b); -BAT *BATcalccstrsh(const ValRecord *v, BAT *b, int abort_on_error); -BAT *BATcalccstsub(const ValRecord *v, BAT *b, int tp, int abort_on_error); -BAT *BATcalccstxor(const ValRecord *v, BAT *b); -BAT *BATcalcdecr(BAT *b, int abort_on_error); -BAT *BATcalcdiv(BAT *b1, BAT *b2, int tp, int abort_on_error); -BAT *BATcalcdivcst(BAT *b, const ValRecord *v, int tp, int abort_on_error); -BAT *BATcalceq(BAT *b1, BAT *b2); -BAT *BATcalceqcst(BAT *b, const ValRecord *v); -BAT *BATcalcge(BAT *b1, BAT *b2); -BAT *BATcalcgecst(BAT *b, const ValRecord *v); -BAT *BATcalcgt(BAT *b1, BAT *b2); -BAT *BATcalcgtcst(BAT *b, const ValRecord *v); +BAT *BATcalcabsolute(BAT *b, BAT *s); +BAT *BATcalcadd(BAT *b1, BAT *b2, BAT *s, int tp, int abort_on_error); +BAT *BATcalcaddcst(BAT *b, const ValRecord *v, BAT *s, int tp, int abort_on_error); +BAT *BATcalcand(BAT *b1, BAT *b2, BAT *s); +BAT *BATcalcandcst(BAT *b, const ValRecord *v, BAT *s); +int BATcalcavg(BAT *b, BAT *s, dbl *avg, BUN *vals); +BAT *BATcalcbetween(BAT *b, BAT *lo, BAT *hi, BAT *s); +BAT *BATcalcbetweenbatcst(BAT *b, BAT *lo, const ValRecord *hi, BAT *s); +BAT *BATcalcbetweencstbat(BAT *b, const ValRecord *lo, BAT *hi, BAT *s); +BAT *BATcalcbetweencstcst(BAT *b, const ValRecord *lo, const ValRecord *hi, BAT *s); +BAT
MonetDB: Oct2012 - Merge with Jul2012 branch.
Changeset: 00bdbd51845c for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=00bdbd51845c Removed Files: clients/RunMapprove.bat.in clients/RunMapprove.in clients/RunMtest.bat.in clients/RunMtest.in clients/Runmclient.bat.in geom/RunMapprove.bat.in geom/RunMapprove.in geom/RunMserver.bat.in geom/RunMtest.bat.in geom/RunMtest.in monetdb5/RunMapprove.bat.in monetdb5/RunMapprove.in monetdb5/RunMserver.bat.in monetdb5/RunMserver.in monetdb5/RunMtest.bat.in monetdb5/RunMtest.in sql/RunMapprove.bat.in sql/RunMapprove.in sql/RunMserver.bat.in sql/RunMserver.in sql/RunMtest.bat.in sql/RunMtest.in Modified Files: clients/Makefile.ag geom/Makefile.ag java/Makefile.ag java/build.properties java/pom.xml java/release.txt monetdb5/Makefile.ag monetdb5/extras/jaql/jaqlgencode.c monetdb5/extras/jaql/json.c sql/Makefile.ag Branch: Oct2012 Log Message: Merge with Jul2012 branch. diffs (truncated from 1434 to 300 lines): diff --git a/clients/Makefile.ag b/clients/Makefile.ag --- a/clients/Makefile.ag +++ b/clients/Makefile.ag @@ -17,25 +17,4 @@ SUBDIRS = mapilib mapiclient HAVE_ODBC?odbc HAVE_PERL?perl php HAVE_RUBYGEM?ruby examples HAVE_PYTHON?python HAVE_PYTHON?python3 NATIVE_WIN32?NT -EXTRA_DIST = RunMtest.in RunMtest.bat.in \ - RunMapprove.in \ - Runmclient.bat.in - EXTRA_DIST_DIR = Tests - -TESTS = RunMtest -TESTS_ENVIRONMENT = $(SHELL) - -scripts_sh = { - EXT = - COND = NOT_WIN32 - NOINST - SOURCES = RunMapprove.in RunMtest.in -} - -scripts_bat = { - EXT = bat - COND = NATIVE_WIN32 - NOINST - SOURCES = RunMapprove.bat.in Runmclient.bat.in RunMtest.bat.in -} diff --git a/clients/RunMapprove.bat.in b/clients/RunMapprove.bat.in deleted file mode 100644 --- a/clients/RunMapprove.bat.in +++ /dev/null @@ -1,26 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -r -goto end - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set builddir=%buildbase%\clients -set srcdir=@XSOURCE@\clients - -set PYTHONPATH=%buildbase%\testing;%srcdir%\..\testing;%PYTHONPATH% - -REM execute Mapprove.py in the source directory -pushd %srcdir% - -call %buildbase%\testing\Mapprove.py --package=%pkg% --TSTTRGBASE=%builddir% %* - -popd -endlocal - -:end diff --git a/clients/RunMapprove.in b/clients/RunMapprove.in deleted file mode 100755 --- a/clients/RunMapprove.in +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/sh - -# The contents of this file are subject to the MonetDB Public License -# Version 1.1 (the License); you may not use this file except in -# compliance with the License. You may obtain a copy of the License at -# http://www.monetdb.org/Legal/MonetDBLicense -# -# Software distributed under the License is distributed on an AS IS -# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the -# License for the specific language governing rights and limitations -# under the License. -# -# The Original Code is the MonetDB Database System. -# -# The Initial Developer of the Original Code is CWI. -# Portions created by CWI are Copyright (C) 1997-July 2008 CWI. -# Copyright August 2008-2012 MonetDB B.V. -# All Rights Reserved. - -pkg=clients -buildbase=@QBUILD@ -builddir=${buildbase}/clients -# make sure srcdir contains absolute path name -srcdir=`cd '@srcdir@'; pwd` - -PYTHONPATH=${buildbase}/testing:${srcdir}/../testing:${PYTHONPATH} -export PYTHONPATH - -# execute Mapprove.py in the source directory -cd $srcdir - -# execute the script. -# if no arguments, do a recursive approve (Mapprove.py -r), else pass -# on the arguments -exec python ${buildbase}/testing/Mapprove.py --package=${pkg} --TSTTRGBASE=${builddir} ${@--r} diff --git a/clients/RunMtest.bat.in b/clients/RunMtest.bat.in deleted file mode 100644 --- a/clients/RunMtest.bat.in +++ /dev/null @@ -1,41 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -rq -goto :EOF - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set srcdir=@XSOURCE@ - -rem binaries (.exe) -set PATH=%buildbase%\clients\examples\C;%PATH% -set PATH=%buildbase%\clients\mapiclient;%PATH% -set PATH=%buildbase%\clients\odbc\samples;%PATH% -set PATH=%buildbase%\testing;%PATH% - -rem libraries (.dll) -set PATH=%buildbase%\clients\mapilib;%PATH% -set PATH=%buildbase%\clients\perl\Cimpl;%PATH% -set PATH=%buildbase%\common\stream;%PATH% - -set PYTHONPATH=%buildbase%\clients\python\build\lib;%buildbase%\testing;%srcdir%\testing;%PYTHONPATH% - -set CLASSPATH=%buildbase%\java;%buildbase%\java\tests;%CLASSPATH% - -set perlib=%buildbase%\clients\perl;%srcdir%\clients\perl -set PERLLIB=%perlib%;%PERLLIB% -set PERL5LIB=%perlib%;%PERL5LIB% - -rem execute Mtest.py in the source directory -pushd %srcdir% - -call %buildbase%\testing\Mtest.py
MonetDB: default - Merge with Oct2012 branch.
Changeset: 3c9067f5937f for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3c9067f5937f Removed Files: clients/RunMapprove.bat.in clients/RunMapprove.in clients/RunMtest.bat.in clients/RunMtest.in clients/Runmclient.bat.in geom/RunMapprove.bat.in geom/RunMapprove.in geom/RunMserver.bat.in geom/RunMtest.bat.in geom/RunMtest.in monetdb5/RunMapprove.bat.in monetdb5/RunMapprove.in monetdb5/RunMserver.bat.in monetdb5/RunMserver.in monetdb5/RunMtest.bat.in monetdb5/RunMtest.in sql/RunMapprove.bat.in sql/RunMapprove.in sql/RunMserver.bat.in sql/RunMserver.in sql/RunMtest.bat.in sql/RunMtest.in Modified Files: clients/Makefile.ag geom/Makefile.ag java/Makefile.ag java/build.properties java/pom.xml java/release.txt monetdb5/Makefile.ag monetdb5/extras/jaql/jaqlgencode.c monetdb5/extras/jaql/json.c sql/Makefile.ag Branch: default Log Message: Merge with Oct2012 branch. diffs (truncated from 1434 to 300 lines): diff --git a/clients/Makefile.ag b/clients/Makefile.ag --- a/clients/Makefile.ag +++ b/clients/Makefile.ag @@ -17,25 +17,4 @@ SUBDIRS = mapilib mapiclient HAVE_ODBC?odbc HAVE_PERL?perl php HAVE_RUBYGEM?ruby examples HAVE_PYTHON?python HAVE_PYTHON?python3 NATIVE_WIN32?NT -EXTRA_DIST = RunMtest.in RunMtest.bat.in \ - RunMapprove.in \ - Runmclient.bat.in - EXTRA_DIST_DIR = Tests - -TESTS = RunMtest -TESTS_ENVIRONMENT = $(SHELL) - -scripts_sh = { - EXT = - COND = NOT_WIN32 - NOINST - SOURCES = RunMapprove.in RunMtest.in -} - -scripts_bat = { - EXT = bat - COND = NATIVE_WIN32 - NOINST - SOURCES = RunMapprove.bat.in Runmclient.bat.in RunMtest.bat.in -} diff --git a/clients/RunMapprove.bat.in b/clients/RunMapprove.bat.in deleted file mode 100644 --- a/clients/RunMapprove.bat.in +++ /dev/null @@ -1,26 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -r -goto end - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set builddir=%buildbase%\clients -set srcdir=@XSOURCE@\clients - -set PYTHONPATH=%buildbase%\testing;%srcdir%\..\testing;%PYTHONPATH% - -REM execute Mapprove.py in the source directory -pushd %srcdir% - -call %buildbase%\testing\Mapprove.py --package=%pkg% --TSTTRGBASE=%builddir% %* - -popd -endlocal - -:end diff --git a/clients/RunMapprove.in b/clients/RunMapprove.in deleted file mode 100755 --- a/clients/RunMapprove.in +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/sh - -# The contents of this file are subject to the MonetDB Public License -# Version 1.1 (the License); you may not use this file except in -# compliance with the License. You may obtain a copy of the License at -# http://www.monetdb.org/Legal/MonetDBLicense -# -# Software distributed under the License is distributed on an AS IS -# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the -# License for the specific language governing rights and limitations -# under the License. -# -# The Original Code is the MonetDB Database System. -# -# The Initial Developer of the Original Code is CWI. -# Portions created by CWI are Copyright (C) 1997-July 2008 CWI. -# Copyright August 2008-2012 MonetDB B.V. -# All Rights Reserved. - -pkg=clients -buildbase=@QBUILD@ -builddir=${buildbase}/clients -# make sure srcdir contains absolute path name -srcdir=`cd '@srcdir@'; pwd` - -PYTHONPATH=${buildbase}/testing:${srcdir}/../testing:${PYTHONPATH} -export PYTHONPATH - -# execute Mapprove.py in the source directory -cd $srcdir - -# execute the script. -# if no arguments, do a recursive approve (Mapprove.py -r), else pass -# on the arguments -exec python ${buildbase}/testing/Mapprove.py --package=${pkg} --TSTTRGBASE=${builddir} ${@--r} diff --git a/clients/RunMtest.bat.in b/clients/RunMtest.bat.in deleted file mode 100644 --- a/clients/RunMtest.bat.in +++ /dev/null @@ -1,41 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -rq -goto :EOF - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set srcdir=@XSOURCE@ - -rem binaries (.exe) -set PATH=%buildbase%\clients\examples\C;%PATH% -set PATH=%buildbase%\clients\mapiclient;%PATH% -set PATH=%buildbase%\clients\odbc\samples;%PATH% -set PATH=%buildbase%\testing;%PATH% - -rem libraries (.dll) -set PATH=%buildbase%\clients\mapilib;%PATH% -set PATH=%buildbase%\clients\perl\Cimpl;%PATH% -set PATH=%buildbase%\common\stream;%PATH% - -set PYTHONPATH=%buildbase%\clients\python\build\lib;%buildbase%\testing;%srcdir%\testing;%PYTHONPATH% - -set CLASSPATH=%buildbase%\java;%buildbase%\java\tests;%CLASSPATH% - -set perlib=%buildbase%\clients\perl;%srcdir%\clients\perl -set PERLLIB=%perlib%;%PERLLIB% -set PERL5LIB=%perlib%;%PERL5LIB% - -rem execute Mtest.py in the source directory -pushd %srcdir% - -call %buildbase%\testing\Mtest.py
MonetDB: default - Initialize s.
Changeset: d4eb12932ac7 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d4eb12932ac7 Modified Files: monetdb5/modules/mal/batcalc.c Branch: default Log Message: Initialize s. diffs (12 lines): diff --git a/monetdb5/modules/mal/batcalc.c b/monetdb5/modules/mal/batcalc.c --- a/monetdb5/modules/mal/batcalc.c +++ b/monetdb5/modules/mal/batcalc.c @@ -1126,6 +1126,8 @@ CMDcalcavg(Client cntxt, MalBlkPtr mb, M BBPreleaseref(b-batCacheid); throw(MAL, aggr.avg, RUNTIME_OBJECT_MISSING); } + } else { + s = NULL; } if (!BAThdense(b)) { t = BATmirror(BATmark(BATmirror(b), 0)); /* [dense,tail] */ ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list
MonetDB: default - we can now manage monetdb databases from python.
Changeset: 43cb06902e1f for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=43cb06902e1f Added Files: clients/python/monetdb/control.py clients/python/test/control.py Modified Files: clients/python/monetdb/mapi.py Branch: default Log Message: we can now manage monetdb databases from python. diffs (222 lines): diff --git a/clients/python/monetdb/control.py b/clients/python/monetdb/control.py new file mode 100644 --- /dev/null +++ b/clients/python/monetdb/control.py @@ -0,0 +1,54 @@ + +from monetdb import mapi + +class Control: +def __init__(self, hostname, port, passphrase): +self.server = mapi.Server() +self.server.connect(hostname, port, 'monetdb', passphrase, 'merovingian', 'control') + +def _send_command(self, database_name, command, has_output=False): +return self.server.cmd(%s %s\n % (database_name, command)) + +def create(self, database_name): +return self._send_command(database_name, create) + +def destroy(self, database_name): +return self._send_command(database_name, destroy) + +def lock(self, database_name): +return self._send_command(database_name, lock) + +def release(self, database_name): +return self._send_command(database_name, release) + +def status(self, database_name): +return self._send_command(database_name, status, True) + +def start(self, database_name): +return self._send_command(database_name, start) + +def stop(self, database_name): +return self._send_command(database_name, stop) + +def kill(self, database_name): +return self._send_command(database_name, kill) + +def set(self, database_name, property_, value): +return self._send_command(database_name, %s=%s % (property_, value)) + +def get(self, database_name): +properties = self._send_command(database_name, get) +values = {} +for dirty_line in properties.split(\n)[1:]: +line = dirty_line[1:] +if not line.startswith(#): +if = in line: +split = line.split(=) +values[split[0]] = split[1] +return values + +def inherit(self, database_name, property_): +return self._send_command(database_name, property_ + =) + +def version(self, database_name): +self._send_command(database_name, version) \ No newline at end of file diff --git a/clients/python/monetdb/mapi.py b/clients/python/monetdb/mapi.py --- a/clients/python/monetdb/mapi.py +++ b/clients/python/monetdb/mapi.py @@ -24,6 +24,7 @@ import logging import struct import hashlib from cStringIO import StringIO +import time from monetdb.exceptions import OperationalError, DatabaseError, ProgrammingError, NotSupportedError @@ -45,6 +46,7 @@ MSG_QBLOCK = 6 MSG_HEADER = % MSG_TUPLE = [ MSG_REDIRECT = ^ +MSG_OK = =OK STATE_INIT = 0 STATE_READY = 1 @@ -100,9 +102,12 @@ class Server(object): self.__putblock(response) prompt = self.__getblock().strip() -if len(prompt) == 0: +if len(prompt) == 0 : # Empty response, server is happy pass +elif prompt == MSG_OK: +# New behaviour, I think it is something good +pass elif prompt.startswith(MSG_INFO): logger.info(II %s % prompt[1:]) @@ -134,11 +139,9 @@ class Server(object): self.password, self.database, self.language) else: -logger.error('!' + prompt[0]) raise ProgrammingError(unknown redirect: %s % prompt) else: -logger.error('!' + prompt[0]) raise ProgrammingError(unknown state: %s % prompt) self.state = STATE_READY @@ -161,7 +164,10 @@ class Server(object): self.__putblock(operation) response = self.__getblock() if not len(response): -return +return True +elif response.startswith(MSG_OK): +# New behaviour, I think it is something good +return response.strip() if response == MSG_MORE: # tell server it isn't going to get more return self.cmd() @@ -233,6 +239,8 @@ class Server(object): while count 0: try: recv = self.socket.recv(bytes) +if len(recv) == 0: +time.sleep(1) logger.debug(II: package size: %i payload: %s % (len(recv), recv)) except socket.error, error: raise OperationalError(error[1]) diff --git a/clients/python/test/control.py b/clients/python/test/control.py new file mode 100644 --- /dev/null +++ b/clients/python/test/control.py @@ -0,0 +1,90 @@ +import unittest +from monetdb.control import Control +from monetdb.exceptions import OperationalError +import logging +logging.basicConfig(level=logging.DEBUG) + +database_prefix =
MonetDB: default - merge
Changeset: 74ab40712f88 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=74ab40712f88 Added Files: gdk/gdk_calc_compare.h Removed Files: clients/RunMapprove.bat.in clients/RunMapprove.in clients/RunMtest.bat.in clients/RunMtest.in clients/Runmclient.bat.in geom/RunMapprove.bat.in geom/RunMapprove.in geom/RunMserver.bat.in geom/RunMtest.bat.in geom/RunMtest.in monetdb5/RunMapprove.bat.in monetdb5/RunMapprove.in monetdb5/RunMserver.bat.in monetdb5/RunMserver.in monetdb5/RunMtest.bat.in monetdb5/RunMtest.in sql/RunMapprove.bat.in sql/RunMapprove.in sql/RunMserver.bat.in sql/RunMserver.in sql/RunMtest.bat.in sql/RunMtest.in Modified Files: clients/Makefile.ag clients/Tests/exports.stable.out gdk/Makefile.ag gdk/gdk_calc.c gdk/gdk_calc.h geom/Makefile.ag java/Makefile.ag java/build.properties java/pom.xml java/release.txt monetdb5/Makefile.ag monetdb5/extras/jaql/jaqlgencode.c monetdb5/extras/jaql/json.c monetdb5/modules/kernel/algebra.mx monetdb5/modules/kernel/group.mx monetdb5/modules/mal/batcalc.c monetdb5/modules/mal/batcalc.mal monetdb5/modules/mal/batcalc.mal.sh monetdb5/modules/mal/batmtime.mal monetdb5/modules/mal/batmtime.mal.sh monetdb5/optimizer/Tests/AEexample.stable.out monetdb5/optimizer/Tests/inline02.stable.out monetdb5/optimizer/Tests/inline03.stable.out monetdb5/optimizer/Tests/inline04.stable.out monetdb5/optimizer/Tests/inline06.stable.out monetdb5/optimizer/Tests/inline07.stable.out monetdb5/optimizer/Tests/remap.stable.out monetdb5/optimizer/Tests/roberto1.stable.out monetdb5/optimizer/Tests/tst4800.stable.out monetdb5/optimizer/Tests/tst4820.stable.out monetdb5/optimizer/Tests/tst4900.stable.out sql/Makefile.ag Branch: default Log Message: merge diffs (truncated from 46599 to 300 lines): diff --git a/clients/Makefile.ag b/clients/Makefile.ag --- a/clients/Makefile.ag +++ b/clients/Makefile.ag @@ -17,25 +17,4 @@ SUBDIRS = mapilib mapiclient HAVE_ODBC?odbc HAVE_PERL?perl php HAVE_RUBYGEM?ruby examples HAVE_PYTHON?python HAVE_PYTHON?python3 NATIVE_WIN32?NT -EXTRA_DIST = RunMtest.in RunMtest.bat.in \ - RunMapprove.in \ - Runmclient.bat.in - EXTRA_DIST_DIR = Tests - -TESTS = RunMtest -TESTS_ENVIRONMENT = $(SHELL) - -scripts_sh = { - EXT = - COND = NOT_WIN32 - NOINST - SOURCES = RunMapprove.in RunMtest.in -} - -scripts_bat = { - EXT = bat - COND = NATIVE_WIN32 - NOINST - SOURCES = RunMapprove.bat.in Runmclient.bat.in RunMtest.bat.in -} diff --git a/clients/RunMapprove.bat.in b/clients/RunMapprove.bat.in deleted file mode 100644 --- a/clients/RunMapprove.bat.in +++ /dev/null @@ -1,26 +0,0 @@ -@echo off - -if not %1== goto skip -call %0 -r -goto end - -:skip - -setlocal - -set pkg=clients -set buildbase=@XBUILD@ -set builddir=%buildbase%\clients -set srcdir=@XSOURCE@\clients - -set PYTHONPATH=%buildbase%\testing;%srcdir%\..\testing;%PYTHONPATH% - -REM execute Mapprove.py in the source directory -pushd %srcdir% - -call %buildbase%\testing\Mapprove.py --package=%pkg% --TSTTRGBASE=%builddir% %* - -popd -endlocal - -:end diff --git a/clients/RunMapprove.in b/clients/RunMapprove.in deleted file mode 100755 --- a/clients/RunMapprove.in +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/sh - -# The contents of this file are subject to the MonetDB Public License -# Version 1.1 (the License); you may not use this file except in -# compliance with the License. You may obtain a copy of the License at -# http://www.monetdb.org/Legal/MonetDBLicense -# -# Software distributed under the License is distributed on an AS IS -# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the -# License for the specific language governing rights and limitations -# under the License. -# -# The Original Code is the MonetDB Database System. -# -# The Initial Developer of the Original Code is CWI. -# Portions created by CWI are Copyright (C) 1997-July 2008 CWI. -# Copyright August 2008-2012 MonetDB B.V. -# All Rights Reserved. - -pkg=clients -buildbase=@QBUILD@ -builddir=${buildbase}/clients -# make sure srcdir contains absolute path name -srcdir=`cd '@srcdir@'; pwd` - -PYTHONPATH=${buildbase}/testing:${srcdir}/../testing:${PYTHONPATH} -export PYTHONPATH - -# execute Mapprove.py in the source directory -cd $srcdir - -# execute the script. -# if no arguments, do a recursive approve (Mapprove.py -r), else pass -# on the arguments -exec python ${buildbase}/testing/Mapprove.py --package=${pkg} --TSTTRGBASE=${builddir} ${@--r} diff --git a/clients/RunMtest.bat.in
MonetDB: default - Move datacell application to separate directory
Changeset: 15ee54ecccbf for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=15ee54ecccbf Added Files: sql/backends/monet5/datacell/Tests/emili/README sql/backends/monet5/datacell/Tests/emili/emili.sql sql/backends/monet5/datacell/Tests/emili/sensor.log.gz Removed Files: sql/backends/monet5/datacell/Tests/emili.sql Branch: default Log Message: Move datacell application to separate directory diffs (truncated from 1867 to 300 lines): diff --git a/sql/backends/monet5/datacell/Tests/emili/README b/sql/backends/monet5/datacell/Tests/emili/README new file mode 100644 --- /dev/null +++ b/sql/backends/monet5/datacell/Tests/emili/README @@ -0,0 +1,13 @@ +This example models a fire-detection system. +It can be exercised as follows. + +step 1) create an new database, e.g. called demo + sh monetdb create demo; monetdb release demo + +step 2) initialize the datacell progream + sh mclient -d demo +sql \emili.sql + +step 3) in a different window sent events at a rate of 10/seconds + +cat sensor.log |sensor --port=50500 --delay=100 --trace --replay diff --git a/sql/backends/monet5/datacell/Tests/emili.sql b/sql/backends/monet5/datacell/Tests/emili/emili.sql rename from sql/backends/monet5/datacell/Tests/emili.sql rename to sql/backends/monet5/datacell/Tests/emili/emili.sql diff --git a/sql/backends/monet5/datacell/Tests/emili/sensor.log.gz b/sql/backends/monet5/datacell/Tests/emili/sensor.log.gz new file mode 100644 index ..c1698c1de48e89e9ee73dd427623328d1d7f39ba GIT binary patch literal 97939 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
MonetDB: default - remove superfluous variable
Changeset: e983d24b32b2 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e983d24b32b2 Modified Files: sql/backends/monet5/datacell/Tests/emili/emili.sql Branch: default Log Message: remove superfluous variable diffs (12 lines): diff --git a/sql/backends/monet5/datacell/Tests/emili/emili.sql b/sql/backends/monet5/datacell/Tests/emili/emili.sql --- a/sql/backends/monet5/datacell/Tests/emili/emili.sql +++ b/sql/backends/monet5/datacell/Tests/emili/emili.sql @@ -45,8 +45,6 @@ CALL datacell.receptor('datacell.observa -- enrich at the arrival time of each stream event CREATE PROCEDURE datacell.enrich() BEGIN - DECLARE cnt INTEGER; - INSERT INTO datacell.sensors(ip, location, kind,value) SELECT ip, substring(location,0,3), kind, value FROM datacell.istream; ___ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list