Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@TomCC7
Copy link

@TomCC7 TomCC7 commented Oct 23, 2025

Adds a new function to dora C++ interface to make retrieving the complete information (id, metadata, arrow data) possible. Metadata will be serialized to json.

@haixuanTao
Copy link
Collaborator

Is using a file type as a suffix something very common in cpp?

It seems to be a bit raw. Does cpp implements a standard dictionary object?

@TomCC7
Copy link
Author

TomCC7 commented Oct 27, 2025

I think it's impossible to return an std::unordered_map directly with rust bindings but I'll see if there's any workaround. The other approach is perhaps creating an accessor function so that we can do something like

auto metadata = extract_metadata();
std::optional<> val = metadata.get(key);

@TomCC7 TomCC7 marked this pull request as draft October 28, 2025 18:40
@TomCC7 TomCC7 marked this pull request as ready for review October 29, 2025 05:56
@TomCC7
Copy link
Author

TomCC7 commented Oct 29, 2025

@haixuanTao This new approach now provides access to metadata dict through getter and setter method. Due to constraints of the FFI interface I have to implement all the metadata types manually. If we want better interface, we can add a wrapper from C++ side to wrap the raw interface into template functions.

Copy link
Collaborator

@haixuanTao haixuanTao left a comment

Choose a reason for hiding this comment

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

This looks awesome to me!

Could @phil-opp take a look maybe? :)

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