Svc REST: rename allocServiceNodePortsNew

This commit is contained in:
Tim Hockin 2021-08-24 21:44:17 -07:00
parent f94782b4f5
commit 3b971b137c

View File

@ -85,7 +85,7 @@ func (al *RESTAllocStuff) allocateCreate(service *api.Service, dryRun bool) (tra
} }
// Allocate ports // Allocate ports
if txn, err := al.allocServiceNodePortsNew(service, dryRun); err != nil { if txn, err := al.txnAllocNodePorts(service, dryRun); err != nil {
result.Revert() result.Revert()
return nil, err return nil, err
} else { } else {
@ -956,8 +956,7 @@ func allocateHealthCheckNodePort(service *api.Service, nodePortOp *portallocator
return nil return nil
} }
//FIXME: rename and merge with initNodePorts func (al *RESTAllocStuff) txnAllocNodePorts(service *api.Service, dryRun bool) (transaction, error) {
func (al *RESTAllocStuff) allocServiceNodePortsNew(service *api.Service, dryRun bool) (transaction, error) {
// The allocator tracks dry-run-ness internally. // The allocator tracks dry-run-ness internally.
nodePortOp := portallocator.StartOperation(al.serviceNodePorts, dryRun) nodePortOp := portallocator.StartOperation(al.serviceNodePorts, dryRun)