Skip to content

Modern GDAL Integration for MapWinGIS6 - #11

Merged
pmeems merged 3 commits into
developmentfrom
phase-5-gdal-errors-logging
Oct 25, 2026
Merged

pmeems merged 3 commits into
developmentfrom
phase-5-gdal-errors-logging

Conversation

@pmeems

@pmeems pmeems commented Oct 25, 2026

Copy link
Copy Markdown
Contributor

Complete Phase 5 of the Modern GDAL Integration plan. Native runners, COG/pipeline operations, and compatibility utilities now expose consistent results with full diagnostics and distinct cancellation state. Captured warnings reach the existing logger.

Serialize algorithm and utility execution with a shared lock. Keep callbacks synchronous, reject callback re-entry, retain callback/logger exceptions at the native boundary, and finalize successful GDAL executions before reporting callback failures. Preserve existing legacy signatures and add progress/cancellation overloads.

Depends on merged Phase 4 (#9). The merged ActiveX work defines architecture only, so completed native GDAL phases remain compatible. COM progress dispatch and BeginGdalOperation/EndGdalOperation remain deferred until a wrapper and asynchronous operation model exist. The external plan checklist is updated locally.

Debug | x64 builds without new Level 4 warnings. The full suite passes 129 tests; one opt-in public-network COG test is skipped. New coverage includes warnings, failures, finalization, cancellation, callback/logger failures, serialization, and isolated concurrent diagnostics.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

Logger-exception paths can discard subsequent GDAL diagnostics or leave compatibility clipping results without captured diagnostics.

2 open issues
What changed in this PR

Completes Phase 5 of the native GDAL integration, extending the Phase 4 COG and pipeline APIs with consistent results, diagnostics, cancellation, and execution controls. ActiveX callback dispatch remains deferred.

Changes:

  • Adds structured result snapshots and progress/cancellation overloads while preserving legacy signatures.
  • Serializes native operations and defers callback/logger exceptions until after native execution and required finalization.
  • Adds regression coverage and documents callback, ownership, and threading contracts.

Builds and tests were not run during this review.

File Description
tests/​MapWinGIS.Core.Tests/​GdalUtilsTests.cpp Tests utility cancellation, progress, and result resets.
tests/​MapWinGIS.Core.Tests/​GdalRuntimeTests.cpp Tests latched cancellation and isolated diagnostics.
tests/​MapWinGIS.Core.Tests/​GdalModernCapabilitiesTests.cpp Tests COG and pipeline cancellation results.
tests/​MapWinGIS.Core.Tests/​GdalEnvironmentTests.cpp Tests logger exceptions and recursive logging rejection.
tests/​MapWinGIS.Core.Tests/​GdalAlgorithmRunnerTests.cpp Covers diagnostics, finalization, callbacks, and serialization.
src/​MwGdalCore/​MwGdalCore.vcxproj Includes the shared execution header.
src/​MwGdalCore/​GdalUtils.cpp Adds progress overloads, result state, and serialization.
src/​MwGdalCore/​GdalRuntime.cpp Adds shared locking, diagnostic forwarding, and cancellation latching.
src/​MwGdalCore/​GdalModern.cpp Integrates structured results and operation locking.
src/​MwGdalCore/​GdalAlgorithmRunner.cpp Implements result queries and revised execution lifecycle.
src/​MapWinGIS.Core/​src/​internal/​GdalExecution.h Defines execution locking and callback guards.
src/​MapWinGIS.Core/​src/​gdal/​GdalEnvironment.cpp Routes diagnostics and retains logger exceptions.
src/​MapWinGIS.Core/​include/​mapwingis/​gdal/​GdalUtils.h Declares result snapshots and progress overloads.
src/​MapWinGIS.Core/​include/​mapwingis/​gdal/​GdalRuntime.h Documents diagnostic forwarding and deferred exceptions.
src/​MapWinGIS.Core/​include/​mapwingis/​gdal/​GdalModern.h Uses the shared result type and documents execution contracts.
src/​MapWinGIS.Core/​include/​mapwingis/​gdal/​GdalEnvironment.h Exposes diagnostic routing and logger-exception reporting.
src/​MapWinGIS.Core/​include/​mapwingis/​gdal/​GdalAlgorithmRunner.h Defines shared results and callback contracts.
docs/​gdal-modern-capabilities.md Documents results, cancellation, logging, and threading.
docs/​ARCHITECTURE.md Summarizes shared execution and synchronization requirements.

Review effort: Balanced

Comment thread src/MwGdalCore/GdalRuntime.cpp Resolved
Comment thread src/MwGdalCore/GdalUtils.cpp Resolved
pmeems and others added 2 commits October 25, 2026 21:19
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

@pmeems pmeems left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Review of the latest PR head (c6501fcf295728f39aa0e1971b4e2f438b0b9f5b): I did not find additional actionable issues beyond the two logger-exception paths already raised by Copilot. Both have since been addressed in a99dfd6, with regression tests for continued diagnostic capture and clipping diagnostics on exceptions. The callback/cancellation flow, pipeline dataset ownership, and shared execution-lock contract look internally consistent on source inspection. I did not run the Windows Debug/x64 build or test suite independently, so this is a source review rather than a verified test run.

@pmeems
pmeems merged commit 2e65498 into development Oct 25, 2026
1 check passed
@pmeems
pmeems deleted the phase-5-gdal-errors-logging branch October 25, 2026 20:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants