-
Notifications
You must be signed in to change notification settings - Fork 180
Improve the StorageLocal struct #1327
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
Open
djeebus
wants to merge
15
commits into
main
Choose a base branch
from
improve-storage-local
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- use pid to ensure we own the total space - stop looking for foreign namespaces - add tests to ensure functionality - randomly look for available slot - only return slot if we created it successfully - no need to create a context timeout, we're only doing in memory things
After reviewing, @ValentaTomas pointed out that Idx is used to generate IP addreses, which must not overlap across orchestrators on the same host. I'll need to do some more work to ensure that stays true. |
# Conflicts: # packages/orchestrator/internal/sandbox/network/pool.go
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Note
Refactors sandbox networking to use typed env config and PID-locked local namespace storage, updating pool/slot/storage APIs (context-aware release) and adding tests.
network.Config
with*net.IPNet
CIDRs and parser (ParseConfig
,ParseIPNet
); updatecfg.Parse
/ParseBuilder
to use custom env parsers.Slot
now uses config-provided CIDRs; fields renamed (Name
replacesKey
);NamespaceID
/names follow PID-based scheme; remove global CIDR getters.Pool
: uses newNewStorage(nodeID, config)
andRelease(ctx, ...)
flow; improved cleanup.Release(ctx, *Slot)
; factory no longer passes slots size (derived from config).slotsSize
from config and uses slotName
for KV keys.config_test.go
for CIDR parsing andstorage_local_test.go
for lock/unlock and round-trip behavior.Written by Cursor Bugbot for commit 1e76a51. This will update automatically on new commits. Configure here.