Eric Promislow
35f4cc04c9
Sort-indirect PR broken into smaller parts: part 3/6 - pass listOptions by reference ( #612 )
...
* Move types related to list options and sql queries into their own package.
The problem having these in the informer package is that eventually code
in other packages will need to import `informer` only for constants or types,
but some members of the informer package may already depend on those. Best to
move type definitions into their own simpler package.
2025-04-25 14:23:35 -07:00
Eric Promislow
2b227dbd22
Move types related to list options and sql queries into their own package. ( #610 )
...
The problem having these in the informer package is that eventually code
in other packages will need to import `informer` only for constants or types,
but some members of the informer package may already depend on those. Best to
move type definitions into their own simpler package.
2025-04-25 09:11:09 -07:00
Tom Lebreux
9dd9b0f625
Move lasso SQL cache in Steve ( #452 )
...
* Copy pkg/cache/sql from lasso to pkg/sqlcache
* Rename import from github.com/rancher/lasso/pkg/cache/sql to github.com/rancher/steve/pkg/sqlcache
* Fix filter.Match -> filter.Matches
* go mod tidy
* Fix lint errors
* Remove lasso SQL cache mentions
* Fix more CI lint errors
* fix goimports
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* fix tests (Match -> Matches)
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* Fix Sort order
---------
Signed-off-by: Silvio Moioli <silvio@moioli.net >
Co-authored-by: Silvio Moioli <silvio@moioli.net >
2025-01-17 09:34:48 -05:00
Eric Promislow
6a11ffb660
Migrate the mocking library to uber's ( #291 )
...
* Migrate from golang/mock to uber/mock.
* Update go.mod
* Continue migration to uber/mock.
* Tweaks from running the go.uber.mock's mockgen.
2024-10-10 10:28:25 -07:00
Silvio Moioli
0841e03c57
sql: bugfix: return total resource count correctly ( #236 )
...
* sql: drop dead code
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* sql: bugfix: return total resource count correctly
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* adapt tests
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* adapt mocks
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* TEMP: remove this when bumping lasso to include https://github.com/rancher/lasso/pull/84
Signed-off-by: Silvio Moioli <silvio@moioli.net >
* Use latest lasso instead of fork
---------
Signed-off-by: Silvio Moioli <silvio@moioli.net >
Co-authored-by: Tom Lebreux <tom.lebreux@suse.com >
2024-07-05 16:17:16 -04:00
Silvio Moioli
7a84620e8b
SQLite backed cache ( #223 )
...
This uses SQLite-backed informers provided by Lasso with https://github.com/rancher/lasso/pull/65 to implement Steve API (/v1/) functionality.
This new functionality is available behind a feature flag to be specified at Steve startup
See https://confluence.suse.com/pages/viewpage.action?pageId=1359086083
Co-authored-by: Ricardo Weir <ricardo.weir@suse.com >
Co-authored-by: Michael Bolot <michael.bolot@suse.com >
Co-authored-by: Silvio Moioli <silvio@moioli.net >
Signed-off-by: Silvio Moioli <silvio@moioli.net >
2024-06-05 16:17:12 +02:00