This commit is contained in:
crusader 2018-04-26 17:43:40 +09:00
parent 9133090b72
commit 14a9b28ed2
6 changed files with 19 additions and 1 deletions

View File

@ -5,6 +5,9 @@ import (
cda "git.loafle.net/commons/di-go/annotation" cda "git.loafle.net/commons/di-go/annotation"
cdr "git.loafle.net/commons/di-go/registry" cdr "git.loafle.net/commons/di-go/registry"
ocsp "git.loafle.net/overflow/commons-go/service/probe"
// For annotation
_ "git.loafle.net/overflow/commons-go/core/annotation" _ "git.loafle.net/overflow/commons-go/core/annotation"
) )
@ -15,6 +18,7 @@ func init() {
} }
type CollectorService struct { type CollectorService struct {
ocsp.CollectorService
cda.TypeAnnotation `annotation:"@overflow:RPCService()"` cda.TypeAnnotation `annotation:"@overflow:RPCService()"`
DataClientService *DataClientService `annotation:"@Inject()"` DataClientService *DataClientService `annotation:"@Inject()"`

View File

@ -16,6 +16,7 @@ import (
crc "git.loafle.net/commons/rpc-go/client" crc "git.loafle.net/commons/rpc-go/client"
csc "git.loafle.net/commons/server-go/client" csc "git.loafle.net/commons/server-go/client"
occp "git.loafle.net/overflow/commons-go/config/probe" occp "git.loafle.net/overflow/commons-go/config/probe"
ocsp "git.loafle.net/overflow/commons-go/service/probe"
"git.loafle.net/overflow/probe/client/container" "git.loafle.net/overflow/probe/client/container"
"git.loafle.net/overflow/probe/config" "git.loafle.net/overflow/probe/config"
@ -30,6 +31,7 @@ func init() {
} }
type ContainerService struct { type ContainerService struct {
ocsp.ContainerService
cda.TypeAnnotation `annotation:"@overflow:RPCService()"` cda.TypeAnnotation `annotation:"@overflow:RPCService()"`
DiscoveryService *DiscoveryService `annotation:"@Inject()"` DiscoveryService *DiscoveryService `annotation:"@Inject()"`

View File

@ -5,6 +5,9 @@ import (
cda "git.loafle.net/commons/di-go/annotation" cda "git.loafle.net/commons/di-go/annotation"
cdr "git.loafle.net/commons/di-go/registry" cdr "git.loafle.net/commons/di-go/registry"
ocsp "git.loafle.net/overflow/commons-go/service/probe"
// For annotation
_ "git.loafle.net/overflow/commons-go/core/annotation" _ "git.loafle.net/overflow/commons-go/core/annotation"
) )
@ -15,6 +18,7 @@ func init() {
} }
type CrawlerService struct { type CrawlerService struct {
ocsp.CrawlerService
cda.TypeAnnotation `annotation:"@overflow:RPCService()"` cda.TypeAnnotation `annotation:"@overflow:RPCService()"`
} }

View File

@ -5,8 +5,11 @@ import (
cda "git.loafle.net/commons/di-go/annotation" cda "git.loafle.net/commons/di-go/annotation"
cdr "git.loafle.net/commons/di-go/registry" cdr "git.loafle.net/commons/di-go/registry"
_ "git.loafle.net/overflow/commons-go/core/annotation" ocsp "git.loafle.net/overflow/commons-go/service/probe"
"git.loafle.net/overflow/probe/client/central" "git.loafle.net/overflow/probe/client/central"
// For annotation
_ "git.loafle.net/overflow/commons-go/core/annotation"
) )
var DataClientServiceType = reflect.TypeOf((*DataClientService)(nil)) var DataClientServiceType = reflect.TypeOf((*DataClientService)(nil))
@ -16,6 +19,7 @@ func init() {
} }
type DataClientService struct { type DataClientService struct {
ocsp.DataClientService
RPCClientService RPCClientService
cda.TypeAnnotation `annotation:"@overflow:RPCService()"` cda.TypeAnnotation `annotation:"@overflow:RPCService()"`

View File

@ -8,6 +8,7 @@ import (
cdr "git.loafle.net/commons/di-go/registry" cdr "git.loafle.net/commons/di-go/registry"
occp "git.loafle.net/overflow/commons-go/config/probe" occp "git.loafle.net/overflow/commons-go/config/probe"
ocmd "git.loafle.net/overflow/commons-go/model/discovery" ocmd "git.loafle.net/overflow/commons-go/model/discovery"
ocsp "git.loafle.net/overflow/commons-go/service/probe"
// For annotation // For annotation
_ "git.loafle.net/overflow/commons-go/core/annotation" _ "git.loafle.net/overflow/commons-go/core/annotation"
@ -20,6 +21,7 @@ func init() {
} }
type DiscoveryService struct { type DiscoveryService struct {
ocsp.DiscoveryService
cda.TypeAnnotation `annotation:"@overflow:RPCService()"` cda.TypeAnnotation `annotation:"@overflow:RPCService()"`
ContainerService *ContainerService `annotation:"@Inject()"` ContainerService *ContainerService `annotation:"@Inject()"`

View File

@ -11,6 +11,7 @@ import (
cda "git.loafle.net/commons/di-go/annotation" cda "git.loafle.net/commons/di-go/annotation"
cdr "git.loafle.net/commons/di-go/registry" cdr "git.loafle.net/commons/di-go/registry"
ocmsc "git.loafle.net/overflow/commons-go/model/sensorconfig" ocmsc "git.loafle.net/overflow/commons-go/model/sensorconfig"
ocsp "git.loafle.net/overflow/commons-go/service/probe"
"git.loafle.net/overflow/probe/config" "git.loafle.net/overflow/probe/config"
// For annotation // For annotation
@ -24,6 +25,7 @@ func init() {
} }
type SensorConfigService struct { type SensorConfigService struct {
ocsp.SensorConfigService
cda.TypeAnnotation `annotation:"@overflow:RPCService()"` cda.TypeAnnotation `annotation:"@overflow:RPCService()"`
sensorConfigs map[string]*ocmsc.SensorConfig sensorConfigs map[string]*ocmsc.SensorConfig