Skip to content

Use porting::optional in olp-cpp-sdk-read instead of boost::optional. #1627

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

asopov-here
Copy link
Collaborator

Currently, SDK requires C++11 minimum.
So, boost::optional type is used for optional values. For C++17 and above more convenient is to use std::optional instead. The task NLAM-23 is about making this type configurable. This commit is a third part of the task: olp-cpp-sdk-read.

Relates-To: NLAM-23

Copy link

codecov bot commented Aug 8, 2025

Codecov Report

❌ Patch coverage is 91.86992% with 20 lines in your changes missing coverage. Please review.
✅ Project coverage is 80.32%. Comparing base (a03183a) to head (9ce5a4d).

Files with missing lines Patch % Lines
...ataservice-read/src/repositories/QuadTreeIndex.cpp 60.00% 4 Missing ⚠️
...dataservice-read/src/generated/api/MetadataApi.cpp 50.00% 3 Missing ⚠️
...ce-read/include/olp/dataservice/read/DataRequest.h 86.67% 2 Missing ⚠️
...d/include/olp/dataservice/read/PartitionsRequest.h 83.33% 2 Missing ⚠️
...e/olp/dataservice/read/PrefetchPartitionsRequest.h 71.43% 2 Missing ⚠️
...read/include/olp/dataservice/read/CatalogRequest.h 85.71% 1 Missing ⚠️
...clude/olp/dataservice/read/CatalogVersionRequest.h 87.50% 1 Missing ⚠️
...nclude/olp/dataservice/read/PrefetchTilesRequest.h 91.67% 1 Missing ⚠️
...ce-read/include/olp/dataservice/read/TileRequest.h 88.89% 1 Missing ⚠️
olp-cpp-sdk-dataservice-read/src/TaskSink.h 0.00% 1 Missing ⚠️
... and 2 more
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1627      +/-   ##
==========================================
+ Coverage   80.27%   80.32%   +0.04%     
==========================================
  Files         349      349              
  Lines       13945    13951       +6     
  Branches     1492     1491       -1     
==========================================
+ Hits        11194    11205      +11     
+ Misses       2150     2147       -3     
+ Partials      601      599       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@asopov-here asopov-here force-pushed the NLAM-23-std-optional branch from ad19ece to 8a9bb0b Compare August 8, 2025 09:40
@asopov-here asopov-here marked this pull request as ready for review August 8, 2025 10:01
@asopov-here asopov-here requested a review from mykolamalik August 8, 2025 16:37
Currently, SDK requires C++11 minimum.
So, boost::optional type is used for optional values.
For C++17 and above more convenient is to use std::optional instead.
The task NLAM-23 is about making this type configurable.
This commit is a third part of the task: olp-cpp-sdk-read.
Also, initial name "optional.hpp" is changed to optional.h
to avoid clang-format header sorting issue.

Relates-To: NLAM-23
Signed-off-by: sopov <[email protected]>
@asopov-here asopov-here force-pushed the NLAM-23-std-optional branch from 0b71fee to 9ce5a4d Compare August 8, 2025 16:41
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.

4 participants