(t cluster.Target)
| 47 | ) |
| 48 | |
| 49 | func initManager(t cluster.Target) error { |
| 50 | var ( |
| 51 | netReq, netResp = cmn.NetIntraControl, cmn.NetIntraData |
| 52 | sowner = t.Sowner() |
| 53 | smap = sowner.Get() |
| 54 | ) |
| 55 | ECM = &Manager{ |
| 56 | netReq: netReq, |
| 57 | netResp: netResp, |
| 58 | t: t, |
| 59 | smap: smap, |
| 60 | targetCnt: *atomic.NewInt32(int32(smap.CountActiveTargets())), |
| 61 | bmd: t.Bowner().Get(), |
| 62 | xacts: make(map[string]*BckXacts), |
| 63 | } |
| 64 | |
| 65 | if ECM.bmd.IsECUsed() { |
| 66 | return ECM.initECBundles() |
| 67 | } |
| 68 | return nil |
| 69 | } |
| 70 | |
| 71 | func (mgr *Manager) req() *bundle.Streams { |
| 72 | return (*bundle.Streams)(mgr.reqBundle.Load()) |
no test coverage detected