Skip to content
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

improve deployment query performance #1211

Merged
merged 5 commits into from
Jul 10, 2023
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions server/registry/internal/storage/models/deployment.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ import (
type Deployment struct {
Key string `gorm:"primaryKey"`
ProjectID string // Uniquely identifies a project.
ApiID string `gorm:"index"` // Uniquely identifies an api within a project.
DeploymentID string // Uniquely identifies a deployment within an api.
ApiID string `gorm:"index:idx_latest"` // Uniquely identifies an api within a project.
DeploymentID string `gorm:"index:idx_latest"` // Uniquely identifies a deployment within an api.
RevisionID string // Uniquely identifies a revision of a deployment.
DisplayName string // A human-friendly name.
Description string // A detailed description.
CreateTime time.Time // Creation time.
RevisionCreateTime time.Time // Revision creation time.
RevisionCreateTime time.Time `gorm:"index:idx_latest,sort:desc"` // Revision creation time.
RevisionUpdateTime time.Time // Time of last change.
ApiSpecRevision string // The spec being served by the deployment.
EndpointURI string // The address where the deployment is serving.
Expand Down