Skip to content

feat(RemotingNG): add RemotingNG and CodeGeneration from macchina.io #5447 - #5483

Merged
matejk merged 14 commits into
mainfrom
5447-remotingng
Sep 24, 2026
Merged

matejk merged 14 commits into
mainfrom
5447-remotingng

Conversation

@matejk

@matejk matejk commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Imports RemotingNG (core; the TCP, HTTP, JSONRPC, REST and SOAP transports; the RemoteGenNG code generator) and CodeGeneration from macchina.io into POCO 2.0, with both build systems, CI, six testsuites, seventeen samples and the documentation pages.

Closes #5447

Source and consolidation

  • Flat import of the current code of the two macchina.io lineages: the Aleph ONE fork as the base plus the four functional Applied Informatics commits since their common base (ULID support and its test, the deprecated-constant renames, removal of the unused WinDriver files). The history stays in the macchina.io repositories; the four Applied Informatics commits keep their authorship.
  • The fork adaptations required by POCO main are included: the top-level Poco::Net::ProxyConfig in the four HTTP-based transports, the TCP ChannelStream update, alternation in REST path templates.
  • The POCO_REQUIRE_LICENSE blocks and the POCO_LICENSING make variable are removed.

Integration

  • CMake options ENABLE_CODEGENERATION, ENABLE_REMOTINGNG and ENABLE_REMOTINGNG_{TCP,HTTP,JSONRPC,REST,SOAP,REMOTEGEN}, ON unless POCO_MINIMAL_BUILD, with dependency forcing as for the other components; Poco<Component>Config.cmake package files with find_dependency; the components file, the top-level Makefile and the full CI builds in ci.yml updated.
  • RemoteGenNG is built without the debug postfix and installed to bin/ together with its RemoteGenNG.xml; the configuration lists the POCO include paths only (-DPOCO_BASE=... at run time).
  • Testsuites use poco_add_executable and the CPPIGNORE_FILE selection; the transport suites listen on distinct ports (HTTP 2280, JSONRPC 2281, REST 2282, SOAP 2283, TCP 2345), so ctest -j works.
  • Poco::Event(bool) replaced by Poco::Event(EventType) (removed in 2.0).

Fixes found during verification

  • EventDispatcher lifetime: the ORB handed out counted references to a remote object and to its event dispatcher separately, while the generated dispatchers hold the object by raw pointer and unsubscribe in their destructor; ASan reported a heap-use-after-free in the TCP event test. The ORB now keeps the remote object alive while a dispatcher references it.
  • SOAP testsuite operator== made const (-Wambiguous-reversed-operator); guard in the XSD generator for accessor names shorter than four characters.

Licensing

All files carry the POCO license: the Applied Informatics license line (173 files) and the "unpublished proprietary source code" paragraph (238 files) were replaced by SPDX-License-Identifier: BSL-1.0; the copyright lines stay. Generated sample sources carry only the copyright line the generator writes; the ONVIF WSDL/XSD files keep their ONVIF notice.

Verification

  • macOS clang: full build, the seven suites sequentially and with -j8 (675 CppUnit cases).
  • Linux GCC 15 release, clang 21 static (BUILD_SHARED_LIBS=OFF), ASan/UBSan (clean after the dispatcher fix), GNU make through the top-level Makefile (8 components, 7 testrunners), cppcheck.
  • Code generator round trip: RemoteGenNG regenerates the checked-in testsuite and sample sources byte-identically (36 + 12 files); installed layout and a find_package(PocoRemotingNGTCP) consumer verified.
  • A downstream OSP-based application was built and linked against Poco::RemotingNG and Poco::RemotingNGTCP from this branch.
  • Not built on Windows locally; the CI full builds cover it.

