state: update calls to ensureConfigEntryTxn
The EnterpriseMeta paramter was removed after this code was written, but before it merged. Also the table name constant has changed.
This commit is contained in:
parent
730cc575e6
commit
ba59727337
|
@ -203,7 +203,7 @@ func ServiceHealthEventsFromChanges(tx ReadTxn, changes Changes) ([]stream.Event
|
||||||
markService(newNodeServiceTupleFromServiceHealthCheck(obj), serviceChangeIndirect)
|
markService(newNodeServiceTupleFromServiceHealthCheck(obj), serviceChangeIndirect)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
case gatewayServicesTableName:
|
case tableGatewayServices:
|
||||||
gs := changeObject(change).(*structs.GatewayService)
|
gs := changeObject(change).(*structs.GatewayService)
|
||||||
if gs.GatewayKind != structs.ServiceKindTerminatingGateway {
|
if gs.GatewayKind != structs.ServiceKindTerminatingGateway {
|
||||||
continue
|
continue
|
||||||
|
|
|
@ -1030,7 +1030,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
return ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
return ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
},
|
},
|
||||||
WantEvents: []stream.Event{},
|
WantEvents: []stream.Event{},
|
||||||
},
|
},
|
||||||
|
@ -1052,7 +1052,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
return ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
return ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
},
|
},
|
||||||
Mutate: func(s *Store, tx *txn) error {
|
Mutate: func(s *Store, tx *txn) error {
|
||||||
if err := s.ensureRegistrationTxn(
|
if err := s.ensureRegistrationTxn(
|
||||||
|
@ -1111,7 +1111,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1172,7 +1172,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
return ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
return ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
},
|
},
|
||||||
WantEvents: []stream.Event{
|
WantEvents: []stream.Event{
|
||||||
testServiceHealthEvent(t,
|
testServiceHealthEvent(t,
|
||||||
|
@ -1201,7 +1201,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1224,7 +1224,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
return ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
return ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
},
|
},
|
||||||
WantEvents: []stream.Event{
|
WantEvents: []stream.Event{
|
||||||
testServiceHealthEvent(t,
|
testServiceHealthEvent(t,
|
||||||
|
@ -1252,7 +1252,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1271,7 +1271,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
return ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
return ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
},
|
},
|
||||||
WantEvents: []stream.Event{
|
WantEvents: []stream.Event{
|
||||||
testServiceHealthDeregistrationEvent(t,
|
testServiceHealthDeregistrationEvent(t,
|
||||||
|
@ -1294,7 +1294,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1314,7 +1314,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
return ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
return ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
},
|
},
|
||||||
WantEvents: []stream.Event{
|
WantEvents: []stream.Event{
|
||||||
testServiceHealthDeregistrationEvent(t,
|
testServiceHealthDeregistrationEvent(t,
|
||||||
|
@ -1342,7 +1342,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1384,7 +1384,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1412,7 +1412,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1444,7 +1444,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1459,7 +1459,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err = ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err = ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -1518,7 +1518,7 @@ func TestServiceHealthEventsFromChanges(t *testing.T) {
|
||||||
},
|
},
|
||||||
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
EnterpriseMeta: *structs.DefaultEnterpriseMeta(),
|
||||||
}
|
}
|
||||||
err := ensureConfigEntryTxn(tx, tx.Index, configEntry, structs.DefaultEnterpriseMeta())
|
err := ensureConfigEntryTxn(tx, tx.Index, configEntry)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue