mirror of
https://github.com/minio/minio.git
synced 2025-11-20 01:50:24 -05:00
In FS or single-node XL mode, there is no need to save listener configuration to persistent storage. As there is only one server, if it is restarted, any connected listenBucketAPI clients were disconnected and will have to reconnect - so there is nothing to actually store. This incidentally solves #3052 by avoiding the problem.
This commit is contained in:
committed by
Harshavardhana
parent
a15dc5fed5
commit
30dc11a931
@@ -347,6 +347,13 @@ func loadNotificationConfig(bucket string, objAPI ObjectLayer) (*notificationCon
|
||||
// loads notification config if any for a given bucket, returns
|
||||
// structured notification config.
|
||||
func loadListenerConfig(bucket string, objAPI ObjectLayer) ([]listenerConfig, error) {
|
||||
// in single node mode, there are no peers, so in this case
|
||||
// there is no configuration to load, as any previously
|
||||
// connected listen clients have been disconnected
|
||||
if !globalS3Peers.isDistXL {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
// Construct the notification config path.
|
||||
listenerConfigPath := path.Join(bucketConfigPrefix, bucket, bucketListenerConfig)
|
||||
objInfo, err := objAPI.GetObjectInfo(minioMetaBucket, listenerConfigPath)
|
||||
|
||||
Reference in New Issue
Block a user