JS/Bridge (#5451) and the OSP repository depend on this import.

Fixes after the first CI run

  • Tests with ENABLE_TRACE=ON (all sanitizer jobs and the Windows full build): Poco::Exception appends a backtrace to message(), so the literal message comparisons in the RemotingNG testsuites failed. CppUnit gained assertMessageEqual(expected, actual): exact without trace; with trace only the backtrace may follow the expected text (or ": " plus the backtrace of an empty nested message). The testsuites use it; the JSON fault tests build their expected documents with Poco::toJSON, and the SOAP fault tests strip the backtraces before the exact comparison.
  • Hidden symbol visibility (hidden-asan jobs): the seven *_API macros gained the GCC visibility("default") branch, and Util's explicit instantiation of Poco::BasicEvent<const std::string, Poco::FastMutex> (enh: reduce binary size across all libraries #5292 #5297) is now exported by declaring it before its first use, because GCC ignores a visibility attribute attached after the type has been instantiated.
  • Modules job: modules/Poco/CppParser.cppm lacked the AttributesParser.h include; RemotingNG enables CppParser by default, which exposed it.
  • TSan lock-order inversion: the ORB destroyed event dispatchers and called listeners while holding _mutex; all unregister paths now release the lock first.
  • CodeQL: the five dead poco_check_ptr checks after new in RemoteGenNG are removed and the SOAP serializer clears its MTOM parts on reset. The remaining alerts are style notes or pre-existing code that the build now compiles.

@matejk matejk added this to the Release 2.0 milestone Sep 15, 2026
@matejk matejk added the feature label Sep 15, 2026

@github-advanced-security github-advanced-security AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CodeQL found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

SOAP packaging omits a required dependency, RemoteGen metadata is incomplete, and the CodeGeneration tests contain empty placeholders.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Imports CodeGeneration and the RemotingNG framework, transports, generator, tests, samples, documentation, and build integration for POCO 2.0.

Changes:

  • Adds RemotingNG core, TCP/HTTP/JSON-RPC/REST/SOAP transports, and RemoteGenNG.
  • Adds CodeGeneration plus extensive tests and samples.
  • Integrates CMake, GNU make, CI, packaging, visibility, and trace handling.
File summaries
File Description
CodeGeneration/** CodeGeneration library and tests
RemotingNG/** Framework, transports, generator, tests, and samples
Util/include/Poco/Util/AbstractConfiguration.h Exports event specialization
Util/src/AbstractConfiguration.cpp Instantiates exported event
CppUnit/src/TestCase.cpp Adds trace-aware message assertions
modules/Poco/CppParser.cppm Exposes attributes parser
components Registers new components
CHANGELOG Documents the import
Review details
  • Files reviewed: 143/4128 changed files
  • Comments generated: 4
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread RemotingNG/SOAP/cmake/PocoRemotingNGSOAPConfig.cmake
Comment thread RemotingNG/RemoteGen/dependencies
Comment thread CodeGeneration/testsuite/src/CodeGenerationTest.cpp Outdated
Comment thread RemotingNG/RemoteGen/src/ExtensionsGenerator.h Outdated
obiltschnig and others added 8 commits September 24, 2026 12:29
Flat import of platform/CodeGeneration from macchina.io (state of 2026-09-09); the Applied
Informatics changes since the common base follow as separate commits.

Co-Authored-By: Aleksandar Fabijanic <aleks-f@users.noreply.github.com>
Co-Authored-By: Matej Kenda <matejken@gmail.com>
…a.io #5447

Flat import of platform/RemotingNG from macchina.io (state of 2026-09-09); the Applied
Informatics changes since the common base follow as separate commits.

Co-Authored-By: Aleksandar Fabijanic <aleks-f@users.noreply.github.com>
Co-Authored-By: Matej Kenda <matejken@gmail.com>
Co-Authored-By: Florian Behrens <florianbehrens@users.noreply.github.com>
@matejk
matejk merged commit 0c070a8 into main Sep 24, 2026
59 checks passed
@matejk
matejk deleted the 5447-remotingng branch September 24, 2026 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(RemotingNG): add RemotingNG and CodeGeneration from macchina.io

5 participants