Changeset: 9db1dd472edb for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9db1dd472edb
Added Files:
sql/test/BugTracker-2013/Tests/All
sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.bat
sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.sh
sql/test/BugTracker-2013/Tests/php-size-limit-bug.php
sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.err
sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.out
Modified Files:
clients/php/lib/php_mapi.inc
Branch: default
Log Message:
Merge with Feb2013 branch.
diffs (176 lines):
diff --git a/clients/php/lib/php_mapi.inc b/clients/php/lib/php_mapi.inc
--- a/clients/php/lib/php_mapi.inc
+++ b/clients/php/lib/php_mapi.inc
@@ -19,7 +19,7 @@
*
**/
- define("MAX_PACKET_SIZE", 32766); // Maximum packet size
+ define("MAX_PACKET_SIZE", 8190); // Maximum packet size
define("REPLY_SIZE", "250"); // Set the initial reply size
diff --git a/sql/test/BugTracker-2013/Tests/All
b/sql/test/BugTracker-2013/Tests/All
new file mode 100644
--- /dev/null
+++ b/sql/test/BugTracker-2013/Tests/All
@@ -0,0 +1,1 @@
+php-size-limit-bug
diff --git a/sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.bat
b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.bat
new file mode 100644
--- /dev/null
+++ b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.bat
@@ -0,0 +1,6 @@
+@echo off
+
+prompt # $t $g
+echo on
+
+php -n -d "include_path=%PHP_INCPATH%" -f "%TSTSRCDIR%\php-size-limit-bug.php"
%MAPIPORT% %TSTDB%
diff --git a/sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.sh
b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.sh
new file mode 100755
--- /dev/null
+++ b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.SQL.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+Mlog -x "php -n -d include_path=$PHP_INCPATH -f
$TSTSRCDIR/php-size-limit-bug.php $MAPIPORT $TSTDB"
diff --git a/sql/test/BugTracker-2013/Tests/php-size-limit-bug.php
b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.php
new file mode 100644
--- /dev/null
+++ b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.php
@@ -0,0 +1,17 @@
+<?php
+ require 'monetdb/php_monetdb.php';
+
+ $db = monetdb_connect("sql", "localhost", $argv[1], "monetdb", "monetdb",
$argv[2]) or die(monetdb_last_error());
+
+ $packet_size = 20000;
+
+ $sql = 'select 1';
+ $sql = str_pad($sql, $packet_size , ' ');
+
+ echo strlen($sql) . "\n";
+
+ $res = monetdb_query($sql);
+ while ( $row = monetdb_fetch_assoc($res) ) { print_r($row); }
+
+ monetdb_disconnect();
+?>
\ No newline at end of file
diff --git a/sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.err
b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.err
new file mode 100644
--- /dev/null
+++ b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.err
@@ -0,0 +1,42 @@
+stderr of test 'php-size-limit-bug` in directory 'test/BugTracker-2013` itself:
+
+
+# 23:24:09 >
+# 23:24:09 > "mserver5" "--debug=10" "--set" "gdk_nr_threads=0" "--set"
"gdk_dbfarm=/home/sjoerd/Monet-stable/var/MonetDB" "--set" "mapi_open=true"
"--set" "mapi_port=31195" "--set"
"mapi_usock=/var/tmp/mtest-22217/.s.monetdb.31195" "--set" "monet_prompt="
"--trace" "--forcemito" "--set" "mal_listing=2"
"--dbname=mTests_test_BugTracker-2013" "--set" "mal_listing=0"
+# 23:24:09 >
+
+# builtin opt gdk_dbname = demo
+# builtin opt gdk_dbfarm = /home/sjoerd/Monet-stable/var/monetdb5/dbfarm
+# builtin opt gdk_debug = 0
+# builtin opt gdk_vmtrim = yes
+# builtin opt monet_prompt = >
+# builtin opt monet_daemon = no
+# builtin opt mapi_port = 50000
+# builtin opt mapi_open = false
+# builtin opt mapi_autosense = false
+# builtin opt sql_optimizer = default_pipe
+# builtin opt sql_debug = 0
+# cmdline opt gdk_nr_threads = 0
+# cmdline opt gdk_dbfarm = /home/sjoerd/Monet-stable/var/MonetDB
+# cmdline opt mapi_open = true
+# cmdline opt mapi_port = 31195
+# cmdline opt mapi_usock = /var/tmp/mtest-22217/.s.monetdb.31195
+# cmdline opt monet_prompt =
+# cmdline opt mal_listing = 2
+# cmdline opt gdk_dbname = mTests_test_BugTracker-2013
+# cmdline opt mal_listing = 0
+
+# 23:24:09 >
+# 23:24:09 > "./php-size-limit-bug.SQL.sh" "php-size-limit-bug"
+# 23:24:09 >
+
+
+# 23:24:09 >
+# 23:24:09 > php -n -d include_path=/home/sjoerd/Monet-stable/share/php -f
/home/sjoerd/src/MonetDB/stable/sql/test/BugTracker-2013/Tests/php-size-limit-bug.php
31195 mTests_test_BugTracker-2013
+# 23:24:09 >
+
+
+# 23:24:10 >
+# 23:24:10 > "Done."
+# 23:24:10 >
+
diff --git a/sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.out
b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.out
new file mode 100644
--- /dev/null
+++ b/sql/test/BugTracker-2013/Tests/php-size-limit-bug.stable.out
@@ -0,0 +1,64 @@
+stdout of test 'php-size-limit-bug` in directory 'test/BugTracker-2013` itself:
+
+
+# 23:24:09 >
+# 23:24:09 > "mserver5" "--debug=10" "--set" "gdk_nr_threads=0" "--set"
"gdk_dbfarm=/home/sjoerd/Monet-stable/var/MonetDB" "--set" "mapi_open=true"
"--set" "mapi_port=31195" "--set"
"mapi_usock=/var/tmp/mtest-22217/.s.monetdb.31195" "--set" "monet_prompt="
"--trace" "--forcemito" "--set" "mal_listing=2"
"--dbname=mTests_test_BugTracker-2013" "--set" "mal_listing=0"
+# 23:24:09 >
+
+# MonetDB 5 server v11.13.8 (hg id: 605737446b9d+)
+# This is an unreleased version
+# Serving database 'mTests_test_BugTracker-2013', using 8 threads
+# Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically
linked
+# Found 7.735 GiB available main-memory.
+# Copyright (c) 1993-July 2008 CWI.
+# Copyright (c) August 2008-2013 MonetDB B.V., all rights reserved
+# Visit http://www.monetdb.org/ for further information
+# Listening for connection requests on mapi:monetdb://gaai.mullender.nl:31195/
+# Listening for UNIX domain connection requests on
mapi:monetdb:///var/tmp/mtest-22217/.s.monetdb.31195
+# MonetDB/GIS module loaded
+# MonetDB/JAQL module loaded
+# MonetDB/SQL module loaded
+
+Ready.
+# SQL catalog created, loading sql scripts once
+# loading sql script: 09_like.sql
+# loading sql script: 10_math.sql
+# loading sql script: 11_times.sql
+# loading sql script: 12_url.sql
+# loading sql script: 13_date.sql
+# loading sql script: 14_inet.sql
+# loading sql script: 15_history.sql
+# loading sql script: 16_tracelog.sql
+# loading sql script: 17_compress.sql
+# loading sql script: 18_dictionary.sql
+# loading sql script: 19_cluster.sql
+# loading sql script: 20_vacuum.sql
+# loading sql script: 21_dependency_functions.sql
+# loading sql script: 22_clients.sql
+# loading sql script: 23_skyserver.sql
+# loading sql script: 24_zorder.sql
+# loading sql script: 25_debug.sql
+# loading sql script: 39_analytics.sql
+# loading sql script: 40_geom.sql
+# loading sql script: 80_udf.sql
+# loading sql script: 99_system.sql
+
+# 23:24:09 >
+# 23:24:09 > "./php-size-limit-bug.SQL.sh" "php-size-limit-bug"
+# 23:24:09 >
+
+
+# 23:24:09 >
+# 23:24:09 > php -n -d include_path=/home/sjoerd/Monet-stable/share/php -f
/home/sjoerd/src/MonetDB/stable/sql/test/BugTracker-2013/Tests/php-size-limit-bug.php
31195 mTests_test_BugTracker-2013
+# 23:24:09 >
+
+20000
+Array
+(
+ [single_value] => 1
+)
+
+# 23:24:10 >
+# 23:24:10 > "Done."
+# 23:24:10 >
+
_______________________________________________
checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list