Skip to content

Conversation

@rly
Copy link
Collaborator

@rly rly commented May 14, 2025

Fix #974

The new endpoint is /files/<string:file_id> where file_id is a string with 8 random letters and numbers, which is highly unlikely to repeat before the Neurosift cache resets (currently after 1000 entries)

See comments in #974 for rationale of using a random string instead of other schemes.

Clearing the Neurosift cache database doesn't work from the GUIDE domain so I removed that code and test.

@rly rly requested a review from pauladkisson May 14, 2025 20:01
Copy link
Collaborator

@pauladkisson pauladkisson left a comment

Choose a reason for hiding this comment

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

Random string seems less transparent, what about using an index + date modified instead?

@rly
Copy link
Collaborator Author

rly commented May 15, 2025

Great idea! I made that change.

Copy link
Collaborator

@pauladkisson pauladkisson left a comment

Choose a reason for hiding this comment

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

Not sure why the e2eLiveServices tests are failing, but otherwise looks good.

@rly
Copy link
Collaborator Author

rly commented May 15, 2025

They are failing due to #987 . I'll address that separately.

@rly rly merged commit acf0703 into main May 15, 2025
23 of 27 checks passed
@rly rly deleted the fix-neurosift-cache branch May 15, 2025 23:48
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.

Clear cache when serving NWB files to Neurosift and other services

3 participants