Removed pkg/discovery
It moves discovery types to discovery/ on root.
This commit is contained in:
@@ -6,14 +6,13 @@ import (
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
"github.com/cortezaproject/corteza/server/pkg/dal"
|
||||
"github.com/cortezaproject/corteza/server/pkg/discovery"
|
||||
|
||||
automationService "github.com/cortezaproject/corteza/server/automation/service"
|
||||
"github.com/cortezaproject/corteza/server/compose/automation"
|
||||
"github.com/cortezaproject/corteza/server/compose/types"
|
||||
discoveryService "github.com/cortezaproject/corteza/server/discovery/service"
|
||||
"github.com/cortezaproject/corteza/server/pkg/actionlog"
|
||||
"github.com/cortezaproject/corteza/server/pkg/corredor"
|
||||
"github.com/cortezaproject/corteza/server/pkg/dal"
|
||||
"github.com/cortezaproject/corteza/server/pkg/eventbus"
|
||||
"github.com/cortezaproject/corteza/server/pkg/filter"
|
||||
"github.com/cortezaproject/corteza/server/pkg/healthcheck"
|
||||
@@ -122,8 +121,8 @@ func Initialize(ctx context.Context, log *zap.Logger, s store.Storer, c Config)
|
||||
l = zap.NewNop()
|
||||
}
|
||||
|
||||
DefaultResourceActivityLog := discovery.Service(l, c.Discovery, DefaultStore, eventbus.Service())
|
||||
err = DefaultResourceActivityLog.InitResourceActivityLog(ctx, []string{
|
||||
DefaultResourceActivity := discoveryService.ResourceActivity(l, c.Discovery, DefaultStore, eventbus.Service())
|
||||
err = DefaultResourceActivity.InitResourceActivityLog(ctx, []string{
|
||||
(types.Namespace{}).LabelResourceKind(),
|
||||
(types.Module{}).LabelResourceKind(),
|
||||
"compose:record",
|
||||
|
||||
@@ -5,8 +5,6 @@ import (
|
||||
"encoding/json"
|
||||
"time"
|
||||
|
||||
discovery "github.com/cortezaproject/corteza/server/discovery/types"
|
||||
|
||||
"github.com/cortezaproject/corteza/server/pkg/sql"
|
||||
"github.com/jmoiron/sqlx/types"
|
||||
|
||||
@@ -55,8 +53,7 @@ type (
|
||||
// Record data privacy settings
|
||||
Privacy ModuleConfigDataPrivacy `json:"privacy"`
|
||||
|
||||
// @todo we need to transfer this from meta!!
|
||||
Discovery discovery.ModuleMeta `json:"discovery"`
|
||||
Discovery ModuleConfigDiscovery `json:"discovery"`
|
||||
|
||||
RecordRevisions ModuleConfigRecordRevisions `json:"recordRevisions"`
|
||||
|
||||
@@ -101,6 +98,19 @@ type (
|
||||
Rules DeDupRuleSet `json:"rules,omitempty"`
|
||||
}
|
||||
|
||||
ModuleConfigDiscovery struct {
|
||||
Public DiscoveryResult `json:"public"`
|
||||
Private DiscoveryResult `json:"private"`
|
||||
Protected DiscoveryResult `json:"protected"`
|
||||
}
|
||||
|
||||
DiscoveryResult struct {
|
||||
Result []struct {
|
||||
Lang string `json:"lang"`
|
||||
Fields []string `json:"fields"`
|
||||
} `json:"result"`
|
||||
}
|
||||
|
||||
ModuleFilter struct {
|
||||
ModuleID []uint64 `json:"moduleID"`
|
||||
NamespaceID uint64 `json:"namespaceID,string"`
|
||||
|
||||
@@ -4,7 +4,6 @@ import (
|
||||
"database/sql/driver"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
discovery "github.com/cortezaproject/corteza/server/discovery/types"
|
||||
"github.com/cortezaproject/corteza/server/pkg/sql"
|
||||
"github.com/spf13/cast"
|
||||
"strconv"
|
||||
@@ -14,9 +13,6 @@ type (
|
||||
ModuleFieldOptions map[string]interface{}
|
||||
|
||||
ModuleFieldOptionIndex struct {
|
||||
// index values in this field for public, protected or private searches
|
||||
Access discovery.Access `json:"access"`
|
||||
|
||||
// Applicable to ref field kinds where we use nested/object type
|
||||
// and we want to control how deep do we want to follow the references
|
||||
NestingDepth map[string]bool `json:"nestingDepth,omitempty"`
|
||||
|
||||
Reference in New Issue
Block a user