-
Notifications
You must be signed in to change notification settings - Fork 113
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
Use storageproviderid for routing #2792
Use storageproviderid for routing #2792
Conversation
0241146
to
b1cbab8
Compare
hmmm https://drone.cernbox.cern.ch/cs3org/reva/6832/11/4
it seems the public scope cannot properly resolve the resuorce ... but why does it work with the |
b1cbab8
to
d97f42f
Compare
ca7cf1c
to
be79a55
Compare
needs to be rebased when sharing jail is merged |
@@ -76,7 +77,8 @@ func (sc *spaceConfig) SpacePath(currentUser *userpb.User, space *providerpb.Sto | |||
// Provider holds information on Spaces | |||
type Provider struct { | |||
// Spaces is a map from space type to space config | |||
Spaces map[string]*spaceConfig `mapstructure:"spaces"` | |||
Spaces map[string]*spaceConfig `mapstructure:"spaces"` | |||
ProviderID string `mapstructure:"providerid"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We generate provider IDs dynamically. Can you make these work with regexes?
"eoshome-[dlntz]" = { address = "localhost:16000" }
"eoshome-[agjkw]" = { address = "localhost:16001" }
"eoshome-[horsy]" = { address = "localhost:16002" }
"eoshome-[bemvx]" = { address = "localhost:16003" }
"eoshome-[cfipqu]" = { address = "localhost:16004" }
For example, provider IDs 1284d238-aa92-42ce-bdc4-0b000000[9157-9159]
should go to localhost:11000
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And doing a ListProviders
without any filters should ideally return all of these:
[
{address: localhost:11000, provider_id: 1284d238-aa92-42ce-bdc4-0b0000009157},
{address: localhost:11000, provider_id: 1284d238-aa92-42ce-bdc4-0b0000009158},
{address: localhost:11000, provider_id: 1284d238-aa92-42ce-bdc4-0b0000009159}
]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can look into this in a separate PR! tracked in #2859
de5e5d3
to
ce605fc
Compare
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
ce605fc
to
4df5ebe
Compare
Kudos, SonarCloud Quality Gate passed! |
@micbar @kobergj @aduffeck owncloud/ocis#3726 got green as well |
We made the spaces registry aware of storageprovider ids and use them to route directly to the correct storageprovider.
Path based requests can be optimized in a subsequent PR
based on #2790