mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
revert to non-streaming mode to assign file id
fix https://github.com/seaweedfs/seaweedfs/issues/4838#issuecomment-1722290685
This commit is contained in:
parent
4650c4c65f
commit
b590a68e75
|
@ -94,9 +94,6 @@ type FilerServer struct {
|
||||||
// track known metadata listeners
|
// track known metadata listeners
|
||||||
knownListenersLock sync.Mutex
|
knownListenersLock sync.Mutex
|
||||||
knownListeners map[int32]int32
|
knownListeners map[int32]int32
|
||||||
|
|
||||||
// client to assign file id
|
|
||||||
assignProxy *operation.AssignProxy
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewFilerServer(defaultMux, readonlyMux *http.ServeMux, option *FilerOption) (fs *FilerServer, err error) {
|
func NewFilerServer(defaultMux, readonlyMux *http.ServeMux, option *FilerOption) (fs *FilerServer, err error) {
|
||||||
|
@ -135,8 +132,6 @@ func NewFilerServer(defaultMux, readonlyMux *http.ServeMux, option *FilerOption)
|
||||||
go stats.LoopPushingMetric("filer", string(fs.option.Host), fs.metricsAddress, fs.metricsIntervalSec)
|
go stats.LoopPushingMetric("filer", string(fs.option.Host), fs.metricsAddress, fs.metricsIntervalSec)
|
||||||
go fs.filer.KeepMasterClientConnected()
|
go fs.filer.KeepMasterClientConnected()
|
||||||
|
|
||||||
fs.assignProxy, err = operation.NewAssignProxy(fs.filer.GetMaster, fs.grpcDialOption, 16)
|
|
||||||
|
|
||||||
if !util.LoadConfiguration("filer", false) {
|
if !util.LoadConfiguration("filer", false) {
|
||||||
v.SetDefault("leveldb2.enabled", true)
|
v.SetDefault("leveldb2.enabled", true)
|
||||||
v.SetDefault("leveldb2.dir", option.DefaultLevelDbDir)
|
v.SetDefault("leveldb2.dir", option.DefaultLevelDbDir)
|
||||||
|
@ -189,7 +184,7 @@ func NewFilerServer(defaultMux, readonlyMux *http.ServeMux, option *FilerOption)
|
||||||
|
|
||||||
fs.filer.Dlm.LockRing.SetTakeSnapshotCallback(fs.OnDlmChangeSnapshot)
|
fs.filer.Dlm.LockRing.SetTakeSnapshotCallback(fs.OnDlmChangeSnapshot)
|
||||||
|
|
||||||
return fs, err
|
return fs, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (fs *FilerServer) checkWithMaster() {
|
func (fs *FilerServer) checkWithMaster() {
|
||||||
|
|
Loading…
Reference in a new issue