Skip to content

Commit

Permalink
Merge pull request #259 from booxter/raftaddress-remove
Browse files Browse the repository at this point in the history
Remove raftAddress from CRD
  • Loading branch information
openshift-merge-bot[bot] committed Apr 12, 2024
2 parents e75b363 + 7466d5a commit 52c4fc7
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 14 deletions.
3 changes: 0 additions & 3 deletions api/bases/ovn.openstack.org_ovndbclusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -238,9 +238,6 @@ spec:
generation, then the controller has not processed the latest changes.
format: int64
type: integer
raftAddress:
description: RaftAddress -
type: string
readyCount:
description: ReadyCount of OVN DBCluster instances
format: int32
Expand Down
3 changes: 0 additions & 3 deletions api/v1beta1/ovndbcluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,6 @@ type OVNDBClusterStatus struct {
// Conditions
Conditions condition.Conditions `json:"conditions,omitempty" optional:"true"`

// RaftAddress -
RaftAddress string `json:"raftAddress,omitempty"`

// DBAddress - DB IP address used by external nodes
DBAddress string `json:"dbAddress,omitempty"`

Expand Down
3 changes: 0 additions & 3 deletions config/crd/bases/ovn.openstack.org_ovndbclusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -238,9 +238,6 @@ spec:
generation, then the controller has not processed the latest changes.
format: int64
type: integer
raftAddress:
description: RaftAddress -
type: string
readyCount:
description: ReadyCount of OVN DBCluster instances
format: int32
Expand Down
4 changes: 0 additions & 4 deletions controllers/ovndbcluster_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,6 @@ func (r *OVNDBClusterReconciler) reconcileNormal(ctx context.Context, instance *
instance.Status.Conditions.MarkTrue(condition.DeploymentReadyCondition, condition.DeploymentReadyMessage)
instance.Status.Conditions.MarkTrue(condition.ExposeServiceReadyCondition, condition.ExposeServiceReadyMessage)
internalDbAddress := []string{}
raftAddress := []string{}
var svcPort int32
scheme := "tcp"
if instance.Spec.TLS.Enabled() {
Expand All @@ -598,7 +597,6 @@ func (r *OVNDBClusterReconciler) reconcileNormal(ctx context.Context, instance *
// Filter out headless services
if svc.Spec.ClusterIP != "None" {
internalDbAddress = append(internalDbAddress, fmt.Sprintf("%s:%s.%s.svc.%s:%d", scheme, svc.Name, svc.Namespace, ovnv1.DNSSuffix, svcPort))
raftAddress = append(raftAddress, fmt.Sprintf("%s:%s.%s.svc.%s:%d", scheme, svc.Name, svc.Namespace, ovnv1.DNSSuffix, svc.Spec.Ports[1].Port))
}
}

Expand All @@ -609,8 +607,6 @@ func (r *OVNDBClusterReconciler) reconcileNormal(ctx context.Context, instance *

// Set DB Address
instance.Status.InternalDBAddress = strings.Join(internalDbAddress, ",")
// Set RaftAddress
instance.Status.RaftAddress = strings.Join(raftAddress, ",")
}
Log.Info("Reconciled Service successfully")
instance.Status.ObservedGeneration = instance.Generation
Expand Down
1 change: 0 additions & 1 deletion tests/functional/ovndbcluster_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,6 @@ var _ = Describe("OVNDBCluster controller", func() {
OVNDBCluster := GetOVNDBCluster(OVNDBClusterName)
g.Expect(OVNDBCluster.Status.DBAddress).To(HavePrefix("ssl:"))
g.Expect(OVNDBCluster.Status.InternalDBAddress).To(HavePrefix("ssl:"))
g.Expect(OVNDBCluster.Status.RaftAddress).To(HavePrefix("ssl:"))
}, timeout, interval).Should(Succeed())

// check scripts configure TLS
Expand Down

0 comments on commit 52c4fc7

Please sign in to comment.