Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into 4529-sql-logger-shutdown
Browse files Browse the repository at this point in the history
  • Loading branch information
aleks-f committed Jul 15, 2024
2 parents c3cbcaa + 2442c66 commit 75b52e1
Show file tree
Hide file tree
Showing 781 changed files with 47,597 additions and 4,526 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ jobs:
timeout_minutes: 90
max_attempts: 3
retry_on: any
command: .\buildwin.ps1 -poco_base . -vs 170 -action build -linkmode all -config release -platform x64 -samples -tests -omit "Crypto,NetSSL_OpenSSL,Data/MySQL,Data/PostgreSQL,JWT"
command: .\buildwin.ps1 -poco_base . -vs 170 -action build -linkmode all -config release -platform x64 -samples -tests -omit "Crypto,NetSSL_OpenSSL,Data/MySQL,Data/PostgreSQL,JWT,DNSSD,DNSSD/Avahi,DNSSD/Bonjour"

# windows-2022-msvc-buildwin-win32:
# runs-on: windows-2022
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-buildscript.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env bash

sudo apt-get -y update && sudo apt-get -y install cmake ninja-build libssl-dev unixodbc-dev libmysqlclient-dev redis-server
cmake -H. -Bcmake-build -GNinja -DENABLE_PDF=OFF -DENABLE_TESTS=ON && cmake --build cmake-build --target all
cmake -H. -Bcmake-build -GNinja -DENABLE_PDF=OFF -DENABLE_DNSSD=OFF -DENABLE_TESTS=ON && cmake --build cmake-build --target all
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,9 @@ lib/
lib64/
pocomsg.h
**/UpgradeLog*.XML
/out/build/x64-Debug
.vs/
vcpkg_installed/

# Eclipse generated files #
###########################
Expand Down Expand Up @@ -163,3 +166,7 @@ node_modules
*_vs1[45]0.sln
*_vs1[45]0.vcxproj
*_vs1[45]0.vcxproj.filters

