Skip to content

Commit d051f4c

Browse files
committed
feat(backend): refactor
1 parent c79914d commit d051f4c

File tree

10 files changed

+403
-53
lines changed

10 files changed

+403
-53
lines changed

backend/modules/observability/application/mocks/trace_application.go

Lines changed: 342 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

backend/modules/observability/application/trace.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ const (
4444
QueryLimitDefault = 100
4545
)
4646

47+
//go:generate mockgen -destination=mocks/trace_application.go -package=mocks . ITraceApplication
4748
type ITraceApplication interface {
4849
trace.TraceService
4950
GetDisplayInfo(context.Context, *GetDisplayInfoRequest) GetDisplayInfoResponse

backend/modules/observability/domain/component/config/config.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ type PlatformTenantsCfg struct {
2323
}
2424

2525
type SpanTransHandlerConfig struct {
26-
PlatformCfg map[string]loop_span.SpanTransCfgList `mapstructure:"platform_cfg" json:"platform_cfg"`
26+
BasicConfig map[string]loop_span.SpanTransCfgList `mapstructure:"basic_config" json:"basic_config"`
27+
PlatformCfg map[string]loop_span.SpanTransCfgList `mapstructure:"platform_cfg" json:"platform_cfg"`
28+
PlatformInheritance map[string][]string `mapstructure:"platform_basic" json:"platform_basic"`
2729
}
2830

2931
type IngestConfig struct {
@@ -116,7 +118,7 @@ type ConsumerListening struct {
116118
type ITraceConfig interface {
117119
GetSystemViews(ctx context.Context) ([]*SystemView, error)
118120
GetPlatformTenants(ctx context.Context) (*PlatformTenantsCfg, error)
119-
GetPlatformSpansTrans(ctx context.Context) (*SpanTransHandlerConfig, error)
121+
GetPlatformSpansTrans(ctx context.Context, platformType loop_span.PlatformType) (loop_span.SpanTransCfgList, error)
120122
GetTraceIngestTenantProducerCfg(ctx context.Context) (map[string]*IngestConfig, error)
121123
GetAnnotationMqProducerCfg(ctx context.Context) (*MqProducerCfg, error)
122124
GetTraceCkCfg(ctx context.Context) (*TraceCKCfg, error)

0 commit comments

Comments
 (0)