2021-01-29 03:04:36 +03:00
|
|
|
package placementrouter
|
|
|
|
|
|
|
|
import (
|
2023-03-07 16:38:26 +03:00
|
|
|
cid "git.frostfs.info/TrueCloudLab/frostfs-sdk-go/container/id"
|
|
|
|
"git.frostfs.info/TrueCloudLab/frostfs-sdk-go/netmap"
|
2021-01-29 03:04:36 +03:00
|
|
|
)
|
|
|
|
|
2023-02-05 18:59:38 +03:00
|
|
|
// PlacementBuilder describes interface of FrostFS placement calculator.
|
2021-01-29 03:04:36 +03:00
|
|
|
type PlacementBuilder interface {
|
|
|
|
// BuildPlacement must compose and sort (according to a specific algorithm)
|
2022-05-31 20:00:41 +03:00
|
|
|
// storage nodes from the container by its identifier using network map
|
2021-01-29 03:04:36 +03:00
|
|
|
// of particular epoch.
|
2022-06-09 02:18:26 +03:00
|
|
|
BuildPlacement(epoch uint64, cnr cid.ID) ([][]netmap.NodeInfo, error)
|
2021-01-29 03:04:36 +03:00
|
|
|
}
|