refactor(api): add deprecation markers for v1.0 API freeze#676
Merged
Conversation
Mark legacy APIs scheduled for removal in v2.0.0 so consumers see compiler warnings during the migration window. The v3.0.0 pass removed legacy types but left transitional surfaces without [[deprecated]] attributes. - compatibility.h: emit #pragma message for thread_system/thread_module/ thread_namespace/utility_module aliases (namespace aliases cannot carry a portable [[deprecated]] attribute). Suppressible via THREAD_SUPPRESS_LEGACY_NAMESPACE_WARNING. - thread_logger.h: attach [[deprecated]] to user-facing methods (log/log_error/set_level/set_enabled/set_lightweight_mode). Keep the SDOF-safe helpers (instance/is_shutting_down/prepare_shutdown) stable because thread_context still depends on them. Leave log_level enum without an attribute to avoid internal self-warnings from member declarations; its deprecation propagates through the deprecated methods that accept it. - lockfree/lockfree_queue.h: emit #pragma message on include of the forwarding header. Suppressible via THREAD_SUPPRESS_LEGACY_LOCKFREE_QUEUE_WARNING. - queue.cppm: define the suppression macro before including lockfree_queue.h so the module re-export path stays quiet. Part of #670 Closes #672
Add a v1.0.0 section to MIGRATION.md that records the frozen public surface, the deprecated APIs scheduled for removal in v2.0.0, and the migration paths and suppression macros consumers can use during the migration window. Previously the document only described the v3.0.0 common_system transition. With v1.0.0 being an API stability commitment, consumers need a single place that lists what is frozen, what remains transitional, and how to silence legacy include warnings without editing upstream headers. Part of #670 Closes #672
Contributor
📊 Performance Benchmark ResultsPerformance Benchmark ReportNo benchmark data available. ℹ️ No baseline reference availableThis is the first benchmark run or baseline file is missing. |
This was referenced Apr 13, 2026
kcenon
added a commit
that referenced
this pull request
May 3, 2026
Add pre-flight verify-archive job to on-release-sync-registry.yml that independently re-downloads the release tarball and computes SHA512 before delegating to the reusable sync-vcpkg-registry workflow in common_system. The sync job now declares 'needs: verify-archive' so a fetch failure or unreachable tag short-circuits the entire run before any portfile commit reaches kcenon/vcpkg-registry. File-based hashing is required: piping curl into sha512sum masks fetch failures because SHA512 of empty input is the fixed constant cf83e1357eefb8bdf..., so a 404 still produces a valid-looking digest. The download uses curl -fsSL --retry 3 to a mktemp file and exits 1 with ::error:: if the fetch fails or the computed digest is empty. This closes the detection gap surfaced by microsoft/vcpkg#51511 and kcenon/vcpkg-registry#87, matching the pattern merged into common_system via PR #676. Closes #691
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #672
Part of #670
Summary
[[deprecated]]attributes to legacythread_loggeruser-facing methods (log,log_error,set_level,set_enabled,set_lightweight_mode,is_lightweight_mode) so consumers of the legacy logging path see compiler warnings. Internal SDOF-safe helpers (instance,is_shutting_down,prepare_shutdown) remain stable becausethread_contextstill depends on them.#pragma messagewarnings on include ofcompatibility.h(namespace aliasesthread_system,thread_module,thread_namespace,utility_module) andlockfree/lockfree_queue.h(forwarding header forconcurrent_queue.h). Namespace aliases cannot carry a portable[[deprecated]]attribute, so pragma-based warnings are the only viable signal.THREAD_SUPPRESS_LEGACY_NAMESPACE_WARNING,THREAD_SUPPRESS_LEGACY_LOCKFREE_QUEUE_WARNING) for consumers that need a quiet migration window.queue.cppmdefinesTHREAD_SUPPRESS_LEGACY_LOCKFREE_QUEUE_WARNINGbefore includinglockfree_queue.hso the module re-export path stays quiet.v1.0.0 API Freezesection todocs/advanced/MIGRATION.mdthat records the frozen public surface, the legacy APIs scheduled for removal in v2.0.0, and the suppression macros consumers can use during migration.Context
The v3.0.0 pass removed legacy types (
thread::result<T>,result_void,error,logger_interface,monitoring_interface) but left transitional compatibility surfaces without compiler-visible deprecation signals. Issue #672 is the v1.0 freeze audit — surface-wide review of 129 public headers to add[[deprecated]]markers and migration paths before v2.0 can make breaking changes. No dead code was found; the freeze is additive only.What changed
include/kcenon/thread/compatibility.h#pragma messagefor namespace aliases + suppression macroinclude/kcenon/thread/core/thread_logger.h[[deprecated]]on 7 user-facing methods; strengthenlog_levelenum docinclude/kcenon/thread/lockfree/lockfree_queue.h#pragma messagefor forwarding header + suppression macrosrc/modules/queue.cppmdocs/advanced/MIGRATION.mdTest plan
cmake --build build-debugsucceeds with exit code 0ctest --test-dir build-debug— 382/383 thread_base_unit tests pass (same pre-existingLifecycleControllerTest.InitialStateIsCreatedfailure as before Replace throw statements with Result<T> in public API #671; unrelated to this PR)queue.cppmmodule re-export path stays quiet (suppression macro applied before include)Notes for reviewers
log_levelenum itself does not carry[[deprecated]]. Applying it at the enum level would trigger warnings insidethread_logger.hitself (member initializer, internal signatures,level_to_string). The deprecation still propagates because every user-facing method that acceptslog_levelis itself[[deprecated]]. The rationale is documented in the enum's doc comment.thread_system,thread_module, etc.) can't be marked[[deprecated]]in portable C++ — the standard permits the attribute on namespace definitions but not on aliases.#pragma messageis the only portable fallback.