# Debug files #
##############
*.core
Empty file removed .gitmodules
Empty file.
2 changes: 1 addition & 1 deletion ActiveRecord/ActiveRecord_vs160.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@
</ImportGroup>
<PropertyGroup Label="UserMacros"/>
<PropertyGroup>
<_ProjectFileVersion>17.0.34511.75</_ProjectFileVersion>
<_ProjectFileVersion>17.0.34714.143</_ProjectFileVersion>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">PocoActiveRecordd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">PocoActiveRecordmdd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">PocoActiveRecordmtd</TargetName>
Expand Down
6 changes: 3 additions & 3 deletions ActiveRecord/ActiveRecord_vs160.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="ActiveRecord">
<UniqueIdentifier>{e1ff1256-5ffb-4edf-b636-f0ae436cd880}</UniqueIdentifier>
<UniqueIdentifier>{28e9724f-5a4c-4c6c-9ff9-c03dd3fab312}</UniqueIdentifier>
</Filter>
<Filter Include="ActiveRecord\Header Files">
<UniqueIdentifier>{878bb6cf-d0f0-43f3-80be-a6c49e7fcdc0}</UniqueIdentifier>
<UniqueIdentifier>{f3dbcbad-f18a-41fe-ad06-4f4b13ab7051}</UniqueIdentifier>
</Filter>
<Filter Include="ActiveRecord\Source Files">
<UniqueIdentifier>{4ee94537-e10b-4905-9e08-83a9aa0c19ac}</UniqueIdentifier>
<UniqueIdentifier>{682e7890-682a-4823-9887-8a9bae670c6e}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion ActiveRecord/ActiveRecord_vs170.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@
</ImportGroup>
<PropertyGroup Label="UserMacros"/>
<PropertyGroup>
<_ProjectFileVersion>17.0.34322.80</_ProjectFileVersion>
<_ProjectFileVersion>17.0.34714.143</_ProjectFileVersion>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|ARM64'">PocoActiveRecordA64d</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|ARM64'">PocoActiveRecordmdd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|ARM64'">PocoActiveRecordmtd</TargetName>
Expand Down
6 changes: 3 additions & 3 deletions ActiveRecord/ActiveRecord_vs170.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="ActiveRecord">
<UniqueIdentifier>{432c214a-0240-4551-855e-81f76d8d4e8a}</UniqueIdentifier>
<UniqueIdentifier>{38b6790a-2ce1-4c5b-a80a-78d45abd59b8}</UniqueIdentifier>
</Filter>
<Filter Include="ActiveRecord\Header Files">
<UniqueIdentifier>{1ecf12a7-37ea-4377-af01-5d99e9bb31bb}</UniqueIdentifier>
<UniqueIdentifier>{e51d8828-dc56-4f93-8c93-4a621baddefb}</UniqueIdentifier>
</Filter>
<Filter Include="ActiveRecord\Source Files">
<UniqueIdentifier>{14c6f1ce-7977-42bb-a83d-deee9c09a926}</UniqueIdentifier>
<UniqueIdentifier>{3a7e31e2-021a-440c-a405-c3d59c6736c5}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion ActiveRecord/Compiler/Compiler_vs160.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@
</ImportGroup>
<PropertyGroup Label="UserMacros"/>
<PropertyGroup>
<_ProjectFileVersion>17.0.34511.75</_ProjectFileVersion>
<_ProjectFileVersion>17.0.34714.143</_ProjectFileVersion>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">poco-arcd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">poco-arcd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">poco-arcd</TargetName>
Expand Down
4 changes: 2 additions & 2 deletions ActiveRecord/Compiler/Compiler_vs160.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{53cccc79-2fa5-454a-8962-a80b8e772eaa}</UniqueIdentifier>
<UniqueIdentifier>{33844d19-e50e-4703-9837-046a25d0996e}</UniqueIdentifier>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{809ee132-09bd-4dad-8c59-e88977d7f12c}</UniqueIdentifier>
<UniqueIdentifier>{4920a70b-4aba-4747-9fef-eb2a648f96d0}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion ActiveRecord/Compiler/Compiler_vs170.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@
</ImportGroup>
<PropertyGroup Label="UserMacros"/>
<PropertyGroup>
<_ProjectFileVersion>17.0.34322.80</_ProjectFileVersion>
<_ProjectFileVersion>17.0.34714.143</_ProjectFileVersion>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|ARM64'">poco-arcd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|ARM64'">poco-arcd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|ARM64'">poco-arcd</TargetName>
Expand Down
4 changes: 2 additions & 2 deletions ActiveRecord/Compiler/Compiler_vs170.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{780c9034-0153-453b-8791-d4659eb8554d}</UniqueIdentifier>
<UniqueIdentifier>{cc7f6445-2867-4c10-8ea1-bbd8dde5b5d9}</UniqueIdentifier>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{c0be2d0e-ae4e-4573-9dcf-dc5821858595}</UniqueIdentifier>
<UniqueIdentifier>{bdfa9b3c-2ffd-4d92-82c5-13b69572aa19}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
Expand Down
9 changes: 5 additions & 4 deletions ActiveRecord/include/Poco/ActiveRecord/ActiveRecord.h
Original file line number Diff line number Diff line change
Expand Up @@ -240,23 +240,24 @@ template <typename IDType>
IDType ActiveRecord<IDType>::lastInsertID(Poco::Data::Session& session)
{
using namespace Poco::Data::Keywords;
using namespace std::string_literals;

IDType id;
if (session.connector() == "sqlite")
if (Poco::icompare(session.connector(), "sqlite"s) == 0)
{
session
<< "SELECT last_insert_rowid()",
into(id),
now;
}
else if (session.connector() == "PostgreSQL")
else if (Poco::icompare(session.connector(), "postgresql"s) == 0)
{
session
<< "SELECT currval('id_seq')",
<< "SELECT lastval()",
into(id),
now;
}
else if (session.connector() == "MySQL")
else if (Poco::icompare(session.connector(), "mysql"s) == 0)
{
session
<< "SELECT LAST_INSERT_ID()",
Expand Down
5 changes: 4 additions & 1 deletion ActiveRecord/src/Context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
#include "Poco/ActiveRecord/Context.h"


using namespace std::string_literals;


namespace Poco {
namespace ActiveRecord {

Expand All @@ -33,7 +36,7 @@ Context::Context(const std::string& connector, const std::string& connectionStri

StatementPlaceholderProvider::Ptr Context::statementPlaceholderProvider() const
{
if (_session.connector() == "postgresql")
if (Poco::icompare(_session.connector(), "postgresql"s) == 0)
return std::make_unique<PostgresStatementPlaceholderProvider>();
else
return std::make_unique<DefaultStatementPlaceholderProvider>();
Expand Down
2 changes: 1 addition & 1 deletion ActiveRecord/testsuite/TestSuite_vs160.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@
</ImportGroup>
<PropertyGroup Label="UserMacros"/>
<PropertyGroup>
<_ProjectFileVersion>17.0.34511.75</_ProjectFileVersion>
<_ProjectFileVersion>17.0.34714.143</_ProjectFileVersion>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestSuited</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">TestSuited</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">TestSuited</TargetName>
Expand Down
8 changes: 4 additions & 4 deletions ActiveRecord/testsuite/TestSuite_vs160.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{18d9df2e-b44e-46a1-89f9-1f2f0d2e816f}</UniqueIdentifier>
<UniqueIdentifier>{81c689e6-8edf-4f29-bcb5-e048a0c0ced9}</UniqueIdentifier>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{5bf0e9d1-a181-47a6-828b-209f7d33b194}</UniqueIdentifier>
<UniqueIdentifier>{ec1ee6d2-7001-4990-880c-c02962bdd5ae}</UniqueIdentifier>
</Filter>
<Filter Include="Generated Header Files">
<UniqueIdentifier>{b59d4ea7-d1c4-42f0-ac59-f4419cbaabdf}</UniqueIdentifier>
<UniqueIdentifier>{1515aae1-a238-472d-ae2e-34e5b90340aa}</UniqueIdentifier>
</Filter>
<Filter Include="Generated Source Files">
<UniqueIdentifier>{680e519d-37d6-412a-aacc-21c82caa59d3}</UniqueIdentifier>
<UniqueIdentifier>{a0fc37c9-ef00-428f-a9f1-35833cc33f29}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
Expand Down
Loading

0 comments on commit 75b52e1

Please sign in to comment.