Compare commits
3 Commits
8ead0d1bf6
...
e33590fba2
Author | SHA1 | Date | |
---|---|---|---|
e33590fba2 | |||
55b68a28c8 | |||
dac1de28b6 |
@ -1,240 +0,0 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"encoding/xml"
|
||||
"fmt"
|
||||
"log"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"deevirt.fr/compute/pkg/amqp"
|
||||
"deevirt.fr/compute/pkg/config"
|
||||
"deevirt.fr/compute/pkg/schema"
|
||||
clientv3 "go.etcd.io/etcd/client/v3"
|
||||
"libvirt.org/go/libvirt"
|
||||
)
|
||||
|
||||
func AgentLifecycle(c *libvirt.Connect, d *libvirt.Domain, event *libvirt.DomainEventAgentLifecycle) {
|
||||
println(event.State)
|
||||
println(event.Reason)
|
||||
|
||||
}
|
||||
|
||||
func Graphics(c *libvirt.Connect, d *libvirt.Domain, event *libvirt.DomainEventGraphics) {
|
||||
println(event.String())
|
||||
}
|
||||
|
||||
func JobCompleted(c *libvirt.Connect, d *libvirt.Domain, e *libvirt.DomainEventJobCompleted) {
|
||||
println(e.Info.DataRemaining)
|
||||
}
|
||||
|
||||
func MigrationIteration(c *libvirt.Connect, d *libvirt.Domain, e *libvirt.DomainEventMigrationIteration) {
|
||||
println(e.Iteration)
|
||||
}
|
||||
|
||||
func Lifecyle(c *libvirt.Connect, d *libvirt.Domain, e *libvirt.DomainEventLifecycle) {
|
||||
var detail, event string
|
||||
config, _ := config.New()
|
||||
domainID, _ := d.GetUUIDString()
|
||||
|
||||
etcd, err := clientv3.New(clientv3.Config{
|
||||
Endpoints: strings.Split(config.EtcdURI, ","),
|
||||
DialTimeout: 5 * time.Second,
|
||||
})
|
||||
if err != nil {
|
||||
log.Fatalf("Error connexion to etcd: %v", err)
|
||||
}
|
||||
defer etcd.Close()
|
||||
|
||||
switch e.Event {
|
||||
case libvirt.DOMAIN_EVENT_DEFINED:
|
||||
event = "defined"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Put(ctx, "/cluster/"+config.ClusterID+"/host/"+config.NodeID+"/qemu/"+domainID, "")
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventDefinedDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_DEFINED_ADDED:
|
||||
detail = "added"
|
||||
case libvirt.DOMAIN_EVENT_DEFINED_UPDATED:
|
||||
detail = "updated"
|
||||
case libvirt.DOMAIN_EVENT_DEFINED_RENAMED:
|
||||
detail = "renamed"
|
||||
case libvirt.DOMAIN_EVENT_DEFINED_FROM_SNAPSHOT:
|
||||
detail = "snapshot"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
case libvirt.DOMAIN_EVENT_UNDEFINED:
|
||||
event = "undefined"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Delete(ctx, "/cluster/"+config.ClusterID+"/host/"+config.NodeID+"/qemu/"+domainID)
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventUndefinedDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_UNDEFINED_REMOVED:
|
||||
detail = "removed"
|
||||
case libvirt.DOMAIN_EVENT_UNDEFINED_RENAMED:
|
||||
detail = "renamed"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
case libvirt.DOMAIN_EVENT_STARTED:
|
||||
event = "started"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Put(ctx, "/cluster/"+config.ClusterID+"/domain/"+domainID+"/state", "2")
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventStartedDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_STARTED_BOOTED:
|
||||
detail = "booted"
|
||||
case libvirt.DOMAIN_EVENT_STARTED_MIGRATED:
|
||||
detail = "migrated"
|
||||
case libvirt.DOMAIN_EVENT_STARTED_RESTORED:
|
||||
detail = "restored"
|
||||
case libvirt.DOMAIN_EVENT_STARTED_FROM_SNAPSHOT:
|
||||
detail = "snapshot"
|
||||
case libvirt.DOMAIN_EVENT_STARTED_WAKEUP:
|
||||
detail = "wakeup"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED:
|
||||
event = "suspended"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Put(ctx, "/cluster/"+config.ClusterID+"/domain/"+domainID+"/state", "3")
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventSuspendedDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_PAUSED:
|
||||
detail = "paused"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_MIGRATED:
|
||||
detail = "migrated"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_IOERROR:
|
||||
detail = "I/O error"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_WATCHDOG:
|
||||
detail = "watchdog"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_RESTORED:
|
||||
detail = "restored"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_FROM_SNAPSHOT:
|
||||
detail = "snapshot"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_API_ERROR:
|
||||
detail = "api error"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_POSTCOPY:
|
||||
detail = "postcopy"
|
||||
case libvirt.DOMAIN_EVENT_SUSPENDED_POSTCOPY_FAILED:
|
||||
detail = "postcopy failed"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
case libvirt.DOMAIN_EVENT_RESUMED:
|
||||
event = "resumed"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Put(ctx, "/cluster/"+config.ClusterID+"/domain/"+domainID+"/state", "4")
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventResumedDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_RESUMED_UNPAUSED:
|
||||
detail = "unpaused"
|
||||
case libvirt.DOMAIN_EVENT_RESUMED_MIGRATED:
|
||||
detail = "migrated"
|
||||
case libvirt.DOMAIN_EVENT_RESUMED_FROM_SNAPSHOT:
|
||||
detail = "snapshot"
|
||||
case libvirt.DOMAIN_EVENT_RESUMED_POSTCOPY:
|
||||
detail = "postcopy"
|
||||
case libvirt.DOMAIN_EVENT_RESUMED_POSTCOPY_FAILED:
|
||||
detail = "postcopy failed"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
case libvirt.DOMAIN_EVENT_STOPPED:
|
||||
event = "stopped"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Put(ctx, "/cluster/"+config.ClusterID+"/domain/"+domainID+"/state", "5")
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventStoppedDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_SHUTDOWN:
|
||||
detail = "shutdown"
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_DESTROYED:
|
||||
detail = "destroyed"
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_CRASHED:
|
||||
detail = "crashed"
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_MIGRATED:
|
||||
detail = "migrated"
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_SAVED:
|
||||
detail = "saved"
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_FAILED:
|
||||
detail = "failed"
|
||||
case libvirt.DOMAIN_EVENT_STOPPED_FROM_SNAPSHOT:
|
||||
detail = "snapshot"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
case libvirt.DOMAIN_EVENT_SHUTDOWN:
|
||||
event = "shutdown"
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
etcd.Put(ctx, "/cluster/"+config.ClusterID+"/domain/"+domainID+"/state", "6")
|
||||
cancel()
|
||||
|
||||
switch libvirt.DomainEventShutdownDetailType(e.Detail) {
|
||||
case libvirt.DOMAIN_EVENT_SHUTDOWN_FINISHED:
|
||||
detail = "finished"
|
||||
case libvirt.DOMAIN_EVENT_SHUTDOWN_GUEST:
|
||||
detail = "guest"
|
||||
case libvirt.DOMAIN_EVENT_SHUTDOWN_HOST:
|
||||
detail = "host"
|
||||
default:
|
||||
detail = "unknown"
|
||||
}
|
||||
|
||||
default:
|
||||
event = "unknown"
|
||||
}
|
||||
|
||||
// Send event for all clients
|
||||
if e.Event != libvirt.DOMAIN_EVENT_DEFINED|libvirt.DOMAIN_EVENT_UNDEFINED {
|
||||
xmlDesc, err := d.GetXMLDesc(0)
|
||||
if err != nil {
|
||||
log.Fatalln(err)
|
||||
}
|
||||
var desc schema.Domain
|
||||
err = xml.Unmarshal([]byte(xmlDesc), &desc)
|
||||
if err != nil {
|
||||
log.Fatalln(err)
|
||||
}
|
||||
|
||||
state, _ := json.Marshal(&schema.DomainStateJSON{
|
||||
CompanyID: desc.Metadata.DeevirtInstance.DeevirtCompanyID,
|
||||
DatacenterID: desc.Metadata.DeevirtInstance.DeevirtDatacenterID,
|
||||
DomainID: domainID,
|
||||
State: int64(e.Event),
|
||||
})
|
||||
|
||||
a, _ := amqp.NewAMQP()
|
||||
a.Publisher("vmcenter",
|
||||
"events."+desc.Metadata.DeevirtInstance.DeevirtCompanyID+
|
||||
"."+desc.Metadata.DeevirtInstance.DeevirtDatacenterID+
|
||||
"."+domainID,
|
||||
state)
|
||||
a.Close()
|
||||
}
|
||||
|
||||
fmt.Printf("Domain event=%q detail=%q\n", event, detail)
|
||||
}
|
||||
|
||||
func Reboot(c *libvirt.Connect, d *libvirt.Domain) {
|
||||
|
||||
}
|
||||
|
||||
func Watchdog(c *libvirt.Connect, d *libvirt.Domain, event *libvirt.DomainEventWatchdog) {
|
||||
println(event.String())
|
||||
}
|
60
cmd/monitor/events/qemu.go
Normal file
60
cmd/monitor/events/qemu.go
Normal file
@ -0,0 +1,60 @@
|
||||
package events
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"encoding/xml"
|
||||
"log"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"deevirt.fr/compute/pkg/config"
|
||||
"deevirt.fr/compute/pkg/schema"
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/credentials/insecure"
|
||||
"libvirt.org/go/libvirt"
|
||||
|
||||
pb "deevirt.fr/compute/pkg/api/proto"
|
||||
)
|
||||
|
||||
type Qemu struct {
|
||||
NodeID string
|
||||
CompanyID string
|
||||
DatacenterID string
|
||||
DomainID string
|
||||
Event *libvirt.DomainQemuMonitorEvent
|
||||
}
|
||||
|
||||
func QemuEvents(c *libvirt.Connect, d *libvirt.Domain, event *libvirt.DomainQemuMonitorEvent) {
|
||||
var desc schema.Domain
|
||||
config, _ := config.New()
|
||||
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
|
||||
defer cancel()
|
||||
|
||||
domainID, _ := d.GetUUIDString()
|
||||
xmlDesc, _ := d.GetXMLDesc(0)
|
||||
err := xml.Unmarshal([]byte(xmlDesc), &desc)
|
||||
if err != nil {
|
||||
log.Fatalln(err)
|
||||
}
|
||||
|
||||
e, _ := json.Marshal(&Qemu{
|
||||
NodeID: config.NodeID,
|
||||
CompanyID: desc.Metadata.DeevirtInstance.DeevirtCompanyID,
|
||||
DatacenterID: desc.Metadata.DeevirtInstance.DeevirtDatacenterID,
|
||||
DomainID: domainID,
|
||||
Event: event,
|
||||
})
|
||||
|
||||
conn, err := grpc.NewClient(strings.Join(config.Manager.Peers, ","), grpc.WithTransportCredentials(insecure.NewCredentials()))
|
||||
if err != nil {
|
||||
log.Fatalf("Erreur de connexion : %v", err)
|
||||
}
|
||||
defer conn.Close()
|
||||
client := pb.NewDomainClient(conn)
|
||||
|
||||
client.Event(ctx, &pb.DomainEventRequest{
|
||||
Event: e,
|
||||
})
|
||||
}
|
@ -22,13 +22,7 @@ func Server() {
|
||||
|
||||
conn.SetKeepAlive(5, 3)
|
||||
|
||||
conn.DomainEventAgentLifecycleRegister(nil, AgentLifecycle)
|
||||
conn.DomainEventGraphicsRegister(nil, Graphics)
|
||||
conn.DomainEventJobCompletedRegister(nil, JobCompleted)
|
||||
conn.DomainEventMigrationIterationRegister(nil, MigrationIteration)
|
||||
conn.DomainEventLifecycleRegister(nil, Lifecyle)
|
||||
conn.DomainEventRebootRegister(nil, Reboot)
|
||||
conn.DomainEventWatchdogRegister(nil, Watchdog)
|
||||
conn.DomainQemuMonitorEventRegister(nil, "(.*)", QemuEvents, libvirt.CONNECT_DOMAIN_QEMU_MONITOR_EVENT_REGISTER_REGEX)
|
||||
|
||||
for {
|
||||
libvirt.EventRunDefaultImpl()
|
||||
|
@ -1,13 +1,23 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"deevirt.fr/compute/cmd/monitor/events"
|
||||
"deevirt.fr/compute/cmd/monitor/metrics"
|
||||
|
||||
"github.com/coreos/go-systemd/v22/daemon"
|
||||
)
|
||||
|
||||
func main() {
|
||||
go metrics.Server()
|
||||
go events.Server()
|
||||
|
||||
select {}
|
||||
daemon.SdNotify(false, daemon.SdNotifyReady)
|
||||
|
||||
for {
|
||||
daemon.SdNotify(false, daemon.SdNotifyWatchdog)
|
||||
|
||||
time.Sleep(5 * time.Second)
|
||||
}
|
||||
}
|
||||
|
@ -5,7 +5,6 @@ import (
|
||||
"log"
|
||||
"strconv"
|
||||
|
||||
"deevirt.fr/compute/pkg/config"
|
||||
"deevirt.fr/compute/pkg/schema"
|
||||
"github.com/prometheus/client_golang/prometheus"
|
||||
"libvirt.org/go/libvirt"
|
||||
@ -231,11 +230,6 @@ var (
|
||||
)
|
||||
|
||||
func CollectDomain(ch chan<- prometheus.Metric, stat libvirt.DomainStats, hostname string) error {
|
||||
config, err := config.New()
|
||||
if err != nil {
|
||||
log.Fatalln(err)
|
||||
}
|
||||
|
||||
domainUUID, err := stat.Domain.GetUUIDString()
|
||||
if err != nil {
|
||||
return err
|
||||
@ -295,15 +289,15 @@ func CollectDomain(ch chan<- prometheus.Metric, stat libvirt.DomainStats, hostna
|
||||
domainUUID)
|
||||
|
||||
// Block Stats
|
||||
CollectDomainVCPU(ch, stat.Vcpu, hostname, domainUUID, config, desc)
|
||||
CollectDomainBlock(ch, stat.Block, hostname, domainUUID, config, desc)
|
||||
CollectDomainNet(ch, stat.Net, hostname, domainUUID, config, desc)
|
||||
CollectDomainBalloon(ch, stat.Balloon, hostname, domainUUID, config, desc)
|
||||
CollectDomainVCPU(ch, stat.Vcpu, hostname, domainUUID, desc)
|
||||
CollectDomainBlock(ch, stat.Block, hostname, domainUUID, desc)
|
||||
CollectDomainNet(ch, stat.Net, hostname, domainUUID, desc)
|
||||
CollectDomainBalloon(ch, stat.Balloon, hostname, domainUUID, desc)
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func CollectDomainVCPU(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsVcpu, hostname string, domainUUID string, config *config.Config, desc schema.Domain) {
|
||||
func CollectDomainVCPU(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsVcpu, hostname string, domainUUID string, desc schema.Domain) {
|
||||
for idx, vcpu := range stat {
|
||||
ch <- prometheus.MustNewConstMetric(
|
||||
libvirtDomainVcpuState,
|
||||
@ -341,7 +335,7 @@ func CollectDomainVCPU(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsVc
|
||||
}
|
||||
}
|
||||
|
||||
func CollectDomainBalloon(ch chan<- prometheus.Metric, stat *libvirt.DomainStatsBalloon, hostname string, domainUUID string, config *config.Config, desc schema.Domain) {
|
||||
func CollectDomainBalloon(ch chan<- prometheus.Metric, stat *libvirt.DomainStatsBalloon, hostname string, domainUUID string, desc schema.Domain) {
|
||||
ch <- prometheus.MustNewConstMetric(
|
||||
libvirtDomainBalloonStatCurrentBytes,
|
||||
prometheus.GaugeValue,
|
||||
@ -422,7 +416,7 @@ func CollectDomainBalloon(ch chan<- prometheus.Metric, stat *libvirt.DomainStats
|
||||
|
||||
}
|
||||
|
||||
func CollectDomainBlock(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsBlock, hostname string, domainUUID string, config *config.Config, desc schema.Domain) {
|
||||
func CollectDomainBlock(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsBlock, hostname string, domainUUID string, desc schema.Domain) {
|
||||
for _, block := range stat {
|
||||
|
||||
if block.RdBytesSet {
|
||||
@ -538,7 +532,7 @@ func CollectDomainBlock(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsB
|
||||
}
|
||||
}
|
||||
|
||||
func CollectDomainNet(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsNet, hostname string, domainUUID string, config *config.Config, desc schema.Domain) {
|
||||
func CollectDomainNet(ch chan<- prometheus.Metric, stat []libvirt.DomainStatsNet, hostname string, domainUUID string, desc schema.Domain) {
|
||||
for _, iface := range stat {
|
||||
|
||||
if iface.RxBytesSet {
|
||||
|
10
go.mod
10
go.mod
@ -5,6 +5,7 @@ go 1.23
|
||||
toolchain go1.24.0
|
||||
|
||||
require (
|
||||
github.com/coreos/go-systemd/v22 v22.5.0
|
||||
github.com/denisbrodbeck/machineid v1.0.1
|
||||
github.com/hashicorp/go-multierror v1.1.1
|
||||
github.com/hashicorp/raft v1.7.2
|
||||
@ -27,12 +28,9 @@ require (
|
||||
github.com/boltdb/bolt v1.3.1 // indirect
|
||||
github.com/cespare/xxhash/v2 v2.3.0 // indirect
|
||||
github.com/coreos/go-semver v0.3.1 // indirect
|
||||
github.com/coreos/go-systemd/v22 v22.5.0 // indirect
|
||||
github.com/fatih/color v1.15.0 // indirect
|
||||
github.com/gogo/protobuf v1.3.2 // indirect
|
||||
github.com/golang/protobuf v1.5.4 // indirect
|
||||
github.com/google/licensecheck v0.3.1 // indirect
|
||||
github.com/google/safehtml v0.0.3-0.20211026203422-d6f0e11a5516 // indirect
|
||||
github.com/hashicorp/errwrap v1.1.0 // indirect
|
||||
github.com/hashicorp/go-hclog v1.6.2 // indirect
|
||||
github.com/hashicorp/go-immutable-radix v1.3.1 // indirect
|
||||
@ -54,14 +52,10 @@ require (
|
||||
go.etcd.io/etcd/api/v3 v3.5.18 // indirect
|
||||
go.etcd.io/etcd/client/pkg/v3 v3.5.18 // indirect
|
||||
go.uber.org/multierr v1.11.0 // indirect
|
||||
golang.org/x/mod v0.23.0 // indirect
|
||||
golang.org/x/net v0.35.0 // indirect
|
||||
golang.org/x/pkgsite v0.0.0-20250214205047-dd488e5da97a // indirect
|
||||
golang.org/x/sync v0.11.0 // indirect
|
||||
golang.org/x/oauth2 v0.26.0 // indirect
|
||||
golang.org/x/sys v0.30.0 // indirect
|
||||
golang.org/x/text v0.22.0 // indirect
|
||||
golang.org/x/tools v0.30.0 // indirect
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20250207221924-e9438ea467c6 // indirect
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6 // indirect
|
||||
rsc.io/markdown v0.0.0-20231214224604-88bb533a6020 // indirect
|
||||
)
|
||||
|
17
go.sum
17
go.sum
@ -67,10 +67,6 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
|
||||
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
|
||||
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
|
||||
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
|
||||
github.com/google/licensecheck v0.3.1 h1:QoxgoDkaeC4nFrtGN1jV7IPmDCHFNIVh54e5hSt6sPs=
|
||||
github.com/google/licensecheck v0.3.1/go.mod h1:ORkR35t/JjW+emNKtfJDII0zlciG9JgbT7SmsohlHmY=
|
||||
github.com/google/safehtml v0.0.3-0.20211026203422-d6f0e11a5516 h1:pSEdbeokt55L2hwtWo6A2k7u5SG08rmw0LhWEyrdWgk=
|
||||
github.com/google/safehtml v0.0.3-0.20211026203422-d6f0e11a5516/go.mod h1:L4KWwDsUJdECRAEpZoBn3O64bQaywRscowZjJAzjHnU=
|
||||
github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0=
|
||||
github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
||||
@ -231,8 +227,6 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.23.0 h1:Zb7khfcRGKk+kqfxFaP5tZqCnDZMjC5VtUBs87Hr6QM=
|
||||
golang.org/x/mod v0.23.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
@ -247,19 +241,14 @@ golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwY
|
||||
golang.org/x/net v0.35.0 h1:T5GQRQb2y08kTAByq9L4/bz8cipCdA8FbRTXewonqY8=
|
||||
golang.org/x/net v0.35.0/go.mod h1:EglIi67kWsHKlRzzVMUD93VMSWGFOMSZgxFjparz1Qk=
|
||||
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
golang.org/x/oauth2 v0.24.0 h1:KTBBxWqUa0ykRPLtV69rRto9TLXcqYkeswu48x/gvNE=
|
||||
golang.org/x/oauth2 v0.24.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI=
|
||||
golang.org/x/oauth2 v0.26.0 h1:afQXWNNaeC4nvZ0Ed9XvCCzXM6UHJG7iCg0W4fPqSBE=
|
||||
golang.org/x/pkgsite v0.0.0-20250214205047-dd488e5da97a h1:kCR3oJNguchcd+dDsr60kYG02n1u5m3o3mkTsmPzWZ4=
|
||||
golang.org/x/pkgsite v0.0.0-20250214205047-dd488e5da97a/go.mod h1:8OazZd0McXcf+pKcTTL90fYlNZyE62+AQbEpxbE7lHk=
|
||||
golang.org/x/oauth2 v0.26.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.11.0 h1:GGz8+XQP4FvTTrjZPzNKTMFtSXH80RAzG+5ghFPgK9w=
|
||||
golang.org/x/sync v0.11.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
|
||||
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
@ -293,8 +282,6 @@ golang.org/x/tools v0.0.0-20190424220101-1e8e1cfdf96b/go.mod h1:RgjU9mgBXZiqYHBn
|
||||
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
|
||||
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
|
||||
golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY=
|
||||
golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
@ -331,5 +318,3 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
|
||||
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
libvirt.org/go/libvirt v1.11001.0 h1:QJgpslxY7qkpXZIDxdMHpkDl7FfhgQJwqRTGBbg/S8E=
|
||||
libvirt.org/go/libvirt v1.11001.0/go.mod h1:1WiFE8EjZfq+FCVog+rvr1yatKbKZ9FaFMZgEqxEJqQ=
|
||||
rsc.io/markdown v0.0.0-20231214224604-88bb533a6020 h1:GqQcl3Kno/rOntek8/d8axYjau8r/c1zVFojXS6WJFI=
|
||||
rsc.io/markdown v0.0.0-20231214224604-88bb533a6020/go.mod h1:8xcPgWmwlZONN1D9bjxtHEjrUtSEa3fakVF8iaewYKQ=
|
||||
|
@ -21,7 +21,7 @@ func (d *Domain) List(ctx context.Context, in *proto.DomainListAllRequest) (*pro
|
||||
}
|
||||
|
||||
func (d *Domain) Get(ctx context.Context, in *proto.DomainListRequest) (*proto.DomainListResponse, error) {
|
||||
d.Store.Set(in.DomainId, "test1")
|
||||
d.Store.Set(in.DomainId, "test")
|
||||
return &proto.DomainListResponse{}, nil
|
||||
}
|
||||
|
||||
|
44
pkg/api/events.go
Normal file
44
pkg/api/events.go
Normal file
@ -0,0 +1,44 @@
|
||||
package api
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
|
||||
"deevirt.fr/compute/pkg/amqp"
|
||||
"deevirt.fr/compute/pkg/api/proto"
|
||||
"libvirt.org/go/libvirt"
|
||||
)
|
||||
|
||||
type Events struct {
|
||||
NodeID string
|
||||
CompanyID string
|
||||
DatacenterID string
|
||||
DomainID string
|
||||
Event *libvirt.DomainQemuMonitorEvent
|
||||
}
|
||||
|
||||
func (d *Domain) Event(ctx context.Context, req *proto.DomainEventRequest) (*proto.DomainEventResponse, error) {
|
||||
var events Events
|
||||
|
||||
err := json.Unmarshal(req.Event, &events)
|
||||
if err != nil {
|
||||
fmt.Println("Erreur lors du décodage JSON:", err)
|
||||
}
|
||||
|
||||
// AMQP - On envoi l'évènement brut
|
||||
e, _ := json.Marshal(events.Event)
|
||||
a, _ := amqp.NewAMQP()
|
||||
a.Publisher("vmcenter",
|
||||
"events."+events.CompanyID+
|
||||
"."+events.DatacenterID+
|
||||
"."+events.DomainID,
|
||||
e)
|
||||
defer a.Close()
|
||||
|
||||
t, _ := json.Marshal(events)
|
||||
|
||||
fmt.Printf("%v\n", string(t))
|
||||
|
||||
return &proto.DomainEventResponse{}, nil
|
||||
}
|
@ -84,6 +84,91 @@ func (DomainPower) EnumDescriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
type DomainEventRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Event []byte `protobuf:"bytes,1,opt,name=event,proto3" json:"event,omitempty"`
|
||||
}
|
||||
|
||||
func (x *DomainEventRequest) Reset() {
|
||||
*x = DomainEventRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DomainEventRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DomainEventRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainEventRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DomainEventRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainEventRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *DomainEventRequest) GetEvent() []byte {
|
||||
if x != nil {
|
||||
return x.Event
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type DomainEventResponse struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
}
|
||||
|
||||
func (x *DomainEventResponse) Reset() {
|
||||
*x = DomainEventResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DomainEventResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DomainEventResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainEventResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DomainEventResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainEventResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
type DomainListAllRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
@ -93,7 +178,7 @@ type DomainListAllRequest struct {
|
||||
func (x *DomainListAllRequest) Reset() {
|
||||
*x = DomainListAllRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[0]
|
||||
mi := &file_proto_domain_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -106,7 +191,7 @@ func (x *DomainListAllRequest) String() string {
|
||||
func (*DomainListAllRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainListAllRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[0]
|
||||
mi := &file_proto_domain_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -119,7 +204,7 @@ func (x *DomainListAllRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainListAllRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainListAllRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{0}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
type DomainListAllResponse struct {
|
||||
@ -133,7 +218,7 @@ type DomainListAllResponse struct {
|
||||
func (x *DomainListAllResponse) Reset() {
|
||||
*x = DomainListAllResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[1]
|
||||
mi := &file_proto_domain_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -146,7 +231,7 @@ func (x *DomainListAllResponse) String() string {
|
||||
func (*DomainListAllResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainListAllResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[1]
|
||||
mi := &file_proto_domain_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -159,7 +244,7 @@ func (x *DomainListAllResponse) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainListAllResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainListAllResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{1}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *DomainListAllResponse) GetDomains() []*DomainListResponse {
|
||||
@ -180,7 +265,7 @@ type DomainListRequest struct {
|
||||
func (x *DomainListRequest) Reset() {
|
||||
*x = DomainListRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[2]
|
||||
mi := &file_proto_domain_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -193,7 +278,7 @@ func (x *DomainListRequest) String() string {
|
||||
func (*DomainListRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainListRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[2]
|
||||
mi := &file_proto_domain_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -206,7 +291,7 @@ func (x *DomainListRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainListRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainListRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{2}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *DomainListRequest) GetDomainId() string {
|
||||
@ -229,7 +314,7 @@ type DomainListResponse struct {
|
||||
func (x *DomainListResponse) Reset() {
|
||||
*x = DomainListResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[3]
|
||||
mi := &file_proto_domain_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -242,7 +327,7 @@ func (x *DomainListResponse) String() string {
|
||||
func (*DomainListResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainListResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[3]
|
||||
mi := &file_proto_domain_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -255,7 +340,7 @@ func (x *DomainListResponse) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainListResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainListResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{3}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *DomainListResponse) GetDomainId() string {
|
||||
@ -291,7 +376,7 @@ type DomainCreateRequest struct {
|
||||
func (x *DomainCreateRequest) Reset() {
|
||||
*x = DomainCreateRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[4]
|
||||
mi := &file_proto_domain_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -304,7 +389,7 @@ func (x *DomainCreateRequest) String() string {
|
||||
func (*DomainCreateRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainCreateRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[4]
|
||||
mi := &file_proto_domain_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -317,7 +402,7 @@ func (x *DomainCreateRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainCreateRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainCreateRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{4}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
func (x *DomainCreateRequest) GetNodeId() string {
|
||||
@ -345,7 +430,7 @@ type DomainCreateResponse struct {
|
||||
func (x *DomainCreateResponse) Reset() {
|
||||
*x = DomainCreateResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[5]
|
||||
mi := &file_proto_domain_proto_msgTypes[7]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -358,7 +443,7 @@ func (x *DomainCreateResponse) String() string {
|
||||
func (*DomainCreateResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainCreateResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[5]
|
||||
mi := &file_proto_domain_proto_msgTypes[7]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -371,7 +456,7 @@ func (x *DomainCreateResponse) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainCreateResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainCreateResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{5}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{7}
|
||||
}
|
||||
|
||||
func (x *DomainCreateResponse) GetProgress() int64 {
|
||||
@ -392,7 +477,7 @@ type DomainUpdateRequest struct {
|
||||
func (x *DomainUpdateRequest) Reset() {
|
||||
*x = DomainUpdateRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[6]
|
||||
mi := &file_proto_domain_proto_msgTypes[8]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -405,7 +490,7 @@ func (x *DomainUpdateRequest) String() string {
|
||||
func (*DomainUpdateRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainUpdateRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[6]
|
||||
mi := &file_proto_domain_proto_msgTypes[8]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -418,7 +503,7 @@ func (x *DomainUpdateRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainUpdateRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainUpdateRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{6}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{8}
|
||||
}
|
||||
|
||||
func (x *DomainUpdateRequest) GetVmId() string {
|
||||
@ -437,7 +522,7 @@ type DomainUpdateResponse struct {
|
||||
func (x *DomainUpdateResponse) Reset() {
|
||||
*x = DomainUpdateResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[7]
|
||||
mi := &file_proto_domain_proto_msgTypes[9]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -450,7 +535,7 @@ func (x *DomainUpdateResponse) String() string {
|
||||
func (*DomainUpdateResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainUpdateResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[7]
|
||||
mi := &file_proto_domain_proto_msgTypes[9]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -463,7 +548,7 @@ func (x *DomainUpdateResponse) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainUpdateResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainUpdateResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{7}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{9}
|
||||
}
|
||||
|
||||
type DomainDeleteRequest struct {
|
||||
@ -477,7 +562,7 @@ type DomainDeleteRequest struct {
|
||||
func (x *DomainDeleteRequest) Reset() {
|
||||
*x = DomainDeleteRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[8]
|
||||
mi := &file_proto_domain_proto_msgTypes[10]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -490,7 +575,7 @@ func (x *DomainDeleteRequest) String() string {
|
||||
func (*DomainDeleteRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainDeleteRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[8]
|
||||
mi := &file_proto_domain_proto_msgTypes[10]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -503,7 +588,7 @@ func (x *DomainDeleteRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainDeleteRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainDeleteRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{8}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{10}
|
||||
}
|
||||
|
||||
func (x *DomainDeleteRequest) GetVmId() string {
|
||||
@ -522,7 +607,7 @@ type DomainDeleteResponse struct {
|
||||
func (x *DomainDeleteResponse) Reset() {
|
||||
*x = DomainDeleteResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[9]
|
||||
mi := &file_proto_domain_proto_msgTypes[11]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -535,7 +620,7 @@ func (x *DomainDeleteResponse) String() string {
|
||||
func (*DomainDeleteResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainDeleteResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[9]
|
||||
mi := &file_proto_domain_proto_msgTypes[11]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -548,7 +633,7 @@ func (x *DomainDeleteResponse) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainDeleteResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainDeleteResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{9}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{11}
|
||||
}
|
||||
|
||||
type DomainPowerRequest struct {
|
||||
@ -563,7 +648,7 @@ type DomainPowerRequest struct {
|
||||
func (x *DomainPowerRequest) Reset() {
|
||||
*x = DomainPowerRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[10]
|
||||
mi := &file_proto_domain_proto_msgTypes[12]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -576,7 +661,7 @@ func (x *DomainPowerRequest) String() string {
|
||||
func (*DomainPowerRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainPowerRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[10]
|
||||
mi := &file_proto_domain_proto_msgTypes[12]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -589,7 +674,7 @@ func (x *DomainPowerRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainPowerRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainPowerRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{10}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{12}
|
||||
}
|
||||
|
||||
func (x *DomainPowerRequest) GetVmId() []byte {
|
||||
@ -615,7 +700,7 @@ type DomainPowerResponse struct {
|
||||
func (x *DomainPowerResponse) Reset() {
|
||||
*x = DomainPowerResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[11]
|
||||
mi := &file_proto_domain_proto_msgTypes[13]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -628,7 +713,7 @@ func (x *DomainPowerResponse) String() string {
|
||||
func (*DomainPowerResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainPowerResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[11]
|
||||
mi := &file_proto_domain_proto_msgTypes[13]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -641,7 +726,7 @@ func (x *DomainPowerResponse) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use DomainPowerResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainPowerResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{11}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{13}
|
||||
}
|
||||
|
||||
type DomainDevicesGraphicsConsoleRequest struct {
|
||||
@ -655,7 +740,7 @@ type DomainDevicesGraphicsConsoleRequest struct {
|
||||
func (x *DomainDevicesGraphicsConsoleRequest) Reset() {
|
||||
*x = DomainDevicesGraphicsConsoleRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[12]
|
||||
mi := &file_proto_domain_proto_msgTypes[14]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -668,7 +753,7 @@ func (x *DomainDevicesGraphicsConsoleRequest) String() string {
|
||||
func (*DomainDevicesGraphicsConsoleRequest) ProtoMessage() {}
|
||||
|
||||
func (x *DomainDevicesGraphicsConsoleRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[12]
|
||||
mi := &file_proto_domain_proto_msgTypes[14]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -681,7 +766,7 @@ func (x *DomainDevicesGraphicsConsoleRequest) ProtoReflect() protoreflect.Messag
|
||||
|
||||
// Deprecated: Use DomainDevicesGraphicsConsoleRequest.ProtoReflect.Descriptor instead.
|
||||
func (*DomainDevicesGraphicsConsoleRequest) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{12}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{14}
|
||||
}
|
||||
|
||||
func (x *DomainDevicesGraphicsConsoleRequest) GetVmId() []byte {
|
||||
@ -702,7 +787,7 @@ type DomainDevicesGraphicsConsoleResponse struct {
|
||||
func (x *DomainDevicesGraphicsConsoleResponse) Reset() {
|
||||
*x = DomainDevicesGraphicsConsoleResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_proto_domain_proto_msgTypes[13]
|
||||
mi := &file_proto_domain_proto_msgTypes[15]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -715,7 +800,7 @@ func (x *DomainDevicesGraphicsConsoleResponse) String() string {
|
||||
func (*DomainDevicesGraphicsConsoleResponse) ProtoMessage() {}
|
||||
|
||||
func (x *DomainDevicesGraphicsConsoleResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_proto_domain_proto_msgTypes[13]
|
||||
mi := &file_proto_domain_proto_msgTypes[15]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -728,7 +813,7 @@ func (x *DomainDevicesGraphicsConsoleResponse) ProtoReflect() protoreflect.Messa
|
||||
|
||||
// Deprecated: Use DomainDevicesGraphicsConsoleResponse.ProtoReflect.Descriptor instead.
|
||||
func (*DomainDevicesGraphicsConsoleResponse) Descriptor() ([]byte, []int) {
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{13}
|
||||
return file_proto_domain_proto_rawDescGZIP(), []int{15}
|
||||
}
|
||||
|
||||
func (x *DomainDevicesGraphicsConsoleResponse) GetUri() string {
|
||||
@ -742,98 +827,106 @@ var File_proto_domain_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_proto_domain_proto_rawDesc = []byte{
|
||||
0x0a, 0x12, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x2e, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x12, 0x07, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x22, 0x16, 0x0a,
|
||||
0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65,
|
||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4e, 0x0a, 0x15, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c,
|
||||
0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x35,
|
||||
0x0a, 0x07, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
|
||||
0x1b, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e,
|
||||
0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x07, 0x64, 0x6f,
|
||||
0x6d, 0x61, 0x69, 0x6e, 0x73, 0x22, 0x30, 0x0a, 0x11, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c,
|
||||
0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x64, 0x6f,
|
||||
0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x64,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x22, 0x5f, 0x0a, 0x12, 0x44, 0x6f, 0x6d, 0x61, 0x69,
|
||||
0x6e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1b, 0x0a,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x12, 0x07, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x22, 0x2a, 0x0a,
|
||||
0x12, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x0c, 0x52, 0x05, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x15, 0x0a, 0x13, 0x44, 0x6f, 0x6d,
|
||||
0x61, 0x69, 0x6e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
|
||||
0x22, 0x16, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c,
|
||||
0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x4e, 0x0a, 0x15, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
|
||||
0x65, 0x12, 0x35, 0x0a, 0x07, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03,
|
||||
0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d,
|
||||
0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52,
|
||||
0x07, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x73, 0x22, 0x30, 0x0a, 0x11, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a,
|
||||
0x09, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x08, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x6f,
|
||||
0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66,
|
||||
0x69, 0x67, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x03, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x46, 0x0a, 0x13, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12,
|
||||
0x17, 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x66,
|
||||
0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67,
|
||||
0x22, 0x32, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,
|
||||
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x67,
|
||||
0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x67,
|
||||
0x72, 0x65, 0x73, 0x73, 0x22, 0x2a, 0x0a, 0x13, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70,
|
||||
0x64, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x13, 0x0a, 0x05, 0x76,
|
||||
0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x76, 0x6d, 0x49, 0x64,
|
||||
0x22, 0x16, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65,
|
||||
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x0a, 0x13, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12,
|
||||
0x13, 0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
|
||||
0x76, 0x6d, 0x49, 0x64, 0x22, 0x16, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65,
|
||||
0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x57, 0x0a, 0x12,
|
||||
0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x12, 0x13, 0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||
0x0c, 0x52, 0x04, 0x76, 0x6d, 0x49, 0x64, 0x12, 0x2c, 0x0a, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f,
|
||||
0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x14, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72,
|
||||
0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x52, 0x06, 0x61,
|
||||
0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x15, 0x0a, 0x13, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50,
|
||||
0x6f, 0x77, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x3a, 0x0a, 0x23,
|
||||
0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61,
|
||||
0x70, 0x68, 0x69, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x12, 0x13, 0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x0c, 0x52, 0x04, 0x76, 0x6d, 0x49, 0x64, 0x22, 0x38, 0x0a, 0x24, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63,
|
||||
0x73, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
|
||||
0x12, 0x10, 0x0a, 0x03, 0x75, 0x72, 0x69, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75,
|
||||
0x72, 0x69, 0x2a, 0x70, 0x0a, 0x0b, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65,
|
||||
0x72, 0x12, 0x0d, 0x0a, 0x09, 0x55, 0x4e, 0x44, 0x45, 0x46, 0x49, 0x4e, 0x45, 0x44, 0x10, 0x00,
|
||||
0x12, 0x09, 0x0a, 0x05, 0x53, 0x54, 0x41, 0x52, 0x54, 0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06, 0x52,
|
||||
0x45, 0x42, 0x4f, 0x4f, 0x54, 0x10, 0x02, 0x12, 0x0c, 0x0a, 0x08, 0x53, 0x48, 0x55, 0x54, 0x44,
|
||||
0x4f, 0x57, 0x4e, 0x10, 0x03, 0x12, 0x09, 0x0a, 0x05, 0x50, 0x41, 0x55, 0x53, 0x45, 0x10, 0x04,
|
||||
0x12, 0x0a, 0x0a, 0x06, 0x52, 0x45, 0x53, 0x55, 0x4d, 0x45, 0x10, 0x05, 0x12, 0x09, 0x0a, 0x05,
|
||||
0x52, 0x45, 0x53, 0x45, 0x54, 0x10, 0x06, 0x12, 0x0b, 0x0a, 0x07, 0x44, 0x45, 0x53, 0x54, 0x52,
|
||||
0x4f, 0x59, 0x10, 0x07, 0x32, 0xb4, 0x03, 0x0a, 0x06, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x12,
|
||||
0x47, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1d, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72,
|
||||
0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74,
|
||||
0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65,
|
||||
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x40, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12,
|
||||
0x1a, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e,
|
||||
0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x64, 0x65,
|
||||
0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74,
|
||||
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x47, 0x0a, 0x06, 0x43, 0x72,
|
||||
0x65, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44,
|
||||
0x52, 0x08, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x22, 0x5f, 0x0a, 0x12, 0x44, 0x6f,
|
||||
0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
|
||||
0x12, 0x1b, 0x0a, 0x09, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x08, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x49, 0x64, 0x12, 0x16, 0x0a,
|
||||
0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63,
|
||||
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x03,
|
||||
0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x46, 0x0a, 0x13, 0x44,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d,
|
||||
0x61, 0x69, 0x6e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
|
||||
0x65, 0x22, 0x00, 0x12, 0x47, 0x0a, 0x06, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x2e,
|
||||
0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70,
|
||||
0x64, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x64, 0x65,
|
||||
0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70, 0x64, 0x61,
|
||||
0x73, 0x74, 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x63,
|
||||
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x6f, 0x6e,
|
||||
0x66, 0x69, 0x67, 0x22, 0x32, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x72, 0x65,
|
||||
0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70,
|
||||
0x72, 0x6f, 0x67, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x70,
|
||||
0x72, 0x6f, 0x67, 0x72, 0x65, 0x73, 0x73, 0x22, 0x2a, 0x0a, 0x13, 0x44, 0x6f, 0x6d, 0x61, 0x69,
|
||||
0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x13,
|
||||
0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x76,
|
||||
0x6d, 0x49, 0x64, 0x22, 0x16, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70, 0x64,
|
||||
0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x0a, 0x13, 0x44,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x12, 0x13, 0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x04, 0x76, 0x6d, 0x49, 0x64, 0x22, 0x16, 0x0a, 0x14, 0x44, 0x6f, 0x6d, 0x61, 0x69,
|
||||
0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22,
|
||||
0x57, 0x0a, 0x12, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x52, 0x65,
|
||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x13, 0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x76, 0x6d, 0x49, 0x64, 0x12, 0x2c, 0x0a, 0x06, 0x61, 0x63,
|
||||
0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x14, 0x2e, 0x64, 0x65, 0x65,
|
||||
0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72,
|
||||
0x52, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x15, 0x0a, 0x13, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22,
|
||||
0x3a, 0x0a, 0x23, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73,
|
||||
0x47, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x13, 0x0a, 0x05, 0x76, 0x6d, 0x5f, 0x69, 0x64, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x76, 0x6d, 0x49, 0x64, 0x22, 0x38, 0x0a, 0x24, 0x44,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61, 0x70,
|
||||
0x68, 0x69, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x72, 0x69, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x03, 0x75, 0x72, 0x69, 0x2a, 0x70, 0x0a, 0x0b, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50,
|
||||
0x6f, 0x77, 0x65, 0x72, 0x12, 0x0d, 0x0a, 0x09, 0x55, 0x4e, 0x44, 0x45, 0x46, 0x49, 0x4e, 0x45,
|
||||
0x44, 0x10, 0x00, 0x12, 0x09, 0x0a, 0x05, 0x53, 0x54, 0x41, 0x52, 0x54, 0x10, 0x01, 0x12, 0x0a,
|
||||
0x0a, 0x06, 0x52, 0x45, 0x42, 0x4f, 0x4f, 0x54, 0x10, 0x02, 0x12, 0x0c, 0x0a, 0x08, 0x53, 0x48,
|
||||
0x55, 0x54, 0x44, 0x4f, 0x57, 0x4e, 0x10, 0x03, 0x12, 0x09, 0x0a, 0x05, 0x50, 0x41, 0x55, 0x53,
|
||||
0x45, 0x10, 0x04, 0x12, 0x0a, 0x0a, 0x06, 0x52, 0x45, 0x53, 0x55, 0x4d, 0x45, 0x10, 0x05, 0x12,
|
||||
0x09, 0x0a, 0x05, 0x52, 0x45, 0x53, 0x45, 0x54, 0x10, 0x06, 0x12, 0x0b, 0x0a, 0x07, 0x44, 0x45,
|
||||
0x53, 0x54, 0x52, 0x4f, 0x59, 0x10, 0x07, 0x32, 0xfa, 0x03, 0x0a, 0x06, 0x44, 0x6f, 0x6d, 0x61,
|
||||
0x69, 0x6e, 0x12, 0x44, 0x0a, 0x05, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x12, 0x1b, 0x2e, 0x64, 0x65,
|
||||
0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x45, 0x76, 0x65, 0x6e,
|
||||
0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69,
|
||||
0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x52, 0x65,
|
||||
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x47, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74,
|
||||
0x12, 0x1d, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69,
|
||||
0x6e, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
|
||||
0x1e, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e,
|
||||
0x4c, 0x69, 0x73, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22,
|
||||
0x00, 0x12, 0x40, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x1a, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69,
|
||||
0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
|
||||
0x65, 0x22, 0x00, 0x12, 0x47, 0x0a, 0x06, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x2e,
|
||||
0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x72,
|
||||
0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x64, 0x65,
|
||||
0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x72, 0x65, 0x61,
|
||||
0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x47, 0x0a, 0x06,
|
||||
0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x1c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74,
|
||||
0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71,
|
||||
0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74,
|
||||
0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x05, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x12, 0x1b,
|
||||
0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50,
|
||||
0x6f, 0x77, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x64, 0x65,
|
||||
0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65,
|
||||
0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x32, 0x81, 0x01, 0x0a, 0x15,
|
||||
0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61,
|
||||
0x70, 0x68, 0x69, 0x63, 0x73, 0x12, 0x68, 0x0a, 0x07, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65,
|
||||
0x12, 0x2c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69,
|
||||
0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73,
|
||||
0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d,
|
||||
0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44,
|
||||
0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x43, 0x6f,
|
||||
0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42,
|
||||
0x09, 0x5a, 0x07, 0x2e, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x33,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x47, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12,
|
||||
0x1c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e,
|
||||
0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e,
|
||||
0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65,
|
||||
0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x44,
|
||||
0x0a, 0x05, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x12, 0x1b, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72,
|
||||
0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72, 0x74, 0x2e, 0x44,
|
||||
0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x50, 0x6f, 0x77, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
|
||||
0x73, 0x65, 0x22, 0x00, 0x32, 0x81, 0x01, 0x0a, 0x15, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44,
|
||||
0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x12, 0x68,
|
||||
0x0a, 0x07, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x12, 0x2c, 0x2e, 0x64, 0x65, 0x65, 0x76,
|
||||
0x69, 0x72, 0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65,
|
||||
0x73, 0x47, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65,
|
||||
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x64, 0x65, 0x65, 0x76, 0x69, 0x72,
|
||||
0x74, 0x2e, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x73, 0x47,
|
||||
0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x52, 0x65,
|
||||
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x09, 0x5a, 0x07, 0x2e, 0x2f, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
@ -849,43 +942,47 @@ func file_proto_domain_proto_rawDescGZIP() []byte {
|
||||
}
|
||||
|
||||
var file_proto_domain_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_proto_domain_proto_msgTypes = make([]protoimpl.MessageInfo, 14)
|
||||
var file_proto_domain_proto_msgTypes = make([]protoimpl.MessageInfo, 16)
|
||||
var file_proto_domain_proto_goTypes = []interface{}{
|
||||
(DomainPower)(0), // 0: deevirt.DomainPower
|
||||
(*DomainListAllRequest)(nil), // 1: deevirt.DomainListAllRequest
|
||||
(*DomainListAllResponse)(nil), // 2: deevirt.DomainListAllResponse
|
||||
(*DomainListRequest)(nil), // 3: deevirt.DomainListRequest
|
||||
(*DomainListResponse)(nil), // 4: deevirt.DomainListResponse
|
||||
(*DomainCreateRequest)(nil), // 5: deevirt.DomainCreateRequest
|
||||
(*DomainCreateResponse)(nil), // 6: deevirt.DomainCreateResponse
|
||||
(*DomainUpdateRequest)(nil), // 7: deevirt.DomainUpdateRequest
|
||||
(*DomainUpdateResponse)(nil), // 8: deevirt.DomainUpdateResponse
|
||||
(*DomainDeleteRequest)(nil), // 9: deevirt.DomainDeleteRequest
|
||||
(*DomainDeleteResponse)(nil), // 10: deevirt.DomainDeleteResponse
|
||||
(*DomainPowerRequest)(nil), // 11: deevirt.DomainPowerRequest
|
||||
(*DomainPowerResponse)(nil), // 12: deevirt.DomainPowerResponse
|
||||
(*DomainDevicesGraphicsConsoleRequest)(nil), // 13: deevirt.DomainDevicesGraphicsConsoleRequest
|
||||
(*DomainDevicesGraphicsConsoleResponse)(nil), // 14: deevirt.DomainDevicesGraphicsConsoleResponse
|
||||
(*DomainEventRequest)(nil), // 1: deevirt.DomainEventRequest
|
||||
(*DomainEventResponse)(nil), // 2: deevirt.DomainEventResponse
|
||||
(*DomainListAllRequest)(nil), // 3: deevirt.DomainListAllRequest
|
||||
(*DomainListAllResponse)(nil), // 4: deevirt.DomainListAllResponse
|
||||
(*DomainListRequest)(nil), // 5: deevirt.DomainListRequest
|
||||
(*DomainListResponse)(nil), // 6: deevirt.DomainListResponse
|
||||
(*DomainCreateRequest)(nil), // 7: deevirt.DomainCreateRequest
|
||||
(*DomainCreateResponse)(nil), // 8: deevirt.DomainCreateResponse
|
||||
(*DomainUpdateRequest)(nil), // 9: deevirt.DomainUpdateRequest
|
||||
(*DomainUpdateResponse)(nil), // 10: deevirt.DomainUpdateResponse
|
||||
(*DomainDeleteRequest)(nil), // 11: deevirt.DomainDeleteRequest
|
||||
(*DomainDeleteResponse)(nil), // 12: deevirt.DomainDeleteResponse
|
||||
(*DomainPowerRequest)(nil), // 13: deevirt.DomainPowerRequest
|
||||
(*DomainPowerResponse)(nil), // 14: deevirt.DomainPowerResponse
|
||||
(*DomainDevicesGraphicsConsoleRequest)(nil), // 15: deevirt.DomainDevicesGraphicsConsoleRequest
|
||||
(*DomainDevicesGraphicsConsoleResponse)(nil), // 16: deevirt.DomainDevicesGraphicsConsoleResponse
|
||||
}
|
||||
var file_proto_domain_proto_depIdxs = []int32{
|
||||
4, // 0: deevirt.DomainListAllResponse.domains:type_name -> deevirt.DomainListResponse
|
||||
6, // 0: deevirt.DomainListAllResponse.domains:type_name -> deevirt.DomainListResponse
|
||||
0, // 1: deevirt.DomainPowerRequest.action:type_name -> deevirt.DomainPower
|
||||
1, // 2: deevirt.Domain.List:input_type -> deevirt.DomainListAllRequest
|
||||
3, // 3: deevirt.Domain.Get:input_type -> deevirt.DomainListRequest
|
||||
5, // 4: deevirt.Domain.Create:input_type -> deevirt.DomainCreateRequest
|
||||
7, // 5: deevirt.Domain.Update:input_type -> deevirt.DomainUpdateRequest
|
||||
9, // 6: deevirt.Domain.Delete:input_type -> deevirt.DomainDeleteRequest
|
||||
11, // 7: deevirt.Domain.Power:input_type -> deevirt.DomainPowerRequest
|
||||
13, // 8: deevirt.DomainDevicesGraphics.Console:input_type -> deevirt.DomainDevicesGraphicsConsoleRequest
|
||||
2, // 9: deevirt.Domain.List:output_type -> deevirt.DomainListAllResponse
|
||||
4, // 10: deevirt.Domain.Get:output_type -> deevirt.DomainListResponse
|
||||
6, // 11: deevirt.Domain.Create:output_type -> deevirt.DomainCreateResponse
|
||||
8, // 12: deevirt.Domain.Update:output_type -> deevirt.DomainUpdateResponse
|
||||
10, // 13: deevirt.Domain.Delete:output_type -> deevirt.DomainDeleteResponse
|
||||
12, // 14: deevirt.Domain.Power:output_type -> deevirt.DomainPowerResponse
|
||||
14, // 15: deevirt.DomainDevicesGraphics.Console:output_type -> deevirt.DomainDevicesGraphicsConsoleResponse
|
||||
9, // [9:16] is the sub-list for method output_type
|
||||
2, // [2:9] is the sub-list for method input_type
|
||||
1, // 2: deevirt.Domain.Event:input_type -> deevirt.DomainEventRequest
|
||||
3, // 3: deevirt.Domain.List:input_type -> deevirt.DomainListAllRequest
|
||||
5, // 4: deevirt.Domain.Get:input_type -> deevirt.DomainListRequest
|
||||
7, // 5: deevirt.Domain.Create:input_type -> deevirt.DomainCreateRequest
|
||||
9, // 6: deevirt.Domain.Update:input_type -> deevirt.DomainUpdateRequest
|
||||
11, // 7: deevirt.Domain.Delete:input_type -> deevirt.DomainDeleteRequest
|
||||
13, // 8: deevirt.Domain.Power:input_type -> deevirt.DomainPowerRequest
|
||||
15, // 9: deevirt.DomainDevicesGraphics.Console:input_type -> deevirt.DomainDevicesGraphicsConsoleRequest
|
||||
2, // 10: deevirt.Domain.Event:output_type -> deevirt.DomainEventResponse
|
||||
4, // 11: deevirt.Domain.List:output_type -> deevirt.DomainListAllResponse
|
||||
6, // 12: deevirt.Domain.Get:output_type -> deevirt.DomainListResponse
|
||||
8, // 13: deevirt.Domain.Create:output_type -> deevirt.DomainCreateResponse
|
||||
10, // 14: deevirt.Domain.Update:output_type -> deevirt.DomainUpdateResponse
|
||||
12, // 15: deevirt.Domain.Delete:output_type -> deevirt.DomainDeleteResponse
|
||||
14, // 16: deevirt.Domain.Power:output_type -> deevirt.DomainPowerResponse
|
||||
16, // 17: deevirt.DomainDevicesGraphics.Console:output_type -> deevirt.DomainDevicesGraphicsConsoleResponse
|
||||
10, // [10:18] is the sub-list for method output_type
|
||||
2, // [2:10] is the sub-list for method input_type
|
||||
2, // [2:2] is the sub-list for extension type_name
|
||||
2, // [2:2] is the sub-list for extension extendee
|
||||
0, // [0:2] is the sub-list for field type_name
|
||||
@ -898,7 +995,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_proto_domain_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainListAllRequest); i {
|
||||
switch v := v.(*DomainEventRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -910,7 +1007,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainListAllResponse); i {
|
||||
switch v := v.(*DomainEventResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -922,7 +1019,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainListRequest); i {
|
||||
switch v := v.(*DomainListAllRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -934,7 +1031,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainListResponse); i {
|
||||
switch v := v.(*DomainListAllResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -946,7 +1043,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainCreateRequest); i {
|
||||
switch v := v.(*DomainListRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -958,7 +1055,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainCreateResponse); i {
|
||||
switch v := v.(*DomainListResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -970,7 +1067,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainUpdateRequest); i {
|
||||
switch v := v.(*DomainCreateRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -982,7 +1079,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainUpdateResponse); i {
|
||||
switch v := v.(*DomainCreateResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -994,7 +1091,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainDeleteRequest); i {
|
||||
switch v := v.(*DomainUpdateRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -1006,7 +1103,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainDeleteResponse); i {
|
||||
switch v := v.(*DomainUpdateResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -1018,7 +1115,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainPowerRequest); i {
|
||||
switch v := v.(*DomainDeleteRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -1030,7 +1127,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainPowerResponse); i {
|
||||
switch v := v.(*DomainDeleteResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -1042,7 +1139,7 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainDevicesGraphicsConsoleRequest); i {
|
||||
switch v := v.(*DomainPowerRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -1054,6 +1151,30 @@ func file_proto_domain_proto_init() {
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainPowerResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainDevicesGraphicsConsoleRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_proto_domain_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DomainDevicesGraphicsConsoleResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -1072,7 +1193,7 @@ func file_proto_domain_proto_init() {
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_proto_domain_proto_rawDesc,
|
||||
NumEnums: 1,
|
||||
NumMessages: 14,
|
||||
NumMessages: 16,
|
||||
NumExtensions: 0,
|
||||
NumServices: 2,
|
||||
},
|
||||
|
@ -5,6 +5,8 @@ package deevirt;
|
||||
|
||||
// The greeting service definition.
|
||||
service Domain {
|
||||
rpc Event (DomainEventRequest) returns (DomainEventResponse) {}
|
||||
|
||||
rpc List (DomainListAllRequest) returns (DomainListAllResponse) {}
|
||||
rpc Get (DomainListRequest) returns (DomainListResponse) {}
|
||||
rpc Create (DomainCreateRequest) returns (DomainCreateResponse) {}
|
||||
@ -15,6 +17,12 @@ service Domain {
|
||||
|
||||
}
|
||||
|
||||
message DomainEventRequest {
|
||||
bytes event = 1;
|
||||
}
|
||||
|
||||
message DomainEventResponse {}
|
||||
|
||||
message DomainListAllRequest {}
|
||||
|
||||
message DomainListAllResponse {
|
||||
|
@ -19,6 +19,7 @@ import (
|
||||
const _ = grpc.SupportPackageIsVersion9
|
||||
|
||||
const (
|
||||
Domain_Event_FullMethodName = "/deevirt.Domain/Event"
|
||||
Domain_List_FullMethodName = "/deevirt.Domain/List"
|
||||
Domain_Get_FullMethodName = "/deevirt.Domain/Get"
|
||||
Domain_Create_FullMethodName = "/deevirt.Domain/Create"
|
||||
@ -33,6 +34,7 @@ const (
|
||||
//
|
||||
// The greeting service definition.
|
||||
type DomainClient interface {
|
||||
Event(ctx context.Context, in *DomainEventRequest, opts ...grpc.CallOption) (*DomainEventResponse, error)
|
||||
List(ctx context.Context, in *DomainListAllRequest, opts ...grpc.CallOption) (*DomainListAllResponse, error)
|
||||
Get(ctx context.Context, in *DomainListRequest, opts ...grpc.CallOption) (*DomainListResponse, error)
|
||||
Create(ctx context.Context, in *DomainCreateRequest, opts ...grpc.CallOption) (*DomainCreateResponse, error)
|
||||
@ -49,6 +51,16 @@ func NewDomainClient(cc grpc.ClientConnInterface) DomainClient {
|
||||
return &domainClient{cc}
|
||||
}
|
||||
|
||||
func (c *domainClient) Event(ctx context.Context, in *DomainEventRequest, opts ...grpc.CallOption) (*DomainEventResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(DomainEventResponse)
|
||||
err := c.cc.Invoke(ctx, Domain_Event_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *domainClient) List(ctx context.Context, in *DomainListAllRequest, opts ...grpc.CallOption) (*DomainListAllResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(DomainListAllResponse)
|
||||
@ -115,6 +127,7 @@ func (c *domainClient) Power(ctx context.Context, in *DomainPowerRequest, opts .
|
||||
//
|
||||
// The greeting service definition.
|
||||
type DomainServer interface {
|
||||
Event(context.Context, *DomainEventRequest) (*DomainEventResponse, error)
|
||||
List(context.Context, *DomainListAllRequest) (*DomainListAllResponse, error)
|
||||
Get(context.Context, *DomainListRequest) (*DomainListResponse, error)
|
||||
Create(context.Context, *DomainCreateRequest) (*DomainCreateResponse, error)
|
||||
@ -131,6 +144,9 @@ type DomainServer interface {
|
||||
// pointer dereference when methods are called.
|
||||
type UnimplementedDomainServer struct{}
|
||||
|
||||
func (UnimplementedDomainServer) Event(context.Context, *DomainEventRequest) (*DomainEventResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method Event not implemented")
|
||||
}
|
||||
func (UnimplementedDomainServer) List(context.Context, *DomainListAllRequest) (*DomainListAllResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method List not implemented")
|
||||
}
|
||||
@ -170,6 +186,24 @@ func RegisterDomainServer(s grpc.ServiceRegistrar, srv DomainServer) {
|
||||
s.RegisterService(&Domain_ServiceDesc, srv)
|
||||
}
|
||||
|
||||
func _Domain_Event_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(DomainEventRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(DomainServer).Event(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: Domain_Event_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(DomainServer).Event(ctx, req.(*DomainEventRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Domain_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(DomainListAllRequest)
|
||||
if err := dec(in); err != nil {
|
||||
@ -285,6 +319,10 @@ var Domain_ServiceDesc = grpc.ServiceDesc{
|
||||
ServiceName: "deevirt.Domain",
|
||||
HandlerType: (*DomainServer)(nil),
|
||||
Methods: []grpc.MethodDesc{
|
||||
{
|
||||
MethodName: "Event",
|
||||
Handler: _Domain_Event_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "List",
|
||||
Handler: _Domain_List_Handler,
|
||||
|
84
vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify.go
generated
vendored
Normal file
84
vendor/github.com/coreos/go-systemd/v22/daemon/sdnotify.go
generated
vendored
Normal file
@ -0,0 +1,84 @@
|
||||
// Copyright 2014 Docker, Inc.
|
||||
// Copyright 2015-2018 CoreOS, Inc.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
// Package daemon provides a Go implementation of the sd_notify protocol.
|
||||
// It can be used to inform systemd of service start-up completion, watchdog
|
||||
// events, and other status changes.
|
||||
//
|
||||
// https://www.freedesktop.org/software/systemd/man/sd_notify.html#Description
|
||||
package daemon
|
||||
|
||||
import (
|
||||
"net"
|
||||
"os"
|
||||
)
|
||||
|
||||
const (
|
||||
// SdNotifyReady tells the service manager that service startup is finished
|
||||
// or the service finished loading its configuration.
|
||||
SdNotifyReady = "READY=1"
|
||||
|
||||
// SdNotifyStopping tells the service manager that the service is beginning
|
||||
// its shutdown.
|
||||
SdNotifyStopping = "STOPPING=1"
|
||||
|
||||
// SdNotifyReloading tells the service manager that this service is
|
||||
// reloading its configuration. Note that you must call SdNotifyReady when
|
||||
// it completed reloading.
|
||||
SdNotifyReloading = "RELOADING=1"
|
||||
|
||||
// SdNotifyWatchdog tells the service manager to update the watchdog
|
||||
// timestamp for the service.
|
||||
SdNotifyWatchdog = "WATCHDOG=1"
|
||||
)
|
||||
|
||||
// SdNotify sends a message to the init daemon. It is common to ignore the error.
|
||||
// If `unsetEnvironment` is true, the environment variable `NOTIFY_SOCKET`
|
||||
// will be unconditionally unset.
|
||||
//
|
||||
// It returns one of the following:
|
||||
// (false, nil) - notification not supported (i.e. NOTIFY_SOCKET is unset)
|
||||
// (false, err) - notification supported, but failure happened (e.g. error connecting to NOTIFY_SOCKET or while sending data)
|
||||
// (true, nil) - notification supported, data has been sent
|
||||
func SdNotify(unsetEnvironment bool, state string) (bool, error) {
|
||||
socketAddr := &net.UnixAddr{
|
||||
Name: os.Getenv("NOTIFY_SOCKET"),
|
||||
Net: "unixgram",
|
||||
}
|
||||
|
||||
// NOTIFY_SOCKET not set
|
||||
if socketAddr.Name == "" {
|
||||
return false, nil
|
||||
}
|
||||
|
||||
if unsetEnvironment {
|
||||
if err := os.Unsetenv("NOTIFY_SOCKET"); err != nil {
|
||||
return false, err
|
||||
}
|
||||
}
|
||||
|
||||
conn, err := net.DialUnix(socketAddr.Net, nil, socketAddr)
|
||||
// Error connecting to NOTIFY_SOCKET
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
defer conn.Close()
|
||||
|
||||
if _, err = conn.Write([]byte(state)); err != nil {
|
||||
return false, err
|
||||
}
|
||||
return true, nil
|
||||
}
|
73
vendor/github.com/coreos/go-systemd/v22/daemon/watchdog.go
generated
vendored
Normal file
73
vendor/github.com/coreos/go-systemd/v22/daemon/watchdog.go
generated
vendored
Normal file
@ -0,0 +1,73 @@
|
||||
// Copyright 2016 CoreOS, Inc.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package daemon
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
"strconv"
|
||||
"time"
|
||||
)
|
||||
|
||||
// SdWatchdogEnabled returns watchdog information for a service.
|
||||
// Processes should call daemon.SdNotify(false, daemon.SdNotifyWatchdog) every
|
||||
// time / 2.
|
||||
// If `unsetEnvironment` is true, the environment variables `WATCHDOG_USEC` and
|
||||
// `WATCHDOG_PID` will be unconditionally unset.
|
||||
//
|
||||
// It returns one of the following:
|
||||
// (0, nil) - watchdog isn't enabled or we aren't the watched PID.
|
||||
// (0, err) - an error happened (e.g. error converting time).
|
||||
// (time, nil) - watchdog is enabled and we can send ping. time is delay
|
||||
// before inactive service will be killed.
|
||||
func SdWatchdogEnabled(unsetEnvironment bool) (time.Duration, error) {
|
||||
wusec := os.Getenv("WATCHDOG_USEC")
|
||||
wpid := os.Getenv("WATCHDOG_PID")
|
||||
if unsetEnvironment {
|
||||
wusecErr := os.Unsetenv("WATCHDOG_USEC")
|
||||
wpidErr := os.Unsetenv("WATCHDOG_PID")
|
||||
if wusecErr != nil {
|
||||
return 0, wusecErr
|
||||
}
|
||||
if wpidErr != nil {
|
||||
return 0, wpidErr
|
||||
}
|
||||
}
|
||||
|
||||
if wusec == "" {
|
||||
return 0, nil
|
||||
}
|
||||
s, err := strconv.Atoi(wusec)
|
||||
if err != nil {
|
||||
return 0, fmt.Errorf("error converting WATCHDOG_USEC: %s", err)
|
||||
}
|
||||
if s <= 0 {
|
||||
return 0, fmt.Errorf("error WATCHDOG_USEC must be a positive number")
|
||||
}
|
||||
interval := time.Duration(s) * time.Microsecond
|
||||
|
||||
if wpid == "" {
|
||||
return interval, nil
|
||||
}
|
||||
p, err := strconv.Atoi(wpid)
|
||||
if err != nil {
|
||||
return 0, fmt.Errorf("error converting WATCHDOG_PID: %s", err)
|
||||
}
|
||||
if os.Getpid() != p {
|
||||
return 0, nil
|
||||
}
|
||||
|
||||
return interval, nil
|
||||
}
|
15
vendor/modules.txt
vendored
15
vendor/modules.txt
vendored
@ -15,6 +15,7 @@ github.com/cespare/xxhash/v2
|
||||
github.com/coreos/go-semver/semver
|
||||
# github.com/coreos/go-systemd/v22 v22.5.0
|
||||
## explicit; go 1.12
|
||||
github.com/coreos/go-systemd/v22/daemon
|
||||
github.com/coreos/go-systemd/v22/journal
|
||||
# github.com/denisbrodbeck/machineid v1.0.1
|
||||
## explicit
|
||||
@ -30,10 +31,6 @@ github.com/gogo/protobuf/protoc-gen-gogo/descriptor
|
||||
# github.com/golang/protobuf v1.5.4
|
||||
## explicit; go 1.17
|
||||
github.com/golang/protobuf/proto
|
||||
# github.com/google/licensecheck v0.3.1
|
||||
## explicit; go 1.12
|
||||
# github.com/google/safehtml v0.0.3-0.20211026203422-d6f0e11a5516
|
||||
## explicit; go 1.14
|
||||
# github.com/hashicorp/errwrap v1.1.0
|
||||
## explicit
|
||||
github.com/hashicorp/errwrap
|
||||
@ -157,8 +154,6 @@ go.uber.org/zap/internal/pool
|
||||
go.uber.org/zap/internal/stacktrace
|
||||
go.uber.org/zap/zapcore
|
||||
go.uber.org/zap/zapgrpc
|
||||
# golang.org/x/mod v0.23.0
|
||||
## explicit; go 1.22.0
|
||||
# golang.org/x/net v0.35.0
|
||||
## explicit; go 1.18
|
||||
golang.org/x/net/http/httpguts
|
||||
@ -168,9 +163,7 @@ golang.org/x/net/idna
|
||||
golang.org/x/net/internal/httpcommon
|
||||
golang.org/x/net/internal/timeseries
|
||||
golang.org/x/net/trace
|
||||
# golang.org/x/pkgsite v0.0.0-20250214205047-dd488e5da97a
|
||||
## explicit; go 1.23
|
||||
# golang.org/x/sync v0.11.0
|
||||
# golang.org/x/oauth2 v0.26.0
|
||||
## explicit; go 1.18
|
||||
# golang.org/x/sys v0.30.0
|
||||
## explicit; go 1.18
|
||||
@ -183,8 +176,6 @@ golang.org/x/text/secure/bidirule
|
||||
golang.org/x/text/transform
|
||||
golang.org/x/text/unicode/bidi
|
||||
golang.org/x/text/unicode/norm
|
||||
# golang.org/x/tools v0.30.0
|
||||
## explicit; go 1.22.0
|
||||
# google.golang.org/genproto/googleapis/api v0.0.0-20250207221924-e9438ea467c6
|
||||
## explicit; go 1.22
|
||||
google.golang.org/genproto/googleapis/api
|
||||
@ -302,5 +293,3 @@ gopkg.in/ini.v1
|
||||
# libvirt.org/go/libvirt v1.11001.0
|
||||
## explicit; go 1.11
|
||||
libvirt.org/go/libvirt
|
||||
# rsc.io/markdown v0.0.0-20231214224604-88bb533a6020
|
||||
## explicit; go 1.20
|
||||
|
Loading…
x
Reference in New Issue
Block a user