Skip to content

Commit

Permalink
feat(restore): skip loading endpoint during initiator start when dmDe…
Browse files Browse the repository at this point in the history
…viceAndEndpointCleanupRequired

longhorn/longhorn-6613

Signed-off-by: Chin-Ya Huang <[email protected]>
  • Loading branch information
c3y1huang committed Aug 1, 2024
1 parent ca31a06 commit 44cc29b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/nvme/initiator.go
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ func (i *Initiator) Start(transportAddress, transportServiceID string, dmDeviceA
// Check if the initiator/NVMe device is already launched and matches the params
if err := i.loadNVMeDeviceInfoWithoutLock(i.TransportAddress, i.TransportServiceID, i.SubsystemNQN); err == nil {
if i.TransportAddress == transportAddress && i.TransportServiceID == transportServiceID {
if err = i.LoadEndpoint(false); err == nil {
if err = i.LoadEndpoint(dmDeviceAndEndpointCleanupRequired); err == nil {

Check warning on line 264 in pkg/nvme/initiator.go

View check run for this annotation

Codecov / codecov/patch

pkg/nvme/initiator.go#L264

Added line #L264 was not covered by tests
i.logger.Info("NVMe initiator is already launched with correct params")
return false, nil
}
Expand Down

0 comments on commit 44cc29b

Please sign in to comment.