Skip to content
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

feat: get_chunks_info query method #207

Closed
wants to merge 8 commits into from

Conversation

3cL1p5e7
Copy link

@3cL1p5e7 3cL1p5e7 commented Feb 15, 2022

We need to know chunks info of any asset for developing streaming strategy on client

Linked PR

@3cL1p5e7 3cL1p5e7 changed the title Feature: get_chunks_info query method feat: get_chunks_info query method Feb 15, 2022
#[derive(Clone, Debug, CandidType, Deserialize)]
struct ChunkInfo {
chunk_id: ChunkId,
total_length: Nat,

Choose a reason for hiding this comment

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

I would rename this maybe to chunk_length

Choose a reason for hiding this comment

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

and maybe make it u64

Copy link
Author

Choose a reason for hiding this comment

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

@mstein-dfinity done :)

@@ -203,6 +203,18 @@ struct HttpRequest {
body: ByteBuf,
}

#[derive(Clone, Debug, CandidType, Deserialize)]
struct ChunkInfo {
Copy link
Contributor

Choose a reason for hiding this comment

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

We want to have certification of these results and to add certification for the get_chunk call. I don't know if we need to do that in this PR though.

Copy link
Author

Choose a reason for hiding this comment

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

@jplevyak
yes, most likely it is better to make a separate PR.
I am currently working on my own certified-assets-based chunk certification solution. If I succeed, then I will definitely share them in the PR format in order to at least discuss the solution

Copy link
Contributor

Choose a reason for hiding this comment

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

SGTM

Copy link
Author

Choose a reason for hiding this comment

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

@jplevyak done :)
#219

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