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

Support Pagination in TAXII DataStore #480

Merged
merged 7 commits into from
Mar 15, 2021

Conversation

emmanvg
Copy link
Contributor

@emmanvg emmanvg commented Dec 22, 2020

Proposed solution to solve the pagination issues.

Closes #479

@codecov-io
Copy link

codecov-io commented Dec 22, 2020

Codecov Report

Merging #480 (76eebeb) into master (0866df0) will decrease coverage by 0.01%.
The diff coverage is 73.68%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #480      +/-   ##
==========================================
- Coverage   89.32%   89.31%   -0.02%     
==========================================
  Files         144      144              
  Lines       16020    16034      +14     
==========================================
+ Hits        14310    14320      +10     
- Misses       1710     1714       +4     
Impacted Files Coverage Δ
stix2/datastore/taxii.py 69.23% <61.53%> (-0.52%) ⬇️
stix2/test/v20/test_datastore_taxii.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0866df0...76eebeb. Read the comment docs.

@chisholm
Copy link
Contributor

Just curious: would it make sense to add an as_pages() function for the 2.1 TAXII client, similar to the 2.0 client? It could be a nice convenience for 2.1 users and better align their APIs.

@emmanvg
Copy link
Contributor Author

emmanvg commented Dec 23, 2020

I think so, that was one of my observations when making the changes. The second one being that some TAXII 2.0 Servers that claim pagination support are not providing the headers required to continue asking for pages making the client code to not behave with consistency.

@emmanvg emmanvg marked this pull request as ready for review February 8, 2021 16:42
@emmanvg emmanvg added this to the 3.0.0 milestone Feb 8, 2021
Copy link
Contributor

@clenk clenk left a comment

Choose a reason for hiding this comment

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

LGTM; thanks @emmanvg!

@clenk clenk merged commit ccf3b1a into oasis-open:master Mar 15, 2021
@emmanvg emmanvg deleted the 479-pagination-taxii-datastore branch March 15, 2021 15:06
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.

TAXIICollectionSource.query() only returns the first page
4 participants