From 144884bf96885dce0bff3c1f7ef97718e8dd66ed Mon Sep 17 00:00:00 2001 From: andiem-bq <67925459+andiem-bq@users.noreply.github.com> Date: Fri, 25 Feb 2022 10:52:05 -0800 Subject: [PATCH] [AD-620] Change driver name in windows installer, development scripts, dsn dialog and enabled tests (#32) --- scripts/register_driver_macos.sh | 4 ++-- src/odbc-test/src/connection_test.cpp | 4 ++-- src/odbc-test/src/odbc_test_suite.cpp | 2 +- src/odbc/CMakeLists.txt | 8 ++++---- src/odbc/install/ignite-odbc-install.ini | 4 ++-- src/odbc/install/ignite-odbc.wxs.in | 6 +++--- src/odbc/install/install_amd64.cmd | 20 ++++++++++---------- src/odbc/install/install_x86.cmd | 10 +++++----- src/odbc/src/config/configuration.cpp | 3 +-- src/odbc/src/config/connection_info.cpp | 6 +++--- 10 files changed, 33 insertions(+), 34 deletions(-) diff --git a/scripts/register_driver_macos.sh b/scripts/register_driver_macos.sh index a5f4f6005..3552936c8 100644 --- a/scripts/register_driver_macos.sh +++ b/scripts/register_driver_macos.sh @@ -18,8 +18,8 @@ then exit 1 fi -echo "[Apache Ignite]" > "$ODBC_LIB_PATH/ignite-odbc-install.ini" -echo "Description=Apache Ignite" >> "$ODBC_LIB_PATH/ignite-odbc-install.ini" +echo "[Amazon DocumentDB]" > "$ODBC_LIB_PATH/ignite-odbc-install.ini" +echo "Description=Amazon DocumentDB" >> "$ODBC_LIB_PATH/ignite-odbc-install.ini" echo "Driver=$ODBC_LIB_FILENAME" >> "$ODBC_LIB_PATH/ignite-odbc-install.ini" echo "Setup=$ODBC_LIB_FILENAME" >> "$ODBC_LIB_PATH/ignite-odbc-install.ini" echo "DriverODBCVer=03.00" >> "$ODBC_LIB_PATH/ignite-odbc-install.ini" diff --git a/src/odbc-test/src/connection_test.cpp b/src/odbc-test/src/connection_test.cpp index f40965467..3da373031 100644 --- a/src/odbc-test/src/connection_test.cpp +++ b/src/odbc-test/src/connection_test.cpp @@ -113,7 +113,7 @@ BOOST_AUTO_TEST_CASE(TestConnectionRestoreMiscOptionsSet) { BOOST_AUTO_TEST_CASE(TestConnectionIncompleteBasicProperties) { std::string connectionString = - "DRIVER={Apache Ignite};" + "DRIVER={Amazon DocumentDB};" "HOSTNAME=localhost;" "USER=user;" "PASSWORD=password;"; @@ -127,7 +127,7 @@ BOOST_AUTO_TEST_CASE(TestConnectionIncompleteBasicProperties) { BOOST_AUTO_TEST_CASE(TestConnectionIncompleteSSHTunnelProperties) { std::string connectionString = - "DRIVER={Apache Ignite};" + "DRIVER={Amazon DocumentDB};" "HOSTNAME=host.com;" "DATABASE=test;" "USER=user;" diff --git a/src/odbc-test/src/odbc_test_suite.cpp b/src/odbc-test/src/odbc_test_suite.cpp index facf1535a..7602368a9 100644 --- a/src/odbc-test/src/odbc_test_suite.cpp +++ b/src/odbc-test/src/odbc_test_suite.cpp @@ -802,7 +802,7 @@ void OdbcTestSuite::CreateDsnConnectionString( } connectionString = - "DRIVER={Apache Ignite};" + "DRIVER={Amazon DocumentDB};" "HOSTNAME=" + host + ":" + port + ";" "DATABASE=test;" "USER=" + user + ";" diff --git a/src/odbc/CMakeLists.txt b/src/odbc/CMakeLists.txt index 1d5f7051e..af30271c9 100644 --- a/src/odbc/CMakeLists.txt +++ b/src/odbc/CMakeLists.txt @@ -158,8 +158,8 @@ if (WIN32 AND ${WITH_ODBC_MSI}) set(WIX_ODBC_LIBRARY_PATH ".\\ignite.odbc.dll") - set(WIX_PROJECT_NAME "Apache Ignite") - set(WIX_MANUFACTURER "The Apache Software Foundation") + set(WIX_PROJECT_NAME "Amazon DocumentDB") + set(WIX_MANUFACTURER "Amazon Web Services") set(WIX_COPYRIGHT_COMMENT "Apache, Apache Ignite, the Apache feather and the Apache Ignite logo are trademarks of The Apache Software Foundation.") if(CMAKE_SIZEOF_VOID_P EQUAL 8) @@ -170,7 +170,7 @@ if (WIN32 AND ${WITH_ODBC_MSI}) set(WIX_PROGRAM_FILES_FOLDER_ID "ProgramFiles64Folder") set(WIX_COMPONENT_IS_WIN64 "yes") set(WIX_PACKAGE_PLATFORM "x64") - set(WIX_INSTALLER_PREFIX ${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/ignite-odbc-amd64) + set(WIX_INSTALLER_PREFIX ${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/documentdb-odbc-amd64) elseif(CMAKE_SIZEOF_VOID_P EQUAL 4) set(WIX_BIT_SUFFIX "32-bit") set(WIX_PRODUCT_ID "D39CBABA-1E21-4701-AA5C-91EDA07B383B") @@ -179,7 +179,7 @@ if (WIN32 AND ${WITH_ODBC_MSI}) set(WIX_PROGRAM_FILES_FOLDER_ID "ProgramFilesFolder") set(WIX_COMPONENT_IS_WIN64 "no") set(WIX_PACKAGE_PLATFORM "x86") - set(WIX_INSTALLER_PREFIX ${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/ignite-odbc-x86) + set(WIX_INSTALLER_PREFIX ${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE}/documentdb-odbc-x86) endif() set(WIX_PRODUCT_NAME "${WIX_PROJECT_NAME} ODBC ${WIX_BIT_SUFFIX} Driver") diff --git a/src/odbc/install/ignite-odbc-install.ini b/src/odbc/install/ignite-odbc-install.ini index f512fb486..4e7735861 100644 --- a/src/odbc/install/ignite-odbc-install.ini +++ b/src/odbc/install/ignite-odbc-install.ini @@ -1,5 +1,5 @@ -[Apache Ignite] -Description=Apache Ignite +[Amazon DocumentDB] +Description=Amazon DocumentDB Driver=/usr/local/lib/libignite-odbc.so Setup=/usr/local/lib/libignite-odbc.so DriverODBCVer=03.00 diff --git a/src/odbc/install/ignite-odbc.wxs.in b/src/odbc/install/ignite-odbc.wxs.in index a3dc84d54..1cc005295 100644 --- a/src/odbc/install/ignite-odbc.wxs.in +++ b/src/odbc/install/ignite-odbc.wxs.in @@ -32,14 +32,14 @@ - + - + - + diff --git a/src/odbc/install/install_amd64.cmd b/src/odbc/install/install_amd64.cmd index 5795e0cf8..d4884bede 100644 --- a/src/odbc/install/install_amd64.cmd +++ b/src/odbc/install/install_amd64.cmd @@ -14,11 +14,11 @@ if exist %ODBC_AMD64% ( echo warning: The path you have specified seems to be a directory. Note that you have to specify path to driver file itself instead. ) echo Installing 64-bit driver: %ODBC_AMD64% - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v DriverODBCVer /t REG_SZ /d "03.80" /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v UsageCount /t REG_DWORD /d 00000001 /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v Driver /t REG_SZ /d %ODBC_AMD64% /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v Setup /t REG_SZ /d %ODBC_AMD64% /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers" /v "Apache Ignite" /t REG_SZ /d "Installed" /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v DriverODBCVer /t REG_SZ /d "03.80" /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v UsageCount /t REG_DWORD /d 00000001 /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v Driver /t REG_SZ /d %ODBC_AMD64% /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v Setup /t REG_SZ /d %ODBC_AMD64% /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers" /v "Amazon DocumentDB" /t REG_SZ /d "Installed" /f ) else ( echo 64-bit driver can not be found: %ODBC_AMD64% echo Call format: install_amd64 abs_path_to_64_bit_driver [abs_path_to_32_bit_driver] @@ -37,11 +37,11 @@ if exist %ODBC_X86% ( echo warning: The path you have specified seems to be a directory. Note that you have to specify path to driver file itself instead. ) echo Installing 32-bit driver: %ODBC_X86% - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Apache Ignite" /v DriverODBCVer /t REG_SZ /d "03.80" /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Apache Ignite" /v UsageCount /t REG_DWORD /d 00000001 /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Apache Ignite" /v Driver /t REG_SZ /d %ODBC_X86% /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Apache Ignite" /v Setup /t REG_SZ /d %ODBC_X86% /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\ODBC Drivers" /v "Apache Ignite" /t REG_SZ /d "Installed" /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Amazon DocumentDB" /v DriverODBCVer /t REG_SZ /d "03.80" /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Amazon DocumentDB" /v UsageCount /t REG_DWORD /d 00000001 /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Amazon DocumentDB" /v Driver /t REG_SZ /d %ODBC_X86% /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\Amazon DocumentDB" /v Setup /t REG_SZ /d %ODBC_X86% /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\ODBC\ODBCINST.INI\ODBC Drivers" /v "Amazon DocumentDB" /t REG_SZ /d "Installed" /f ) else ( echo warning: 32-bit driver can not be found: %ODBC_X86% exit /b 1 diff --git a/src/odbc/install/install_x86.cmd b/src/odbc/install/install_x86.cmd index af0f8152e..682639b1e 100644 --- a/src/odbc/install/install_x86.cmd +++ b/src/odbc/install/install_x86.cmd @@ -13,11 +13,11 @@ if exist %ODBC% ( echo warning: The path you have specified seems to be a directory. Note that you have to specify path to driver file itself instead. ) echo Installing driver: %ODBC% - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v DriverODBCVer /t REG_SZ /d "03.80" /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v UsageCount /t REG_DWORD /d 00000001 /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v Driver /t REG_SZ /d %ODBC% /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Apache Ignite" /v Setup /t REG_SZ /d %ODBC% /f - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers" /v "Apache Ignite" /t REG_SZ /d "Installed" /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v DriverODBCVer /t REG_SZ /d "03.80" /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v UsageCount /t REG_DWORD /d 00000001 /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v Driver /t REG_SZ /d %ODBC% /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\Amazon DocumentDB" /v Setup /t REG_SZ /d %ODBC% /f + reg add "HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBCINST.INI\ODBC Drivers" /v "Amazon DocumentDB" /t REG_SZ /d "Installed" /f ) else ( echo Driver can not be found: %ODBC% echo Call format: install_x86 abs_path_to_driver diff --git a/src/odbc/src/config/configuration.cpp b/src/odbc/src/config/configuration.cpp index 0c9d62d2c..131b191d7 100644 --- a/src/odbc/src/config/configuration.cpp +++ b/src/odbc/src/config/configuration.cpp @@ -32,8 +32,7 @@ namespace odbc { namespace config { // Connection Settings const std::string Configuration::DefaultValue::dsn = "DocumentDB DSN"; -const std::string Configuration::DefaultValue::driver = - "Amazon DocumentDB ODBC Driver"; +const std::string Configuration::DefaultValue::driver = "Amazon DocumentDB"; const std::string Configuration::DefaultValue::database = ""; const std::string Configuration::DefaultValue::hostname = ""; const uint16_t Configuration::DefaultValue::port = 27017; diff --git a/src/odbc/src/config/connection_info.cpp b/src/odbc/src/config/connection_info.cpp index b4d35afda..11d5695af 100644 --- a/src/odbc/src/config/connection_info.cpp +++ b/src/odbc/src/config/connection_info.cpp @@ -584,10 +584,10 @@ ConnectionInfo::ConnectionInfo(const Configuration& config) // Driver name. #ifdef SQL_DRIVER_NAME - strParams[SQL_DRIVER_NAME] = "Apache Ignite"; + strParams[SQL_DRIVER_NAME] = "Amazon DocumentDB"; #endif // SQL_DRIVER_NAME #ifdef SQL_DBMS_NAME - strParams[SQL_DBMS_NAME] = "Apache Ignite"; + strParams[SQL_DBMS_NAME] = "Amazon DocumentDB"; #endif // SQL_DBMS_NAME // ODBC version. @@ -832,7 +832,7 @@ ConnectionInfo::ConnectionInfo(const Configuration& config) // A character string with the actual data source-specific server name; useful // when a data source name is used during SQLConnect, SQLDriverConnect, and // SQLBrowseConnect. - strParams[SQL_SERVER_NAME] = "Apache Ignite"; + strParams[SQL_SERVER_NAME] = "Amazon DocumentDB"; #endif // SQL_SERVER_NAME #ifdef SQL_USER_NAME