Skip to content

Commit

Permalink
Remove Unused Constants (#1891)
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Valdivia <18384552+dvaldivia@users.noreply.github.com>
  • Loading branch information
dvaldivia committed Nov 27, 2023
1 parent f6a9687 commit 38961bf
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 42 deletions.
4 changes: 0 additions & 4 deletions api/consts.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,8 @@ const (

// Constants for prometheus annotations
prometheusPath = "prometheus.io/path"
prometheusPort = "prometheus.io/port"
prometheusScrape = "prometheus.io/scrape"

// Constants for DirectPV
DirectPVMode = "DIRECTPV_MODE"

// Image versions

KESImageVersion = "minio/kes:2023-11-10T10-44-28Z"
Expand Down
3 changes: 0 additions & 3 deletions pkg/apis/minio.min.io/v2/names.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ const MinIOServerName = "minio"
// KESContainerName specifies the default container name for KES
const KESContainerName = "kes"

// InitContainerImage name for init container.
const InitContainerImage = "busybox:1.33.1"

// MinIO Related Names

// MinIOStatefulSetNameForPool returns the name for MinIO StatefulSet
Expand Down
12 changes: 0 additions & 12 deletions pkg/controller/monitoring.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ const (
HealthHealingMessage = "Healing"
// HealthReduceAvailabilityMessage some drives are offline
HealthReduceAvailabilityMessage = "Reduced Availability"
// HealthAboutToLoseQuorumMessage means we are close to losing write capabilities
HealthAboutToLoseQuorumMessage = "About to lose quorum"
)

// recurrentTenantStatusMonitor loop that checks every 3 minutes for tenants health
Expand Down Expand Up @@ -259,16 +257,6 @@ type HealthResult struct {
WriteQuorumDrives int
}

// HealthMode type of query we want to perform to MinIO cluster health
type HealthMode string

const (
// MaintenanceMode query type for when we want to ask MinIO if we can take down 1 server
MaintenanceMode HealthMode = "MaintenanceMode"
// RegularMode query type for when we want to ask MinIO the current state of healing/health
RegularMode = "RegularMode"
)

// processNextHealthCheckItem will read a single work item off the workqueue and
// attempt to process it, by calling the syncHandler.
func (c *Controller) processNextHealthCheckItem() bool {
Expand Down
27 changes: 4 additions & 23 deletions pkg/internal/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,27 +30,10 @@ var (

// Standard S3 HTTP response constants
const (
LastModified = "Last-Modified"
Date = "Date"
ETag = "ETag"
ContentType = "Content-Type"
ContentMD5 = "Content-Md5"
ContentEncoding = "Content-Encoding"
Expires = "Expires"
ContentLength = "Content-Length"
ContentLanguage = "Content-Language"
ContentRange = "Content-Range"
Connection = "Connection"
AcceptRanges = "Accept-Ranges"
AmzBucketRegion = "X-Amz-Bucket-Region"
ServerInfo = "Server"
RetryAfter = "Retry-After"
Location = "Location"
CacheControl = "Cache-Control"
ContentDisposition = "Content-Disposition"
Authorization = "Authorization"
Action = "Action"
Range = "Range"
ContentType = "Content-Type"
ContentLength = "Content-Length"
AcceptRanges = "Accept-Ranges"
ServerInfo = "Server"
)

// mimeType represents various MIME type used API responses.
Expand All @@ -59,8 +42,6 @@ type mimeType string
const (
// MimeNone Means no response type.
MimeNone mimeType = ""
// MimeJSON Means response type is JSON.
MimeJSON mimeType = "application/json"
// MimeXML Means response type is XML.
MimeXML mimeType = "application/xml"
)
Expand Down

0 comments on commit 38961bf

Please sign in to comment.