-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add sparse streams, compression, single resource api endpoints (#…
…28) ## Description The original SSE implementation is very inefficient as it streams the complete / reconciled list on each data change event. After exploring a number of different strategies for optimizing this, including differentials, sparse data + compression realized a significant efficiency gains, > 90% typically and in some extreme cases up to 99.96% reduction in bandwidth requirements. Spare Streams: This PR introduces a concept of sparse and dense resource streams. The default is now sparse and can be overriden by adding the query param `dense=true` to any of the resource streams. Sparse streams only return `metadata`, `status`, `type`, `data` (keys only), `kind`, `apiVersion` fields and strip `managedFields` from `metadata` as well. This results in much lighter data streams. Single-Resource Endpoint: This PR also introduces the ability to call a dense resource by it's UID, to be used in conjunction with thew new spare streams. The url pattern is `/api/v1/resources/<kind>/uid`, in this mode `once` and `dense` currently have no affect, this also means we do not yet support streaming a single resource. Compression: GZIP compressions for both streams and regular API calls will now automatically be enabled if the client supports it. This PR also introduces the Secrets & Configmaps UI views, which originally triggered the performance concerns due to large binary data stored in their resource lists.
- Loading branch information
1 parent
084fc83
commit c5c4c9c
Showing
24 changed files
with
608 additions
and
148 deletions.
There are no files selected for viewing
This file contains 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
Oops, something went wrong.