Browse Source

remove extra code

pull/2/head
Chris Lu 13 years ago
parent
commit
c51884ce23
  1. 1
      weed-fs/src/pkg/topology/topology.go

1
weed-fs/src/pkg/topology/topology.go

@ -19,7 +19,6 @@ func NewTopology(id NodeId) *Topology{
func (t *Topology) RandomlyReserveOneVolume() (bool, *Node, storage.VolumeId) { func (t *Topology) RandomlyReserveOneVolume() (bool, *Node, storage.VolumeId) {
slots := t.Node.maxVolumeCount-t.Node.activeVolumeCount slots := t.Node.maxVolumeCount-t.Node.activeVolumeCount
r := rand.Intn(slots) r := rand.Intn(slots)
r = rand.Intn(slots)
fmt.Println("slots:", slots, "random :", r) fmt.Println("slots:", slots, "random :", r)
vid := t.nextVolumeId() vid := t.nextVolumeId()
ret, node := t.Node.ReserveOneVolume(r,vid) ret, node := t.Node.ReserveOneVolume(r,vid)

Loading…
Cancel
Save