mirror of
https://github.com/zalando/postgres-operator.git
synced 2026-10-07 02:41:48 +02:00
fix golint fail #415
This commit is contained in:
@@ -849,8 +849,8 @@ func (c *Cluster) GetCurrentProcess() Process {
|
||||
}
|
||||
|
||||
// GetStatus provides status of the cluster
|
||||
func (c *Cluster) GetStatus() *ClusterStatus {
|
||||
return &ClusterStatus{
|
||||
func (c *Cluster) GetStatus() *Status {
|
||||
return &Status{
|
||||
Cluster: c.Spec.ClusterName,
|
||||
Team: c.Spec.TeamID,
|
||||
Status: c.Status,
|
||||
|
||||
+1
-5
@@ -77,11 +77,7 @@ func (c *Cluster) deletePod(podName spec.NamespacedName) error {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := c.waitForPodDeletion(ch); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
return c.waitForPodDeletion(ch)
|
||||
}
|
||||
|
||||
func (c *Cluster) unregisterPodSubscriber(podName spec.NamespacedName) {
|
||||
|
||||
@@ -20,6 +20,7 @@ const (
|
||||
Replica PostgresRole = "replica"
|
||||
)
|
||||
|
||||
// PodEventType describe value of event type
|
||||
type PodEventType string
|
||||
|
||||
// Possible values for the EventType
|
||||
@@ -50,8 +51,8 @@ type WorkerStatus struct {
|
||||
CurrentProcess Process
|
||||
}
|
||||
|
||||
// ClusterStatus describes status of the cluster
|
||||
type ClusterStatus struct {
|
||||
// Status describes status of the cluster
|
||||
type Status struct {
|
||||
Team string
|
||||
Cluster string
|
||||
MasterService *v1.Service
|
||||
|
||||
@@ -460,6 +460,7 @@ func (c *Cluster) setSpec(newSpec *acidv1.Postgresql) {
|
||||
c.specMu.Unlock()
|
||||
}
|
||||
|
||||
// GetSpec returns cluster.Postgresql
|
||||
func (c *Cluster) GetSpec() (*acidv1.Postgresql, error) {
|
||||
c.specMu.RLock()
|
||||
defer c.specMu.RUnlock()
|
||||
|
||||
Reference in New Issue
Block a user