Details
-
New Feature
-
Status: Closed (View Workflow)
-
P2
-
Resolution: Done
-
None
-
-
CP: sprint 100, CP: sprint 101
-
3
-
Core: Platform
Description
Iterating over each RoutingEntry of a tenant takes long, we have more than 700 API paths, and can be avoided by using a hash map.
For a path without wildcards use the path as key, for example
/a/b/c
For a path with a wildcard use the path until the last slash before the wildcard.
Examples:
/a/d/ is the key for
/a/d/{id} /a/d/{id}/y /a/d/{id1}/y/{id2}
/a/e/ is the key for
/a/e/*
/a/ is the key for
/a/y* /a/zoo*
For each tenant maintain a hash where each key points to a List<RoutingEntry>.
If there is a request for the path /a/b/f/g try these keys:
/a/b/f/g /a/b/f/ /a/b/ /a/ /
For n path segments there are only n+1 hash lookups.
TestRail: Results
Attachments
Issue Links
- relates to
-
OKAPI-796 Consider not encode/decode object when use LockedTypeMap
-
- Closed
-
-
OKAPI-941 Remove legacy "path", it has been obsoleted by "pathPattern"
-
- Open
-
-
OKAPI-964 Performance Degradation of ProxyContext.logRequest and ProxyContext.logResponse
-
- Closed
-
-
OKAPI-967 Clustered Okapi not allowing bootstrapping of superuser
-
- Closed
-