This differential wraps generated C++ bindings for blob upload so that caller does not need to diretctly instantiate CXx types from ::rust namespace
Details
Details
Methods implemented in this differential can be used to send data to actual blob service instance.
- Start blob service locally.
- put the following code somewhere in CommCoreModule:
std::string holder = "test.holder.v0"; std::string hash = "test.hash.v0"; auto data = { std::string(4000000, 'a'), std::string(4000000, 'b'), std::string(4000000, 'c'), std::string(4000000, 'd'), std::string(4000000, 'e'), std::string(4000000, 'f'), std::string(4000000, 'g'), }; UploadBlobClient client; client.startUploadBlocking(holder, hash); for (auto &chunk : data) { client.uploadChunkBlocking((std::uint8_t *)chunk.c_str(), chunk.length()); } client.completeUploadBlocking();
- Run aws --endpoint-url=http://localhost:4566 s3 cp s3://commapp-blob/test.hash.v0 localfile. Then cat localfile | wc -c and ensure the output is 28000000.
Diff Detail
Diff Detail
- Repository
- rCOMM Comm
- Branch
- marcin/eng-384-native-rust-lib
- Lint
No Lint Coverage - Unit
No Test Coverage