trafodion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hzel...@apache.org
Subject [16/37] incubator-trafodion git commit: add cleanup for drop schema and reorder script
Date Tue, 01 Mar 2016 22:36:02 GMT
add cleanup for drop schema and reorder script


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/93341376
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/93341376
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/93341376

Branch: refs/heads/master
Commit: 933413766810056d5b90a6862378346cd5c3dedb
Parents: 8c8d305
Author: Kevin Xu <kaihua.xu@esgyn.cn>
Authored: Wed Dec 23 17:50:33 2015 +0800
Committer: Kevin Xu <kaihua.xu@esgyn.cn>
Committed: Wed Dec 23 17:54:29 2015 +0800

----------------------------------------------------------------------
 .../main/java/org/trafodion/libmgmt/FileMgmt.java    |  2 +-
 core/sql/lib_mgmt/src/main/resources/init_libmgmt.sh | 15 +++++++--------
 2 files changed, 8 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/93341376/core/sql/lib_mgmt/src/main/java/org/trafodion/libmgmt/FileMgmt.java
----------------------------------------------------------------------
diff --git a/core/sql/lib_mgmt/src/main/java/org/trafodion/libmgmt/FileMgmt.java b/core/sql/lib_mgmt/src/main/java/org/trafodion/libmgmt/FileMgmt.java
index ed6a725..4fdeb2b 100644
--- a/core/sql/lib_mgmt/src/main/java/org/trafodion/libmgmt/FileMgmt.java
+++ b/core/sql/lib_mgmt/src/main/java/org/trafodion/libmgmt/FileMgmt.java
@@ -48,7 +48,7 @@ public class FileMgmt {
 	// 100Mb
 	private static final long MAX_JAR_FILE_SIZE = 104857600;
 	private static final SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
-	private static final int MaxDataSize = 102400;
+	private static final int MaxDataSize = 12800;
 	private static final String CHARTSET = "ISO-8859-1";
 
 	/**

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/93341376/core/sql/lib_mgmt/src/main/resources/init_libmgmt.sh
----------------------------------------------------------------------
diff --git a/core/sql/lib_mgmt/src/main/resources/init_libmgmt.sh b/core/sql/lib_mgmt/src/main/resources/init_libmgmt.sh
index ec6c031..13b64bf 100644
--- a/core/sql/lib_mgmt/src/main/resources/init_libmgmt.sh
+++ b/core/sql/lib_mgmt/src/main/resources/init_libmgmt.sh
@@ -23,8 +23,8 @@
 SERVER_JAR=${MY_SQROOT}/export/lib/lib_mgmt.jar
 CI=sqlci
 CATALOG_NAME=TRAFODION
-LIB_SCHEMA="DB__LIBMGR"
-DB__LIBMGRROLE=DB__LIBMGRROLE
+LIB_SCHEMA="DB_LIBMGR"
+DB__LIBMGRROLE=DB_LIBMGRROLE
 LIB_NAME=LIBMGMTNAME
 
 function dropAndCreateSchema {
@@ -34,8 +34,11 @@ function dropAndCreateSchema {
       cqd CAT_IGNORE_ALREADY_EXISTS_ERROR 'on';
       cqd CAT_IGNORE_DOES_NOT_EXIST_ERROR 'on';
 
-      DROP SCHEMA $CATALOG_NAME.$LIB_SCHEMA CASCADE;
+      DROP LIBRARY ${LIB_NAME} CASCADE;
+      DROP SCHEMA $CATALOG_NAME.$LIB_SCHEMA CLEANUP CASCADE;
       CREATE SCHEMA $CATALOG_NAME.$LIB_SCHEMA;
+      CREATE LIBRARY ${LIB_NAME} FILE '${SERVER_JAR}';
+      CREATE ROLE ${DB__LIBMGRROLE};
 
       cqd CAT_IGNORE_ALREADY_EXISTS_ERROR 'off';
       cqd CAT_IGNORE_DOES_NOT_EXIST_ERROR 'off';
@@ -54,10 +57,6 @@ function createProcedures {
 
       -- Creating Procedures 
       set schema $CATALOG_NAME.$LIB_SCHEMA;
-
-      DROP LIBRARY ${LIB_NAME} CASCADE;
-      CREATE LIBRARY ${LIB_NAME} FILE '${SERVER_JAR}';
-      CREATE ROLE ${DB__LIBMGRROLE};
    
       CREATE PROCEDURE HELP (
       INOUT COMMANDNAME VARCHAR(2560) CHARACTER SET ISO88591)
@@ -132,7 +131,7 @@ function createProcedures {
       CREATE PROCEDURE GETFILE (
       IN FILENAME VARCHAR(256) CHARACTER SET UTF8,
       IN OFFSET INTEGER,
-      OUT FILEDATA VARCHAR(51200) CHARACTER SET UTF8,
+      OUT FILEDATA VARCHAR(12800) CHARACTER SET UTF8,
       OUT DATALENGTH LARGEINT)
       EXTERNAL NAME 'org.trafodion.libmgmt.FileMgmt.get (java.lang.String,int,java.lang.String[],long[])'
       EXTERNAL SECURITY DEFINER


Mime
View raw message