From: Martin Zaun Date: April 19 2012 6:54pm Subject: bzr push into mysql-5.5-cluster-7.2 branch (martin.zaun:3891 to 3893) List-Archive: http://lists.mysql.com/commits/143495 Message-Id: <201204191854.q3JIsdXb028884@acsmt358.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit 3893 Martin Zaun 2012-04-19 [merge] ndbjtie - merge from 71 to 72 3892 Martin Zaun 2012-04-19 [merge] merge from ndb-7.2-ndbjtie-constants-test added: storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.cpp storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.hpp storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_lib.cpp storage/ndb/src/ndbjtie/test/test/NdbJTieConstantsTest.java storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.cmd.in storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.sh.in storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.cmd.in storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.sh.in modified: storage/ndb/src/ndbjtie/com/mysql/ndbjtie/ndbapi/NDBAPIConst.java storage/ndb/src/ndbjtie/jtie/test/unload/test/MyLoadUnloadTest.java storage/ndb/src/ndbjtie/test/CMakeLists.txt storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.alt storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.cpp storage/ndb/src/ndbjtie/test/test/JTieTestBase.java storage/ndb/src/ndbjtie/test/test/NdbJTieMultiLibTest.java storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.cmd.in storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.sh.in storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.cmd.in storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.sh.in 3891 magnus.blaudd@stripped 2012-04-18 [merge] Merge modified: mysql-test/lib/mtr_cases.pm mysql-test/mysql-test-run.pl mysql-test/suite/ndb_memcache/include/have_memcache.inc === modified file 'storage/ndb/src/ndbjtie/com/mysql/ndbjtie/ndbapi/NDBAPIConst.java' --- a/storage/ndb/src/ndbjtie/com/mysql/ndbjtie/ndbapi/NDBAPIConst.java 2012-03-23 20:29:31 +0000 +++ b/storage/ndb/src/ndbjtie/com/mysql/ndbjtie/ndbapi/NDBAPIConst.java 2012-04-19 10:46:43 +0000 @@ -26,6 +26,8 @@ import com.mysql.jtie.Wrapper; public interface NDBAPIConst { +// these limits are subject to change; don't map as constants +/* int NDB_MAX_NO_OF_ATTRIBUTES_IN_KEY = 32, NDB_MAX_ATTRIBUTES_IN_INDEX = NDB_MAX_NO_OF_ATTRIBUTES_IN_KEY, NDB_MAX_ATTRIBUTES_IN_TABLE = 512, @@ -35,4 +37,5 @@ public interface NDBAPIConst NDB_MAX_TUPLE_SIZE = (NDB_MAX_TUPLE_SIZE_IN_WORDS*4), NDB_MAX_ACTIVE_EVENTS = 100, NDB_MAX_SCANFILTER_SIZE_IN_WORDS = (16384 - 1 - 1024); +*/ } === modified file 'storage/ndb/src/ndbjtie/jtie/test/unload/test/MyLoadUnloadTest.java' --- a/storage/ndb/src/ndbjtie/jtie/test/unload/test/MyLoadUnloadTest.java 2012-03-05 07:24:11 +0000 +++ b/storage/ndb/src/ndbjtie/jtie/test/unload/test/MyLoadUnloadTest.java 2012-04-19 11:20:12 +0000 @@ -437,7 +437,7 @@ public class MyLoadUnloadTest { final String cname = System.getProperty(cname_prop, "test.MyJapiTest"); final String mname = System.getProperty(mname_prop, "test"); out.println(); - out.println(" using properties"); + out.println(" settings:"); out.println(" pprefixes = '" + pprefixes + "'"); out.println(" cname = '" + cname + "'"); out.println(" mname = '" + mname + "'"); === modified file 'storage/ndb/src/ndbjtie/test/CMakeLists.txt' --- a/storage/ndb/src/ndbjtie/test/CMakeLists.txt 2012-03-15 07:24:54 +0000 +++ b/storage/ndb/src/ndbjtie/test/CMakeLists.txt 2012-04-19 11:20:12 +0000 @@ -15,7 +15,7 @@ # neither wildcards (nor line breaks) for clean targets supported by cmake SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES - "test_mutils.sh.log;test_mutils.cmd.log;test_ndbjtie_multilib.sh.log;test_ndbjtie_multilib.cmd.log;test_ndbjtie_smoke.sh.log;test_ndbjtie_smoke.cmd.log;test_unload_mutils.sh.log;test_unload_mutils.cmd.log;test_unload_ndbjtie_multilib.sh.log;test_unload_ndbjtie_multilib.cmd.log;test_unload_ndbjtie_smoke.sh.log;test_unload_ndbjtie_smoke.cmd.log;") + "test_mutils.sh.log;test_mutils.cmd.log;test_ndbjtie_constants.sh.log;test_ndbjtie_constants.cmd.log;test_ndbjtie_multilib.sh.log;test_ndbjtie_multilib.cmd.log;test_ndbjtie_smoke.sh.log;test_ndbjtie_smoke.cmd.log;test_unload_mutils.sh.log;test_unload_mutils.cmd.log;test_unload_ndbjtie_constants.sh.log;test_unload_ndbjtie_constants.cmd.log;test_unload_ndbjtie_multilib.sh.log;test_unload_ndbjtie_multilib.cmd.log;test_unload_ndbjtie_smoke.sh.log;test_unload_ndbjtie_smoke.cmd.log;") # the test classes FILE(GLOB JAVA_SOURCES @@ -33,12 +33,40 @@ CREATE_JAR(ndbjtie-test ${JAVA_SOURCES} ADD_EXECUTABLE(ndbjtie_unit_tests-t ndbjtie_unit_tests-t.cpp) +IF(HAVE_JDK) + + INCLUDE_DIRECTORIES( + ${CMAKE_SOURCE_DIR}/storage/ndb/src/ndbjtie/utils + ${CMAKE_SOURCE_DIR}/storage/ndb/src/ndbjtie/jtie + ${CMAKE_SOURCE_DIR}/storage/ndb/include/mgmapi + ${CMAKE_SOURCE_DIR}/storage/ndb/include/ndbapi + ${JNI_INCLUDE_DIRS}) + + # enable safety behaviour + SET(CMAKE_CXX_FLAGS + "${CMAKE_CXX_FLAGS} -DJTIE_OBJECT_CLEAR_ADDRESS_UPON_DELETE") + + # shared library for testing + ADD_LIBRARY(libndbjtie_unit_tests SHARED + ndbjtie_unit_tests_consts.cpp + ndbjtie_unit_tests_lib.cpp) + + SET_TARGET_PROPERTIES(libndbjtie_unit_tests PROPERTIES + OUTPUT_NAME "ndbjtie_unit_tests") + # no other library dependencies + #TARGET_LINK_LIBRARIES(libndbjtie_unit_tests ...) + +ENDIF(HAVE_JDK) + IF(WIN32) # build the unit-test scripts for win CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_mutils.cmd.in ${CMAKE_CURRENT_BINARY_DIR}/test_mutils.cmd @ONLY NEWLINE_STYLE WIN32) + CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_ndbjtie_constants.cmd.in + ${CMAKE_CURRENT_BINARY_DIR}/test_ndbjtie_constants.cmd + @ONLY NEWLINE_STYLE WIN32) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_ndbjtie_multilib.cmd.in ${CMAKE_CURRENT_BINARY_DIR}/test_ndbjtie_multilib.cmd @ONLY NEWLINE_STYLE WIN32) @@ -48,6 +76,9 @@ IF(WIN32) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_unload_mutils.cmd.in ${CMAKE_CURRENT_BINARY_DIR}/test_unload_mutils.cmd @ONLY NEWLINE_STYLE WIN32) + CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_unload_ndbjtie_constants.cmd.in + ${CMAKE_CURRENT_BINARY_DIR}/test_unload_ndbjtie_constants.cmd + @ONLY NEWLINE_STYLE WIN32) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_unload_ndbjtie_multilib.cmd.in ${CMAKE_CURRENT_BINARY_DIR}/test_unload_ndbjtie_multilib.cmd @ONLY NEWLINE_STYLE WIN32) @@ -64,6 +95,12 @@ ELSE(WIN32) ADD_CUSTOM_TARGET(chmod_x_mutils ALL chmod a+x "${CMAKE_CURRENT_BINARY_DIR}/test_mutils.sh" || echo "") # don't break the build if file was deleted) + CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_ndbjtie_constants.sh.in + ${CMAKE_CURRENT_BINARY_DIR}/test_ndbjtie_constants.sh + @ONLY NEWLINE_STYLE UNIX) + ADD_CUSTOM_TARGET(chmod_x_ndbjtie_constants ALL + chmod a+x "${CMAKE_CURRENT_BINARY_DIR}/test_ndbjtie_constants.sh" + || echo "") # don't break the build if file was deleted) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_ndbjtie_multilib.sh.in ${CMAKE_CURRENT_BINARY_DIR}/test_ndbjtie_multilib.sh @ONLY NEWLINE_STYLE UNIX) @@ -82,6 +119,12 @@ ELSE(WIN32) ADD_CUSTOM_TARGET(chmod_x_unload_mutils ALL chmod a+x "${CMAKE_CURRENT_BINARY_DIR}/test_unload_mutils.sh" || echo "") # don't break the build if file was deleted) + CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_unload_ndbjtie_constants.sh.in + ${CMAKE_CURRENT_BINARY_DIR}/test_unload_ndbjtie_constants.sh + @ONLY NEWLINE_STYLE UNIX) + ADD_CUSTOM_TARGET(chmod_x_unload_ndbjtie_constants ALL + chmod a+x "${CMAKE_CURRENT_BINARY_DIR}/test_unload_ndbjtie_constants.sh" + || echo "") # don't break the build if file was deleted) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/test_unload_ndbjtie_multilib.sh.in ${CMAKE_CURRENT_BINARY_DIR}/test_unload_ndbjtie_multilib.sh @ONLY NEWLINE_STYLE UNIX) === modified file 'storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.alt' --- a/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.alt 2012-03-05 04:19:09 +0000 +++ b/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.alt 2012-04-19 10:46:43 +0000 @@ -22,7 +22,7 @@ # redirected to a local log file. # TAP: report test plan -plan="1..6" +plan="1..8" echo "$plan" this_dir="`dirname $0`" @@ -65,9 +65,11 @@ run_test() } run_test "mutils" +run_test "ndbjtie_constants" run_test "ndbjtie_multilib" run_test "ndbjtie_smoke" run_test "unload_mutils" +run_test "unload_ndbjtie_constants" run_test "unload_ndbjtie_multilib" run_test "unload_ndbjtie_smoke" === modified file 'storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.cpp' --- a/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.cpp 2012-03-14 19:13:20 +0000 +++ b/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests-t.cpp 2012-04-19 10:46:43 +0000 @@ -139,10 +139,11 @@ int main(int argc, char **argv) assert(this_name); // TAP: print number of tests to run - plan(6); + plan(8); // run tests run_test_script(this_dir, "mutils"); + run_test_script(this_dir, "ndbjtie_constants"); run_test_script(this_dir, "ndbjtie_multilib"); run_test_script(this_dir, "ndbjtie_smoke"); // TAP: configured by MYTAP_CONFIG environment var @@ -151,10 +152,12 @@ int main(int argc, char **argv) if (false) { printf("\n"); skip(1, "big subtest unload_mutils"); + skip(1, "big subtest unload_ndbjtie_constants"); skip(1, "big subtest unload_ndbjtie_multilib"); skip(1, "big subtest unload_ndbjtie_smoke"); } else { run_test_script(this_dir, "unload_mutils"); + run_test_script(this_dir, "unload_ndbjtie_constants"); run_test_script(this_dir, "unload_ndbjtie_multilib"); run_test_script(this_dir, "unload_ndbjtie_smoke"); } === added file 'storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.cpp' --- a/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.cpp 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.cpp 2012-04-19 10:46:43 +0000 @@ -0,0 +1,443 @@ +/* + Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 of the License. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +*/ +/* + * ndbjtie_unit_tests_classes.cpp + */ + +#include +#include + +#include "ndbjtie_unit_tests_consts.hpp" +#include "NdbApi.hpp" +//#include "NdbError.hpp" + +// name/value pair +struct Constant { + const char * const name; + const long long value; +}; + +// the list of defined constants +static Constant constants[] = { + { "com.mysql.ndbjtie.ndbapi.Ndb$PartitionSpecConst$SpecType.PS_NONE", + Ndb::PartitionSpec::/*_enum SpecType_*/PS_NONE }, + { "com.mysql.ndbjtie.ndbapi.Ndb$PartitionSpecConst$SpecType.PS_USER_DEFINED", + Ndb::PartitionSpec::/*_enum SpecType_*/PS_USER_DEFINED }, + { "com.mysql.ndbjtie.ndbapi.Ndb$PartitionSpecConst$SpecType.PS_DISTR_KEY_PART_PTR", + Ndb::PartitionSpec::/*_enum SpecType_*/PS_DISTR_KEY_PART_PTR }, + { "com.mysql.ndbjtie.ndbapi.Ndb$PartitionSpecConst$SpecType.PS_DISTR_KEY_RECORD", + Ndb::PartitionSpec::/*_enum SpecType_*/PS_DISTR_KEY_RECORD }, + { "com.mysql.ndbjtie.ndbapi.NdbBlob$State.Idle", + NdbBlob::/*_enum State_*/Idle }, + { "com.mysql.ndbjtie.ndbapi.NdbBlob$State.Prepared", + NdbBlob::/*_enum State_*/Prepared }, + { "com.mysql.ndbjtie.ndbapi.NdbBlob$State.Active", + NdbBlob::/*_enum State_*/Active }, + { "com.mysql.ndbjtie.ndbapi.NdbBlob$State.Closed", + NdbBlob::/*_enum State_*/Closed }, + { "com.mysql.ndbjtie.ndbapi.NdbBlob$State.Invalid", + NdbBlob::/*_enum State_*/Invalid }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$ArrayType.ArrayTypeFixed", + NdbDictionary::Column::/*_enum ArrayType_*/ArrayTypeFixed }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$ArrayType.ArrayTypeShortVar", + NdbDictionary::Column::/*_enum ArrayType_*/ArrayTypeShortVar }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$ArrayType.ArrayTypeMediumVar", + NdbDictionary::Column::/*_enum ArrayType_*/ArrayTypeMediumVar }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$StorageType.StorageTypeMemory", + NdbDictionary::Column::/*_enum StorageType_*/StorageTypeMemory }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$StorageType.StorageTypeDisk", + NdbDictionary::Column::/*_enum StorageType_*/StorageTypeDisk }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Undefined", + NdbDictionary::Column::/*_enum Type_*/Undefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Tinyint", + NdbDictionary::Column::/*_enum Type_*/Tinyint }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Tinyunsigned", + NdbDictionary::Column::/*_enum Type_*/Tinyunsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Smallint", + NdbDictionary::Column::/*_enum Type_*/Smallint }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Smallunsigned", + NdbDictionary::Column::/*_enum Type_*/Smallunsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Mediumint", + NdbDictionary::Column::/*_enum Type_*/Mediumint }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Mediumunsigned", + NdbDictionary::Column::/*_enum Type_*/Mediumunsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Int", + NdbDictionary::Column::/*_enum Type_*/Int }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Unsigned", + NdbDictionary::Column::/*_enum Type_*/Unsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Bigint", + NdbDictionary::Column::/*_enum Type_*/Bigint }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Bigunsigned", + NdbDictionary::Column::/*_enum Type_*/Bigunsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Float", + NdbDictionary::Column::/*_enum Type_*/Float }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Double", + NdbDictionary::Column::/*_enum Type_*/Double }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Olddecimal", + NdbDictionary::Column::/*_enum Type_*/Olddecimal }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Olddecimalunsigned", + NdbDictionary::Column::/*_enum Type_*/Olddecimalunsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Decimal", + NdbDictionary::Column::/*_enum Type_*/Decimal }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Decimalunsigned", + NdbDictionary::Column::/*_enum Type_*/Decimalunsigned }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Char", + NdbDictionary::Column::/*_enum Type_*/Char }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Varchar", + NdbDictionary::Column::/*_enum Type_*/Varchar }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Binary", + NdbDictionary::Column::/*_enum Type_*/Binary }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Varbinary", + NdbDictionary::Column::/*_enum Type_*/Varbinary }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Datetime", + NdbDictionary::Column::/*_enum Type_*/Datetime }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Date", + NdbDictionary::Column::/*_enum Type_*/Date }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Blob", + NdbDictionary::Column::/*_enum Type_*/Blob }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Text", + NdbDictionary::Column::/*_enum Type_*/Text }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Bit", + NdbDictionary::Column::/*_enum Type_*/Bit }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Longvarchar", + NdbDictionary::Column::/*_enum Type_*/Longvarchar }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Longvarbinary", + NdbDictionary::Column::/*_enum Type_*/Longvarbinary }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Time", + NdbDictionary::Column::/*_enum Type_*/Time }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Year", + NdbDictionary::Column::/*_enum Type_*/Year }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ColumnConst$Type.Timestamp", + NdbDictionary::Column::/*_enum Type_*/Timestamp }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$EventDurability.ED_UNDEFINED", + NdbDictionary::Event::/*_enum EventDurability_*/ED_UNDEFINED }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$EventDurability.ED_PERMANENT", + NdbDictionary::Event::/*_enum EventDurability_*/ED_PERMANENT }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$EventReport.ER_UPDATED", + NdbDictionary::Event::/*_enum EventReport_*/ER_UPDATED }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$EventReport.ER_ALL", + NdbDictionary::Event::/*_enum EventReport_*/ER_ALL }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$EventReport.ER_SUBSCRIBE", + NdbDictionary::Event::/*_enum EventReport_*/ER_SUBSCRIBE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_INSERT", + NdbDictionary::Event::/*_enum TableEvent_*/TE_INSERT }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_DELETE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_DELETE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_UPDATE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_UPDATE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_DROP", + NdbDictionary::Event::/*_enum TableEvent_*/TE_DROP }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_ALTER", + NdbDictionary::Event::/*_enum TableEvent_*/TE_ALTER }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_CREATE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_CREATE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_GCP_COMPLETE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_GCP_COMPLETE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_CLUSTER_FAILURE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_CLUSTER_FAILURE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_STOP", + NdbDictionary::Event::/*_enum TableEvent_*/TE_STOP }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_NODE_FAILURE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_NODE_FAILURE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_SUBSCRIBE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_SUBSCRIBE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_UNSUBSCRIBE", + NdbDictionary::Event::/*_enum TableEvent_*/TE_UNSUBSCRIBE }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$EventConst$TableEvent.TE_ALL", + NdbDictionary::Event::/*_enum TableEvent_*/TE_ALL }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$IndexConst$Type.Undefined", + NdbDictionary::Index::/*_enum Type_*/Undefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$IndexConst$Type.UniqueHashIndex", + NdbDictionary::Index::/*_enum Type_*/UniqueHashIndex }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$IndexConst$Type.OrderedIndex", + NdbDictionary::Index::/*_enum Type_*/OrderedIndex }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$NdbRecordFlags.RecMysqldShrinkVarchar", + NdbDictionary::/*_enum NdbRecordFlags_*/RecMysqldShrinkVarchar }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$NdbRecordFlags.RecMysqldBitfield", + NdbDictionary::/*_enum NdbRecordFlags_*/RecMysqldBitfield }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.FragUndefined", + NdbDictionary::Object::/*_enum FragmentType_*/FragUndefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.FragSingle", + NdbDictionary::Object::/*_enum FragmentType_*/FragSingle }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.FragAllSmall", + NdbDictionary::Object::/*_enum FragmentType_*/FragAllSmall }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.FragAllMedium", + NdbDictionary::Object::/*_enum FragmentType_*/FragAllMedium }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.FragAllLarge", + NdbDictionary::Object::/*_enum FragmentType_*/FragAllLarge }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.DistrKeyHash", + NdbDictionary::Object::/*_enum FragmentType_*/DistrKeyHash }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.DistrKeyLin", + NdbDictionary::Object::/*_enum FragmentType_*/DistrKeyLin }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$FragmentType.UserDefined", + NdbDictionary::Object::/*_enum FragmentType_*/UserDefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateUndefined", + NdbDictionary::Object::/*_enum State_*/StateUndefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateOffline", + NdbDictionary::Object::/*_enum State_*/StateOffline }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateBuilding", + NdbDictionary::Object::/*_enum State_*/StateBuilding }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateDropping", + NdbDictionary::Object::/*_enum State_*/StateDropping }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateOnline", + NdbDictionary::Object::/*_enum State_*/StateOnline }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateBackup", + NdbDictionary::Object::/*_enum State_*/StateBackup }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$State.StateBroken", + NdbDictionary::Object::/*_enum State_*/StateBroken }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Store.StoreUndefined", + NdbDictionary::Object::/*_enum Store_*/StoreUndefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Store.StoreNotLogged", + NdbDictionary::Object::/*_enum Store_*/StoreNotLogged }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Store.StorePermanent", + NdbDictionary::Object::/*_enum Store_*/StorePermanent }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.TypeUndefined", + NdbDictionary::Object::/*_enum Type_*/TypeUndefined }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.SystemTable", + NdbDictionary::Object::/*_enum Type_*/SystemTable }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.UserTable", + NdbDictionary::Object::/*_enum Type_*/UserTable }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.UniqueHashIndex", + NdbDictionary::Object::/*_enum Type_*/UniqueHashIndex }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.OrderedIndex", + NdbDictionary::Object::/*_enum Type_*/OrderedIndex }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.HashIndexTrigger", + NdbDictionary::Object::/*_enum Type_*/HashIndexTrigger }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.IndexTrigger", + NdbDictionary::Object::/*_enum Type_*/IndexTrigger }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.SubscriptionTrigger", + NdbDictionary::Object::/*_enum Type_*/SubscriptionTrigger }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.ReadOnlyConstraint", + NdbDictionary::Object::/*_enum Type_*/ReadOnlyConstraint }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.TableEvent", + NdbDictionary::Object::/*_enum Type_*/TableEvent }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.Tablespace", + NdbDictionary::Object::/*_enum Type_*/Tablespace }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.LogfileGroup", + NdbDictionary::Object::/*_enum Type_*/LogfileGroup }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.Datafile", + NdbDictionary::Object::/*_enum Type_*/Datafile }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$Object$Type.Undofile", + NdbDictionary::Object::/*_enum Type_*/Undofile }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ObjectConst$Status.New", + NdbDictionary::Object::/*_enum Status_*/New }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ObjectConst$Status.Changed", + NdbDictionary::Object::/*_enum Status_*/Changed }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ObjectConst$Status.Retrieved", + NdbDictionary::Object::/*_enum Status_*/Retrieved }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ObjectConst$Status.Invalid", + NdbDictionary::Object::/*_enum Status_*/Invalid }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$ObjectConst$Status.Altered", + NdbDictionary::Object::/*_enum Status_*/Altered }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$RecordType.TableAccess", + NdbDictionary::/*_enum RecordType_*/TableAccess }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$RecordType.IndexAccess", + NdbDictionary::/*_enum RecordType_*/IndexAccess }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$TableConst$SingleUserMode.SingleUserModeLocked", + NdbDictionary::Table::/*_enum SingleUserMode_*/SingleUserModeLocked }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$TableConst$SingleUserMode.SingleUserModeReadOnly", + NdbDictionary::Table::/*_enum SingleUserMode_*/SingleUserModeReadOnly }, + { "com.mysql.ndbjtie.ndbapi.NdbDictionary$TableConst$SingleUserMode.SingleUserModeReadWrite", + NdbDictionary::Table::/*_enum SingleUserMode_*/SingleUserModeReadWrite }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.NoError", + NdbError::/*_enum Classification_*/NoError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.ApplicationError", + NdbError::/*_enum Classification_*/ApplicationError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.NoDataFound", + NdbError::/*_enum Classification_*/NoDataFound }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.ConstraintViolation", + NdbError::/*_enum Classification_*/ConstraintViolation }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.SchemaError", + NdbError::/*_enum Classification_*/SchemaError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.UserDefinedError", + NdbError::/*_enum Classification_*/UserDefinedError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.InsufficientSpace", + NdbError::/*_enum Classification_*/InsufficientSpace }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.TemporaryResourceError", + NdbError::/*_enum Classification_*/TemporaryResourceError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.NodeRecoveryError", + NdbError::/*_enum Classification_*/NodeRecoveryError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.OverloadError", + NdbError::/*_enum Classification_*/OverloadError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.TimeoutExpired", + NdbError::/*_enum Classification_*/TimeoutExpired }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.UnknownResultError", + NdbError::/*_enum Classification_*/UnknownResultError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.InternalError", + NdbError::/*_enum Classification_*/InternalError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.FunctionNotImplemented", + NdbError::/*_enum Classification_*/FunctionNotImplemented }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.UnknownErrorCode", + NdbError::/*_enum Classification_*/UnknownErrorCode }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.NodeShutdown", + NdbError::/*_enum Classification_*/NodeShutdown }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.SchemaObjectExists", + NdbError::/*_enum Classification_*/SchemaObjectExists }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Classification.InternalTemporary", + NdbError::/*_enum Classification_*/InternalTemporary }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Status.Success", + NdbError::/*_enum Status_*/Success }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Status.TemporaryError", + NdbError::/*_enum Status_*/TemporaryError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Status.PermanentError", + NdbError::/*_enum Status_*/PermanentError }, + { "com.mysql.ndbjtie.ndbapi.NdbErrorConst$Status.UnknownResult", + NdbError::/*_enum Status_*/UnknownResult }, + { "com.mysql.ndbjtie.ndbapi.NdbEventOperation$State.EO_CREATED", + NdbEventOperation::/*_enum State_*/EO_CREATED }, + { "com.mysql.ndbjtie.ndbapi.NdbEventOperation$State.EO_EXECUTING", + NdbEventOperation::/*_enum State_*/EO_EXECUTING }, + { "com.mysql.ndbjtie.ndbapi.NdbEventOperation$State.EO_DROPPED", + NdbEventOperation::/*_enum State_*/EO_DROPPED }, + { "com.mysql.ndbjtie.ndbapi.NdbEventOperation$State.EO_ERROR", + NdbEventOperation::/*_enum State_*/EO_ERROR }, + { "com.mysql.ndbjtie.ndbapi.NdbIndexScanOperation$BoundType.BoundLE", + NdbIndexScanOperation::/*_enum BoundType_*/BoundLE }, + { "com.mysql.ndbjtie.ndbapi.NdbIndexScanOperation$BoundType.BoundLT", + NdbIndexScanOperation::/*_enum BoundType_*/BoundLT }, + { "com.mysql.ndbjtie.ndbapi.NdbIndexScanOperation$BoundType.BoundGE", + NdbIndexScanOperation::/*_enum BoundType_*/BoundGE }, + { "com.mysql.ndbjtie.ndbapi.NdbIndexScanOperation$BoundType.BoundGT", + NdbIndexScanOperation::/*_enum BoundType_*/BoundGT }, + { "com.mysql.ndbjtie.ndbapi.NdbIndexScanOperation$BoundType.BoundEQ", + NdbIndexScanOperation::/*_enum BoundType_*/BoundEQ }, + { "com.mysql.ndbjtie.ndbapi.NdbIndexScanOperation$NotSpecified.MaxRangeNo", + NdbIndexScanOperation::/*_enum NotSpecified_*/MaxRangeNo }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_ABORTOPTION", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_ABORTOPTION }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_GETVALUE", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_GETVALUE }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_SETVALUE", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_SETVALUE }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_PARTITION_ID", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_PARTITION_ID }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_INTERPRETED", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_INTERPRETED }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_ANYVALUE", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_ANYVALUE }, + { "com.mysql.ndbjtie.ndbapi.NdbOperation$OperationOptionsConst$Flags.OO_CUSTOMDATA", + NdbOperation::OperationOptions::/*_enum Flags_*/OO_CUSTOMDATA }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$AbortOption.DefaultAbortOption", + NdbOperation::/*_enum AbortOption_*/DefaultAbortOption }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$AbortOption.AbortOnError", + NdbOperation::/*_enum AbortOption_*/AbortOnError }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$AbortOption.AO_IgnoreError", + NdbOperation::/*_enum AbortOption_*/AO_IgnoreError }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$LockMode.LM_Read", + NdbOperation::/*_enum LockMode_*/LM_Read }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$LockMode.LM_Exclusive", + NdbOperation::/*_enum LockMode_*/LM_Exclusive }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$LockMode.LM_CommittedRead", + NdbOperation::/*_enum LockMode_*/LM_CommittedRead }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$LockMode.LM_Dirty", + NdbOperation::/*_enum LockMode_*/LM_Dirty }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$LockMode.LM_SimpleRead", + NdbOperation::/*_enum LockMode_*/LM_SimpleRead }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$Type.PrimaryKeyAccess", + NdbOperation::/*_enum Type_*/PrimaryKeyAccess }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$Type.UniqueIndexAccess", + NdbOperation::/*_enum Type_*/UniqueIndexAccess }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$Type.TableScan", + NdbOperation::/*_enum Type_*/TableScan }, + { "com.mysql.ndbjtie.ndbapi.NdbOperationConst$Type.OrderedIndexScan", + NdbOperation::/*_enum Type_*/OrderedIndexScan }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_LE", + NdbScanFilter::/*_enum BinaryCondition_*/COND_LE }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_LT", + NdbScanFilter::/*_enum BinaryCondition_*/COND_LT }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_GE", + NdbScanFilter::/*_enum BinaryCondition_*/COND_GE }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_GT", + NdbScanFilter::/*_enum BinaryCondition_*/COND_GT }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_EQ", + NdbScanFilter::/*_enum BinaryCondition_*/COND_EQ }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_NE", + NdbScanFilter::/*_enum BinaryCondition_*/COND_NE }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_LIKE", + NdbScanFilter::/*_enum BinaryCondition_*/COND_LIKE }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$BinaryCondition.COND_NOT_LIKE", + NdbScanFilter::/*_enum BinaryCondition_*/COND_NOT_LIKE }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$Error.FilterTooLarge", + NdbScanFilter::/*_enum Error_*/FilterTooLarge }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$Group.AND", + NdbScanFilter::/*_enum Group_*/AND }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$Group.OR", + NdbScanFilter::/*_enum Group_*/OR }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$Group.NAND", + NdbScanFilter::/*_enum Group_*/NAND }, + { "com.mysql.ndbjtie.ndbapi.NdbScanFilter$Group.NOR", + NdbScanFilter::/*_enum Group_*/NOR }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_TupScan", + NdbScanOperation::/*_enum ScanFlag_*/SF_TupScan }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_DiskScan", + NdbScanOperation::/*_enum ScanFlag_*/SF_DiskScan }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_OrderBy", + NdbScanOperation::/*_enum ScanFlag_*/SF_OrderBy }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_Descending", + NdbScanOperation::/*_enum ScanFlag_*/SF_Descending }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_ReadRangeNo", + NdbScanOperation::/*_enum ScanFlag_*/SF_ReadRangeNo }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_MultiRange", + NdbScanOperation::/*_enum ScanFlag_*/SF_MultiRange }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanFlag.SF_KeyInfo", + NdbScanOperation::/*_enum ScanFlag_*/SF_KeyInfo }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_SCANFLAGS", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_SCANFLAGS }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_PARALLEL", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_PARALLEL }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_BATCH", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_BATCH }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_GETVALUE", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_GETVALUE }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_PARTITION_ID", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_PARTITION_ID }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_INTERPRETED", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_INTERPRETED }, + { "com.mysql.ndbjtie.ndbapi.NdbScanOperation$ScanOptionsConst$Type.SO_CUSTOMDATA", + NdbScanOperation::ScanOptions::/*_enum Type_*/SO_CUSTOMDATA }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$CommitStatusType.NotStarted", + NdbTransaction::/*_enum CommitStatusType_*/NotStarted }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$CommitStatusType.Started", + NdbTransaction::/*_enum CommitStatusType_*/Started }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$CommitStatusType.Committed", + NdbTransaction::/*_enum CommitStatusType_*/Committed }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$CommitStatusType.Aborted", + NdbTransaction::/*_enum CommitStatusType_*/Aborted }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$CommitStatusType.NeedAbort", + NdbTransaction::/*_enum CommitStatusType_*/NeedAbort }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$ExecType.NoExecTypeDef", + NdbTransaction::/*_enum ExecType_*/NoExecTypeDef }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$ExecType.Prepare", + NdbTransaction::/*_enum ExecType_*/Prepare }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$ExecType.NoCommit", + NdbTransaction::/*_enum ExecType_*/NoCommit }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$ExecType.Commit", + NdbTransaction::/*_enum ExecType_*/Commit }, + { "com.mysql.ndbjtie.ndbapi.NdbTransaction$ExecType.Rollback", + NdbTransaction::/*_enum ExecType_*/Rollback }, + { "", UNKNOWN_CONSTANT } // last entry +}; + +long long nativeConstValue(const char * p0) { + assert(p0); + const int n = sizeof(constants) / sizeof(constants[0]); + for (int i = 0; i < n; i++) { + if (!strcmp(constants[i].name, p0)) + return constants[i].value; + } + return UNKNOWN_CONSTANT; +} === added file 'storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.hpp' --- a/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.hpp 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_consts.hpp 2012-04-19 10:46:43 +0000 @@ -0,0 +1,31 @@ +/* + Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 of the License. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +*/ +/* + * ndbjtie_unit_tests_consts.hpp + */ + +#ifndef ndbjtie_unit_tests_consts_hpp +#define ndbjtie_unit_tests_consts_hpp + +// magic value if a constant name is unknown +const long long UNKNOWN_CONSTANT = 0x0abcdef00fedcba0; + +// Returns the integral value of a constant passed by its qualified JVM name, +// or UNKNOWN_CONSTANT if the passed name is unknown to this function. +extern long long nativeConstValue(const char * p0); + +#endif // ndbjtie_unit_tests_consts_hpp === added file 'storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_lib.cpp' --- a/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_lib.cpp 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/ndbjtie_unit_tests_lib.cpp 2012-04-19 10:46:43 +0000 @@ -0,0 +1,99 @@ +/* + Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 of the License. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +*/ +/* + * ndbjtie_unit_tests_lib.cpp + */ + +// libraries +#include "helpers.hpp" +#include "jtie.hpp" +#include "jtie_lib.hpp" + +// the applied Java mapping of basic variable-width C++ types +#define JTIE_JNI_SHORT_T jshort +#define JTIE_JNI_INT_T jint +#define JTIE_JNI_LONG_T jint +#define JTIE_JNI_LONGLONG_T jlong +#define JTIE_JNI_LONGDOUBLE_T jdouble +#include "jtie_tconv_vwidth.hpp" + +// global test ndbjtie_unit_tests library definitions +#include "ndbjtie_unit_tests_consts.hpp" + +// --------------------------------------------------------------------------- +// JNI function stubs +// --------------------------------------------------------------------------- + +// The API stub functions in this file have mangled names that adhere +// to the JVM specification. It is not necessary to include the +// function prototypes generated by the javah tool from the Java source +// if they are declared to receive "C" linkage here. +extern "C" { + +//#include "test_NdbJTieConstantsTest.h" + +/* + * Class: test_NdbJTieConstantsTest + * Method: nativeConstValue + * Signature: (Ljava/lang/String;)J + */ +JNIEXPORT jlong JNICALL +Java_test_NdbJTieConstantsTest_nativeConstValue(JNIEnv * env, jclass cls, jstring p0) +{ + TRACE("jlong Java_test_NdbJTieConstantsTest_nativeConstValue(JNIEnv *, jclass, jstring)"); + return gcall_fr< ttrait_longlong, ttrait_char_cp_jutf8null, &::nativeConstValue >(env, cls, p0); +} + +} // extern "C" + +// --------------------------------------------------------------------------- +// Library Load and Unload Handlers +// --------------------------------------------------------------------------- + +// Initializes the JTie resources; called when the native library is loaded; +// returns the JNI version needed by the native library or JNI_ERR. +JNIEXPORT jint JNICALL +JNI_OnLoad(JavaVM * jvm, void * reserved) +{ + TRACE("jint JNI_OnLoad(JavaVM *, void *)"); + VERBOSE("loading the NDB JTie Unit Test library ..."); + + const jint required_jni_version = JTie_OnLoad(jvm, reserved); + if (required_jni_version == JNI_ERR) { + PRINT_ERROR("JTie_OnLoad() returned: JNI_ERR"); + return JNI_ERR; + } + + VERBOSE("... loaded the NDB JTie Unit Test library"); + return required_jni_version; +} + +// Called when the class loader containing the native library is garbage +// collected; called in an unknown context (such as from a finalizer): +// be conservative, and refrain from arbitrary Java call-backs. +JNIEXPORT void JNICALL +JNI_OnUnload(JavaVM * jvm, void * reserved) +{ + TRACE("void JNI_OnUnload(JavaVM *, void *)"); + VERBOSE("unloading the NDB JTie Unit Test library..."); + + JTie_OnUnload(jvm, reserved); + + VERBOSE("... unloaded the NDB JTie Unit Test library"); +} + +// --------------------------------------------------------------------------- === modified file 'storage/ndb/src/ndbjtie/test/test/JTieTestBase.java' --- a/storage/ndb/src/ndbjtie/test/test/JTieTestBase.java 2012-03-05 07:24:11 +0000 +++ b/storage/ndb/src/ndbjtie/test/test/JTieTestBase.java 2012-04-19 11:20:12 +0000 @@ -30,6 +30,15 @@ public abstract class JTieTestBase { static protected final PrintWriter out = new PrintWriter(System.out, true); static protected final PrintWriter err = new PrintWriter(System.err, true); + // ensure that asserts are enabled + static { + boolean assertsEnabled = false; + assert assertsEnabled = true; // intentional side effect + if (!assertsEnabled) { + throw new RuntimeException("Asserts must be enabled for this test to be effective!"); + } + } + /** * Loads a dynamically linked library. */ === added file 'storage/ndb/src/ndbjtie/test/test/NdbJTieConstantsTest.java' --- a/storage/ndb/src/ndbjtie/test/test/NdbJTieConstantsTest.java 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/test/NdbJTieConstantsTest.java 2012-04-19 10:46:43 +0000 @@ -0,0 +1,205 @@ +/* + Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 of the License. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +*/ +/* + * NdbJTieConstantsTest.java + */ + +package test; + +import java.lang.reflect.Field; +import java.lang.reflect.Modifier; +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.util.List; +import java.util.ArrayList; +import java.util.jar.JarEntry; +import java.util.jar.JarInputStream; + +import com.mysql.ndbjtie.ndbapi.NDBAPI; + +/** + * Verifies the constants in NdbJTie against their values in NDB API. + */ +public class NdbJTieConstantsTest extends JTieTestBase { + + static protected native long nativeConstValue(String constName); + + static protected final String ndbjtie_jar_file_prop + = "test.NdbJTieConstantsTest.ndbjtie_jar_file"; + + static protected final long unknown = 0x0abcdef00fedcba0L; + + protected final List classNames = new ArrayList(); + + protected final List errors = new ArrayList(); + protected int nFields; + protected int nClasses; + protected int nPackages; + + protected void fetchClassNames(String jarFile) { + try { + final JarInputStream jStream + = new JarInputStream(new FileInputStream(jarFile)); + try { + JarEntry e; + while ((e = jStream.getNextJarEntry()) != null) { + final String en = e.getName(); + if (en.endsWith(".class")) { + String cn = en.replace("/", ".").replace("\\", "."); + cn = cn.substring(0, cn.length() - ".class".length()); + classNames.add(cn); + } + jStream.closeEntry(); + } + } finally { + jStream.close(); + } + } catch (IOException e) { + throw new RuntimeException(e); + } + } + + public NdbJTieConstantsTest() { + out.println("--> NdbJTieConstantsTest()"); + + // read properties + final String jar_file + = System.getProperty(ndbjtie_jar_file_prop, "ndbjtie.jar"); + out.println(" settings:"); + out.println(" ndbjtie_jar_file = '" + jar_file + "'"); + + // read classes + out.println(" parsing jar file ..."); + fetchClassNames(jar_file); + out.println(" ... found " + classNames.size() + " classes"); + + out.println("<-- NdbJTieConstantsTest()"); + } + + public void clear() { + errors.clear(); + nFields = 0; + nClasses = 0; + nPackages = 0; + } + + public void validateField(Field f) { + nFields++; + out.println(" " + f.getName()); + final int m = f.getModifiers(); + assert Modifier.isStatic(m); + assert Modifier.isPublic(m); + assert Modifier.isFinal(m); + + final String name = (f.getDeclaringClass().getName() + + "." + f.getName()); + final long expected = nativeConstValue(name); + if (expected == unknown) { + errors.add("unknown constant '" + name + "'"); + return; + } + + final long actual; + try { + actual = f.getLong(null); + } catch (IllegalAccessException e) { + throw new RuntimeException(e); + } + if (expected != actual) { + errors.add("numeric value mismatch for constant '" + name + "'" + + "; expected = " + expected + "; actual = " + actual); + } + } + + public void validateClass(Class c) { + nClasses++; + out.println(" " + c.getName()); + for (Field f : c.getDeclaredFields()) { + validateField(f); + } + } + + public void validatePackage(String pkg) { + nPackages++; + out.println(" validating: " + pkg); + try { + for (String name : classNames) { + if (name.startsWith(pkg)) + validateClass(Class.forName(name)); + } + } catch (ClassNotFoundException e) { + throw new RuntimeException(e); + } + } + + public void test() { + out.println("--> NdbJTieConstantsTest.test()"); + clear(); + + // load native library + out.println(); + loadSystemLibrary("ndbjtie_unit_tests"); + + // test unknown constant + out.println(); + final String n = "_an_unknown_c0nstant_"; + out.println(" validating: " + n); + final long l = nativeConstValue(n); + assert l == 0x0abcdef00fedcba0L; + + // test classes in package + out.println(); + validatePackage("com.mysql.ndbjtie.ndbapi."); + + // report status + out.println(); + out.println(" TEST STATUS:"); + for (String s : errors) + out.println(" !!! " + s); + out.println(" #packages: " + nPackages); + out.println(" #classes: " + nClasses); + out.println(" #fields: " + nFields); + out.println(" #errors: " + errors.size()); + assert errors.isEmpty() : "data errors in test"; + + out.println(); + out.println("<-- NdbJTieConstantsTest.test()"); + }; + + static public void usage() { + out.println("usage:"); + out.println("java -cp :"); + out.println(" -D" + ndbjtie_jar_file_prop + "="); + out.println(" test.NdbJTieConstantsTest"); + System.exit(1); + } + + static public void main(String[] args) throws Exception { + out.println("--> NdbJTieConstantsTest.main()"); + + if (args.length != 0) + usage(); + + out.println(); + NdbJTieConstantsTest test = new NdbJTieConstantsTest(); + test.test(); + + out.println(); + out.println("<-- NdbJTieConstantsTest.main()"); + } +} === modified file 'storage/ndb/src/ndbjtie/test/test/NdbJTieMultiLibTest.java' --- a/storage/ndb/src/ndbjtie/test/test/NdbJTieMultiLibTest.java 2012-03-05 07:24:11 +0000 +++ b/storage/ndb/src/ndbjtie/test/test/NdbJTieMultiLibTest.java 2012-04-19 11:20:12 +0000 @@ -43,6 +43,12 @@ public class NdbJTieMultiLibTest extends out.println(); out.println(" loaded: " + NDBAPI.class); + // load native library and class #3 + out.println(); + loadSystemLibrary("ndbjtie_unit_tests"); + out.println(); + out.println(" loaded: " + NDBAPI.class); + out.println(); out.println("<-- NdbJTieMultiLibTest.test()"); }; === added file 'storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.cmd.in' --- a/storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.cmd.in 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.cmd.in 2012-04-19 10:46:43 +0000 @@ -0,0 +1,83 @@ +@echo off +setlocal +rem Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +rem +rem This program is free software; you can redistribute it and/or modify +rem it under the terms of the GNU General Public License as published by +rem the Free Software Foundation; version 2 of the License. +rem +rem This program is distributed in the hope that it will be useful, +rem but WITHOUT ANY WARRANTY; without even the implied warranty of +rem MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +rem GNU General Public License for more details. +rem +rem You should have received a copy of the GNU General Public License +rem along with this program; if not, write to the Free Software +rem Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +rem redirect all output to logfile +set LOGFILE=%0.log +echo running test... output in file: %CD%\%LOGFILE% +call :doit %1 > %LOGFILE% + +rem calling exit directly will not pass status arg back to calling program; +rem workaround is for literally last command in script be a call to exit +goto :lastCommand + +:doit +rem echo --^> %0 + +rem some build configs place binaries in subdirectories +set BIN_DIR=%1 +if not defined BIN_DIR set BIN_DIR=. +echo all binaries assumed in subdirectory '%BIN_DIR%' + +rem jvm +set JAVA="@Java_JAVA_EXECUTABLE_PATH@" +set JAVA_FLAGS=-ea -Xcheck:jni +set JAVA_ARCH=@Java_JAVA_ARCH_OPT@ +echo checking if JVM arch option %JAVA_ARCH% supported... +%JAVA% %JAVA_ARCH% -version >nul 2>&1 || set JAVA_ARCH= +echo. + +rem this test +set JAVA_CLASS=test.NdbJTieConstantsTest +set TEST_JAR=ndbjtie-test-@JAVA_NDB_VERSION@.jar + +rem dependencies +set NDBJTIE=.. +set NDBJTIE_JAR=%NDBJTIE%\ndbjtie-@JAVA_NDB_VERSION@.jar +set JAVA_CLASSPATH=-classpath "%TEST_JAR%;%NDBJTIE_JAR%" +set JAVA_LIBPATH=-Djava.library.path="%BIN_DIR%" +set JAVA_DEFS="-Dtest.NdbJTieConstantsTest.ndbjtie_jar_file=%NDBJTIE_JAR%" + +echo running +echo. %JAVA% +echo. %JAVA_ARCH% %JAVA_FLAGS% +echo. %JAVA_CLASSPATH% +echo. %JAVA_LIBPATH% +echo. %JAVA_DEFS% +echo. %JAVA_CLASS% + +set TEST=%JAVA% %JAVA_ARCH% %JAVA_FLAGS% ^ + %JAVA_CLASSPATH% %JAVA_LIBPATH% %JAVA_DEFS% %JAVA_CLASS% +rem echo TEST=%TEST% + +rem retain test's exit status when discarding local settings +@echo on +%TEST% +@endlocal & set EXIT_STATUS=%errorlevel% +@echo off + +echo. +echo exit status: %EXIT_STATUS% +rem echo ^<-- %0 +rem goto :lastCommand + +:returnWithStatus +exit /b %EXIT_STATUS% + +rem calling exit directly will not pass status arg back to calling program; +rem workaround is for literally last command in script be a call to exit +:lastCommand +call :returnWithStatus === added file 'storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.sh.in' --- a/storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.sh.in 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_ndbjtie_constants.sh.in 2012-04-19 11:20:12 +0000 @@ -0,0 +1,55 @@ +#!/bin/sh +# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; version 2 of the License. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +LOGFILE="$0.log" +echo "running test... output in file: `pwd`/$LOGFILE" +exec > "$LOGFILE" + +# some build configs place binaries in subdirectories +BIN_DIR=${1:-"."} +echo "all binaries assumed in subdirectory \'$BIN_DIR\'" + +# jvm +JAVA="@Java_JAVA_EXECUTABLE_PATH@" +JAVA_ARCH="@Java_JAVA_ARCH_OPT@" +JAVA_FLAGS="-ea -Xcheck:jni" + +# this test +JAVA_CLASS="test.NdbJTieConstantsTest" +TEST_JAR="ndbjtie-test-@JAVA_NDB_VERSION@.jar" + +# dependencies +NDBJTIE=".." +NDBJTIE_JAR="$NDBJTIE/ndbjtie-@JAVA_NDB_VERSION@.jar" +JAVA_CLASSPATH="-classpath $TEST_JAR:$NDBJTIE_JAR" +JAVA_LIBPATH="-Djava.library.path=$BIN_DIR" +JAVA_DEFS="-Dtest.NdbJTieConstantsTest.ndbjtie_jar_file=$NDBJTIE_JAR" + +TEST=" + $JAVA + $JAVA_ARCH $JAVA_FLAGS + $JAVA_CLASSPATH + $JAVA_LIBPATH + $JAVA_DEFS + $JAVA_CLASS" + +echo "running $TEST" +echo +$TEST +STATUS=$? +echo +echo "exit status: $STATUS" +exit "$STATUS" === modified file 'storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.cmd.in' --- a/storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.cmd.in 2012-03-05 04:19:09 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.cmd.in 2012-04-19 10:46:43 +0000 @@ -51,7 +51,7 @@ set MYJAPI=..\jtie\test\myjapi set NDBJTIE_JAR=%NDBJTIE%\ndbjtie-@JAVA_NDB_VERSION@.jar set MYJAPI_JAR=%MYJAPI%\jtie-test-myjapi-@JAVA_NDB_VERSION@.jar set JAVA_CLASSPATH=-classpath "%TEST_JAR%;%MYJAPI_JAR%;%NDBJTIE_JAR%" -set JAVA_LIBPATH=-Djava.library.path="%MYJAPI%\%BIN_DIR%;%NDBCLIENT%\%BIN_DIR%" +set JAVA_LIBPATH=-Djava.library.path="%MYJAPI%\%BIN_DIR%;%NDBCLIENT%\%BIN_DIR%;%BIN_DIR%" set JAVA_DEFS= echo running === modified file 'storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.sh.in' --- a/storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.sh.in 2012-03-05 08:14:47 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_ndbjtie_multilib.sh.in 2012-04-19 11:20:12 +0000 @@ -38,7 +38,7 @@ MYJAPI="../jtie/test/myjapi" NDBJTIE_JAR="$NDBJTIE/ndbjtie-@JAVA_NDB_VERSION@.jar" MYJAPI_JAR="$MYJAPI/jtie-test-myjapi-@JAVA_NDB_VERSION@.jar" JAVA_CLASSPATH="-classpath $TEST_JAR:$MYJAPI_JAR:$NDBJTIE_JAR" -JAVA_LIBPATH="-Djava.library.path=$MYJAPI/$BIN_DIR:$NDBCLIENT/$BIN_DIR" +JAVA_LIBPATH="-Djava.library.path=$MYJAPI/$BIN_DIR:$NDBCLIENT/$BIN_DIR:$BIN_DIR" JAVA_DEFS="" TEST=" === added file 'storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.cmd.in' --- a/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.cmd.in 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.cmd.in 2012-04-19 10:46:43 +0000 @@ -0,0 +1,85 @@ +@echo off +setlocal +rem Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +rem +rem This program is free software; you can redistribute it and/or modify +rem it under the terms of the GNU General Public License as published by +rem the Free Software Foundation; version 2 of the License. +rem +rem This program is distributed in the hope that it will be useful, +rem but WITHOUT ANY WARRANTY; without even the implied warranty of +rem MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +rem GNU General Public License for more details. +rem +rem You should have received a copy of the GNU General Public License +rem along with this program; if not, write to the Free Software +rem Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +rem redirect all output to logfile +set LOGFILE=%0.log +echo running test... output in file: %CD%\%LOGFILE% +call :doit %1 > %LOGFILE% + +rem calling exit directly will not pass status arg back to calling program; +rem workaround is for literally last command in script be a call to exit +goto :lastCommand + +:doit +rem echo --^> %0 + +rem some build configs place binaries in subdirectories +set BIN_DIR=%1 +if not defined BIN_DIR set BIN_DIR=. +echo all binaries assumed in subdirectory '%BIN_DIR%' + +rem jvm +set JAVA="@Java_JAVA_EXECUTABLE_PATH@" +set JAVA_FLAGS=-ea -Xcheck:jni +set JAVA_ARCH=@Java_JAVA_ARCH_OPT@ +echo checking if JVM arch option %JAVA_ARCH% supported... +%JAVA% %JAVA_ARCH% -version >nul 2>&1 || set JAVA_ARCH= +echo. + +rem this test +set JAVA_CLASS=test.MyLoadUnloadTest +set UNLOAD_TEST_JAR=..\jtie\test\unload\jtie-test-unload-@JAVA_NDB_VERSION@.jar + +rem dependencies +set NDBJTIE=.. +set NDBJTIE_JAR=%NDBJTIE%\ndbjtie-@JAVA_NDB_VERSION@.jar +set NDBJTIE_TEST_JAR=ndbjtie-test-@JAVA_NDB_VERSION@.jar +set JAVA_CLASSPATH=-classpath "%UNLOAD_TEST_JAR%;%NDBJTIE_TEST_JAR%;%NDBJTIE_JAR%" +set JAVA_LIBPATH=-Djava.library.path="%BIN_DIR%" +set JAVA_DEFS=-Dcom.mysql.jtie.test.MyLoadUnloadTest.target_package_prefixes=test.,myjapi.,com.mysql.ndbjtie. -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_class_name=test.NdbJTieConstantsTest -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_method_name=test +set JAVA_DEFS=%JAVA_DEFS% -Dtest.NdbJTieConstantsTest.ndbjtie_jar_file="%NDBJTIE_JAR%" + +echo running +echo. %JAVA% +echo. %JAVA_ARCH% %JAVA_FLAGS% +echo. %JAVA_CLASSPATH% +echo. %JAVA_LIBPATH% +echo. %JAVA_DEFS% +echo. %JAVA_CLASS% + +set TEST=%JAVA% %JAVA_ARCH% %JAVA_FLAGS% ^ + %JAVA_CLASSPATH% %JAVA_LIBPATH% %JAVA_DEFS% %JAVA_CLASS% +rem echo TEST=%TEST% + +rem retain test's exit status when discarding local settings +@echo on +%TEST% +@endlocal & set EXIT_STATUS=%errorlevel% +@echo off + +echo. +echo exit status: %EXIT_STATUS% +rem echo ^<-- %0 +rem goto :lastCommand + +:returnWithStatus +exit /b %EXIT_STATUS% + +rem calling exit directly will not pass status arg back to calling program; +rem workaround is for literally last command in script be a call to exit +:lastCommand +call :returnWithStatus === added file 'storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.sh.in' --- a/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.sh.in 1970-01-01 00:00:00 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_constants.sh.in 2012-04-19 11:20:12 +0000 @@ -0,0 +1,57 @@ +#!/bin/sh +# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; version 2 of the License. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +LOGFILE="$0.log" +echo "running test... output in file: `pwd`/$LOGFILE" +exec > "$LOGFILE" + +# some build configs place binaries in subdirectories +BIN_DIR=${1:-"."} +echo "all binaries assumed in subdirectory \'$BIN_DIR\'" + +# jvm +JAVA="@Java_JAVA_EXECUTABLE_PATH@" +JAVA_ARCH="@Java_JAVA_ARCH_OPT@" +JAVA_FLAGS="-ea -Xcheck:jni" + +# this test +JAVA_CLASS="test.MyLoadUnloadTest" +UNLOAD_TEST_JAR="../jtie/test/unload/jtie-test-unload-@JAVA_NDB_VERSION@.jar" + +# dependencies +NDBJTIE=".." +NDBJTIE_JAR="$NDBJTIE/ndbjtie-@JAVA_NDB_VERSION@.jar" +NDBJTIE_TEST_JAR="ndbjtie-test-@JAVA_NDB_VERSION@.jar" +JAVA_CLASSPATH="-classpath $UNLOAD_TEST_JAR:$NDBJTIE_TEST_JAR:$NDBJTIE_JAR" +JAVA_LIBPATH="-Djava.library.path=$BIN_DIR" +JAVA_DEFS="-Dcom.mysql.jtie.test.MyLoadUnloadTest.target_package_prefixes=test.,com.mysql.ndbjtie. -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_class_name=test.NdbJTieConstantsTest -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_method_name=test" +JAVA_DEFS="$JAVA_DEFS -Dtest.NdbJTieConstantsTest.ndbjtie_jar_file=$NDBJTIE_JAR" + +TEST=" + $JAVA + $JAVA_ARCH $JAVA_FLAGS + $JAVA_CLASSPATH + $JAVA_LIBPATH + $JAVA_DEFS + $JAVA_CLASS" + +echo "running $TEST" +echo +$TEST +STATUS=$? +echo +echo "exit status: $STATUS" +exit "$STATUS" === modified file 'storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.cmd.in' --- a/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.cmd.in 2012-03-05 04:19:09 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.cmd.in 2012-04-19 10:46:43 +0000 @@ -52,7 +52,7 @@ set NDBJTIE_JAR=%NDBJTIE%\ndbjtie-@JAVA_ set MYJAPI_JAR=%MYJAPI%\jtie-test-myjapi-@JAVA_NDB_VERSION@.jar set NDBJTIE_TEST_JAR=ndbjtie-test-@JAVA_NDB_VERSION@.jar set JAVA_CLASSPATH=-classpath "%UNLOAD_TEST_JAR%;%NDBJTIE_TEST_JAR%;%MYJAPI_JAR%;%NDBJTIE_JAR%" -set JAVA_LIBPATH=-Djava.library.path="%MYJAPI%\%BIN_DIR%;%NDBCLIENT%\%BIN_DIR%" +set JAVA_LIBPATH=-Djava.library.path="%MYJAPI%\%BIN_DIR%;%NDBCLIENT%\%BIN_DIR%;%BIN_DIR%" set JAVA_DEFS=-Dcom.mysql.jtie.test.MyLoadUnloadTest.target_package_prefixes=test.,myjapi.,com.mysql.ndbjtie. -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_class_name=test.NdbJTieMultiLibTest -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_method_name=test echo running === modified file 'storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.sh.in' --- a/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.sh.in 2012-03-05 08:14:47 +0000 +++ b/storage/ndb/src/ndbjtie/test/test_unload_ndbjtie_multilib.sh.in 2012-04-19 11:20:12 +0000 @@ -39,7 +39,7 @@ NDBJTIE_JAR="$NDBJTIE/ndbjtie-@JAVA_NDB_ MYJAPI_JAR="$MYJAPI/jtie-test-myjapi-@JAVA_NDB_VERSION@.jar" NDBJTIE_TEST_JAR="ndbjtie-test-@JAVA_NDB_VERSION@.jar" JAVA_CLASSPATH="-classpath $UNLOAD_TEST_JAR:$NDBJTIE_TEST_JAR:$MYJAPI_JAR:$NDBJTIE_JAR" -JAVA_LIBPATH="-Djava.library.path=$MYJAPI/$BIN_DIR:$NDBCLIENT/$BIN_DIR" +JAVA_LIBPATH="-Djava.library.path=$MYJAPI/$BIN_DIR:$NDBCLIENT/$BIN_DIR:$BIN_DIR" JAVA_DEFS="-Dcom.mysql.jtie.test.MyLoadUnloadTest.target_package_prefixes=test.,myjapi.,com.mysql.ndbjtie. -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_class_name=test.NdbJTieMultiLibTest -Dcom.mysql.jtie.test.MyLoadUnloadTest.target_method_name=test" TEST=" No bundle (reason: useless for push emails).