Joseph Schorr
917d5e2550
Fix typos in data model
2017-03-23 11:14:08 -04:00
Jimmy Zelinskie
d20ff785e6
data.model.repository: add back search fields
2017-03-23 10:46:04 -04:00
Jimmy Zelinskie
ddad957a56
data.model.repository: add app methods
2017-03-22 21:51:55 -04:00
Jimmy Zelinskie
48ba59d615
endpoints.v2: only work on docker repositories
2017-03-22 17:26:59 -04:00
Jimmy Zelinskie
45f14f220d
data.model.repository: optimize by using kind_id
2017-03-22 15:51:19 -04:00
Joseph Schorr
30b532254c
Disallow non-apps-supported APIs for application repositories
2017-03-22 15:51:19 -04:00
Jimmy Zelinskie
a2bac7dabd
endpoints.v1: only work on docker repositories
2017-03-22 14:31:22 -04:00
Jimmy Zelinskie
d2a4c9d05a
data.model.repository: audited for repo_kind usage
2017-03-22 13:58:50 -04:00
Antoine Legrand
718aeeead8
Fix search group_by clause for PG
2017-03-17 16:30:24 +01:00
Joseph Schorr
b5bb76cdea
Optimize repository search by changing our lookup strategy
...
Previous to this change, repositories were looked up unfiltered in six different queries, and then filtered using the permissions model, which issued a query per repository found, making search incredibly slow. Instead, we now lookup a chunk of repositories unfiltered and then filter them via a single query to the database. By layering the filtering on top of the lookup, each as queries, we can minimize the number of queries necessary, without (at the same time) using a super expensive join.
Other changes:
- Remove the 5 page pre-lookup on V1 search and simply return that there is one more page available, until there isn't. While technically not correct, it is much more efficient, and no one should be using pagination with V1 search anyway.
- Remove the lookup for repos without entries in the RAC table. Instead, we now add a new RAC entry when the repository is created for *the day before*, with count 0, so that it is immediately searchable
- Remove lookup of results with a matching namespace; these aren't very relevant anyway, and it overly complicates sorting
2017-03-09 19:47:55 -05:00
Joseph Schorr
ef9cb3757d
Check for missing repository on GC call
...
Fixes https://sentry.io/coreos/backend-production/issues/192273882/
2017-02-22 13:18:23 -05:00
Joseph Schorr
eece782038
Prevent peewee from loading the visibility every time
...
By calling `visibility` instead of `visibility_id`, peewee was issuing a SQL Select statement for the repository, which removes the benefit of the optimization
2017-02-17 12:09:48 -05:00
Joseph Schorr
973a110ac7
Full text search for repository name and description
...
Adds support for searching full text against the name and description of a repository
[Delivers #134867401 ]
2017-01-31 11:38:31 -05:00
Joseph Schorr
d65d32b284
Convert model to use moved prefix_search method
2017-01-31 11:38:31 -05:00
Joseph Schorr
5225642850
Garbage collection image+storage callback support
...
Add support to GC to invoke a callback with the image+storages removed. Only images whose storage was also removed will be sent to the callback. This will be used by security scanning for its own GC in the followup change.
2016-12-22 14:27:42 -05:00
Evan Cordell
5686c80af1
Revert "Add GC of layers in Clair"
...
This reverts 49872838ab
2016-12-13 18:40:58 -05:00
Joseph Schorr
49872838ab
Add GC of layers in Clair
...
Fixes https://www.pivotaltracker.com/story/show/135583207
2016-12-06 19:52:56 -05:00
josephschorr
ad4efba802
Merge pull request #1830 from coreos-inc/superuser-dashboard
...
Add prometheus stats to enable better dashboarding
2016-09-26 17:19:22 +02:00
Joseph Schorr
30af8aef1a
Add a worker for reporting global stats to Prometheus
...
Fixes #1789
2016-09-12 16:19:19 -04:00
Jake Moshenko
91963c17a0
Remove a join to slightly optimize the gc query.
2016-09-09 15:40:40 -04:00
Jake Moshenko
cf83c9a16a
Improve the garbage collection tests.
2016-09-07 13:25:19 -04:00
Jake Moshenko
584a5a7ddd
Reduce database bandwidth by tracking gc candidate images.
2016-09-07 13:25:19 -04:00
Jake Moshenko
1d8b72235a
Add a helper method to Image to parse ancestor string.
2016-09-07 10:48:58 -04:00
Joseph Schorr
1a2666be07
Fix deletion of labels and add tests
2016-08-26 16:07:49 -04:00
Joseph Schorr
608ffd9663
Basic labels support
...
Adds basic labels support to the registry code (V2), and the API. Note that this does not yet add any UI related support.
2016-08-26 15:24:26 -04:00
Joseph Schorr
aeddc6af06
Handle GC constraint failures in a nicer way
...
Fixes #1739
2016-08-17 16:13:27 -04:00
Joseph Schorr
7f5b536ddb
Fix pagination of repositories
...
Fixes #1725
2016-08-15 16:48:04 -04:00
Joseph Schorr
4a2acac5dc
Fix pagination of public repos, make more efficient and add test
2016-08-10 15:08:06 -04:00
Jake Moshenko
05e2773fa7
Get rid of remaining slow query for garbage collection.
2016-08-01 18:22:38 -04:00
Joseph Schorr
e252ee07cb
Fix popularity metrics on list repos API
2016-07-06 16:15:54 -04:00
Joseph Schorr
117ccda1cf
Fix postgres error in SQL query
2016-07-01 13:04:20 -04:00
Joseph Schorr
1eec6f53b2
Fix SQL error with pagination around Repositories
...
Fixes #1591
2016-06-30 17:31:35 -04:00
Joseph Schorr
853cca35f3
Change repo stats to use the RAC table and a nice UI
2016-06-22 15:06:53 -04:00
Jake Moshenko
a1cf12e460
Add a sitemap.txt for popular public repos
...
and reference it from the robots.txt
2016-06-17 14:34:20 -04:00
Joseph Schorr
42e934d84f
Make notification lookup faster and fix repo pagination on Postgres
2016-03-30 14:46:31 -04:00
Joseph Schorr
534ec9cb2b
Add pagination to the repository list API to make it better for public
...
Fixes #1166
2016-02-01 22:42:44 +02:00
Jake Moshenko
9c1a2e7e1b
Improve performance by removing unnecessary group by fields
2015-12-22 11:35:49 -05:00
Joseph Schorr
141f664bf7
Fix subquery delete which messes up MySQL
...
Fixes #1061
2015-12-15 13:15:10 -05:00
Joseph Schorr
762cd56e64
Change derived storage to be based on image
...
Fixes #971
2015-11-24 12:44:07 -05:00
Jake Moshenko
ab340e20ea
Merge remote-tracking branch 'upstream/master' into python-registry-v2
2015-11-11 16:41:40 -05:00
Joseph Schorr
2d2662f53f
Fix deleting repos and images under MySQL
...
MySQL doesn't handle constraints at the end of transactions, so deleting images currently fails. This removes the constraint and just leaves parent_id as an int
2015-11-09 14:42:05 -05:00
Jake Moshenko
e7a6176594
Merge remote-tracking branch 'upstream/v2-phase4' into python-registry-v2
2015-10-22 16:59:28 -04:00
Joseph Schorr
803a983126
Fix deletion of repos and users with V2 stuff
...
Fixes #674
2015-10-22 11:58:52 -04:00
Joseph Schorr
147b7b26b4
Fix is_public in repo list
...
Fixes #678
2015-10-21 14:13:39 -04:00
Joseph Schorr
4e5c8a9281
Reduce GC work time and make sure to use distinct query
2015-10-20 18:13:29 -04:00
Joseph Schorr
5941f3937c
Enable async GC for all
...
Fixes #569
2015-10-19 14:22:41 -04:00
josephschorr
2f42a4d94d
Merge pull request #641 from coreos-inc/wildcardfix
...
Make sure to filter wildcard queries
2015-10-15 14:26:51 -04:00
Joseph Schorr
6df7f60e4a
Make sure to filter wildcard queries
...
Fixes #640
2015-10-15 14:26:33 -04:00
Joseph Schorr
c9daf7d8a9
Add additional tests for repo visibility and further simplify the query for perf
2015-10-15 12:12:57 -04:00
Joseph Schorr
e8cb359d96
Unionize the mega query - It needed more performance-based benefits
2015-10-09 14:45:05 -07:00