feat: add ip to uk_scheduler index and uk_seed_peer index in manager (#2426)
Signed-off-by: Gaius <gaius.qi@gmail.com>
This commit is contained in:
parent
e6049d2362
commit
7546bfc945
|
|
@ -29,7 +29,7 @@ type Scheduler struct {
|
|||
Hostname string `gorm:"column:host_name;type:varchar(256);index:uk_scheduler,unique;not null;comment:hostname" json:"host_name"`
|
||||
IDC string `gorm:"column:idc;type:varchar(1024);comment:internet data center" json:"idc"`
|
||||
Location string `gorm:"column:location;type:varchar(1024);comment:location" json:"location"`
|
||||
IP string `gorm:"column:ip;type:varchar(256);not null;comment:ip address" json:"ip"`
|
||||
IP string `gorm:"column:ip;type:varchar(256);index:uk_scheduler,unique;not null;comment:ip address" json:"ip"`
|
||||
Port int32 `gorm:"column:port;not null;comment:grpc service listening port" json:"port"`
|
||||
State string `gorm:"column:state;type:varchar(256);default:'inactive';comment:service state" json:"state"`
|
||||
Features Array `gorm:"column:features;comment:feature flags" json:"features"`
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ type SeedPeer struct {
|
|||
Type string `gorm:"column:type;type:varchar(256);comment:type" json:"type"`
|
||||
IDC string `gorm:"column:idc;type:varchar(1024);comment:internet data center" json:"idc"`
|
||||
Location string `gorm:"column:location;type:varchar(1024);comment:location" json:"location"`
|
||||
IP string `gorm:"column:ip;type:varchar(256);not null;comment:ip address" json:"ip"`
|
||||
IP string `gorm:"column:ip;type:varchar(256);index:uk_seed_peer,unique;not null;comment:ip address" json:"ip"`
|
||||
Port int32 `gorm:"column:port;not null;comment:grpc service listening port" json:"port"`
|
||||
DownloadPort int32 `gorm:"column:download_port;not null;comment:download service listening port" json:"download_port"`
|
||||
ObjectStoragePort int32 `gorm:"column:object_storage_port;comment:object storage service listening port" json:"object_storage_port"`
|
||||
|
|
|
|||
Loading…
Reference in New Issue