Skip to content

Conversation

@srenatus
Copy link
Contributor

@srenatus srenatus commented Oct 30, 2025

See #141.

Previously, it was possible to create a state in the database that would unconditionally fail when we tried to build a bundle from that. Now, any PUT will be validated against the current state of the database.

@srenatus srenatus force-pushed the sr/qstmlyywlskq branch 5 times, most recently from a4f46e4 to f1c6f18 Compare October 31, 2025 14:23
@@ -0,0 +1,128 @@
package sourcedatafs
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The correct answer is always one more filesystem

@srenatus srenatus force-pushed the sr/zoorstqmswmk branch 4 times, most recently from 2ce8c72 to 29c03d7 Compare November 4, 2025 08:37
Base automatically changed from sr/zoorstqmswmk to main November 4, 2025 08:47
See #141.

Previously, it was possible to create a state in the database that would
unconditionally fail when we tried to build a bundle from that. Now, any
PUT will be validated against the current state of the database.

Signed-off-by: Stephan Renatus <[email protected]>
Note that we currently still hold on to it, so we need to be able
to keep all the (raw JSON) data in memory. Let's figure out a
better way...

Signed-off-by: Stephan Renatus <[email protected]>
This should let us avoid dealing with most of the files most of the time.

Signed-off-by: Stephan Renatus <[email protected]>
But this seems to take forever for my 12k files experiment. I'll
explore returning the relevant prefixed files instead.
(It takes 5 min to load the 12k files on-the-fly.)

Signed-off-by: Stephan Renatus <[email protected]>
@srenatus srenatus force-pushed the sr/qstmlyywlskq branch 6 times, most recently from f035b95 to 1ca846f Compare November 4, 2025 12:56
This might be a good compromise between extra effort and
usability.

Signed-off-by: Stephan Renatus <[email protected]>

// deal with (1.), downwards conflicts
// NB(sr): We don't need to consult the data itself to determine errors here,
// so we only check existing paths.
Copy link
Contributor Author

@srenatus srenatus Nov 4, 2025

Choose a reason for hiding this comment

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

Turns out this is too restrictive. There are valid data combinations that this model refuses, for example:

users/admins/alice/data.json: {"name": "Alice"}
users/data.json: {"admins": {"bob": "foo"}}

In that order, the PUT of the second request would be forbidden. If ordered the other way around, it would work. This isn't good. 😵 Back to the drawing table.

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.

2 participants