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

Add a batched image CID route to creator node #1350

Merged
merged 1 commit into from
Mar 29, 2021

Conversation

cheran-senthil
Copy link
Contributor

@cheran-senthil cheran-senthil commented Mar 25, 2021

Description

Continues from: #1310

Adds a batched image CID route to creator node, so that #1310 works.

Tests

Stage testing as well as load testing for the new route is pending.

Copy link
Contributor

@SidSethi SidSethi left a comment

Choose a reason for hiding this comment

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

really feels like these two routes should be combined, a few diff ways to do that. but not worth doing now. this works, and looks good. priority here is beginning use of your network CID script

return errorResponseBadRequest(`Too many CIDs passed in, limit is ${BATCH_CID_ROUTE_LIMIT}`)
}

const queryResults = (await models.File.findAll({
Copy link
Contributor

Choose a reason for hiding this comment

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

did we decide to not add a type != image for the non-image batch CID route?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, because we still want to support the existence of directory check.

Copy link
Contributor

Choose a reason for hiding this comment

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

right - sounds good, can you add comment to that effect 🙂

Copy link
Contributor Author

Choose a reason for hiding this comment

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

   * @param {string[]} req.body.cids the cids to check existence for, these cids can also be directories

This comment should explain that already, if you think that is sufficient, I think this is good to merge now too.

@cheran-senthil cheran-senthil merged commit 66f87ea into master Mar 29, 2021
@cheran-senthil cheran-senthil deleted the vss-batch-image-cid branch March 29, 2021 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content-node Content Node (previously known as Creator Node)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants