Documentation ¶
Index ¶
- Constants
- type HostServiceImpl
- func (i *HostServiceImpl) Config()
- func (i *HostServiceImpl) CreateHost(ctx context.Context, ins *host.Host) (*host.Host, error)
- func (i *HostServiceImpl) DeleteHost(ctx context.Context, req *host.DeleteHostRequest) error
- func (i *HostServiceImpl) DescribeHost(ctx context.Context, req *host.DescribeHostRequest) (*host.Host, error)
- func (i *HostServiceImpl) Name() string
- func (i *HostServiceImpl) QueryHost(ctx context.Context, req *host.QueryHostRequest) (*host.HostSet, error)
- func (i *HostServiceImpl) UpdateHost(ctx context.Context, req *host.UpdateHostRequest) (*host.Host, error)
Constants ¶
View Source
const ( InsertResourceSQL = `` /* 223-byte string literal not displayed */ // INSERT INTO `host` ( resource_id, cpu, memory, gpu_amount, gpu_spec, os_type, os_name, serial_number ) // VALUES // ( "111", 1, 2048, 1, 'n', 'linux', 'centos8', '00000' ); InsertDescribeSQL = `` /* 135-byte string literal not displayed */ // -- 1页2条数据, 2 offset: (page_number-1)*page_size // SELECT * FROM resource AS r LEFT JOIN `host` AS h ON r.id=h.resource_id WHERE id LIKE 'ins-0%' LIMIT 2,2 ; QueryHostSQL = `` /* 163-byte string literal not displayed */ )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HostServiceImpl ¶
type HostServiceImpl struct {
// contains filtered or unexported fields
}
func NewhostServiceImpl ¶
func NewhostServiceImpl() *HostServiceImpl
func (*HostServiceImpl) CreateHost ¶
func (*HostServiceImpl) DeleteHost ¶
func (i *HostServiceImpl) DeleteHost(ctx context.Context, req *host.DeleteHostRequest) error
func (*HostServiceImpl) DescribeHost ¶
func (i *HostServiceImpl) DescribeHost(ctx context.Context, req *host.DescribeHostRequest) ( *host.Host, error)
func (*HostServiceImpl) QueryHost ¶
func (i *HostServiceImpl) QueryHost(ctx context.Context, req *host.QueryHostRequest) (*host.HostSet, error)
func (*HostServiceImpl) UpdateHost ¶
func (i *HostServiceImpl) UpdateHost(ctx context.Context, req *host.UpdateHostRequest) ( *host.Host, error)
Click to show internal directories.
Click to hide internal directories.