Documentation
¶
Index ¶
- func SerializeUploadUnit(u interface{}) ([]byte, error)
- type BindingConfigPart
- type DriverType
- type ExecuteConfig
- type FunctionContextUploadUnit
- type FunctionUploadUnit
- type FunctionWithSignature
- type QueueConfigPart
- type QueueType
- type ServerConfigPart
- type ServerType
- type WorkerConfigPart
- type WorkspaceConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SerializeUploadUnit ¶
Types ¶
type BindingConfigPart ¶ added in v0.9.0
type BindingConfigPart struct {
// binding
DbType DriverType `mapstructure:"dbType"`
Neo4jUri string `mapstructure:"neo4JUri"`
Neo4jUserName string `mapstructure:"neo4JUserName"`
Neo4jPassword string `mapstructure:"neo4JPassword"`
BadgerPath string `mapstructure:"badgerPath"`
TikvAddrs string `mapstructure:"tikvAddrs"`
}
type DriverType ¶
type DriverType = string
const ( DtNeo4j DriverType = "NEO4J" DtInMemory DriverType = "INMEM" DtBadger DriverType = "BADGER" DtTikv DriverType = "TIKV" FlagWcKeySplit = "|,,|" )
type ExecuteConfig ¶
type ExecuteConfig struct {
*ServerConfigPart `mapstructure:"server"`
*BindingConfigPart `mapstructure:"binding"`
*WorkerConfigPart `mapstructure:"worker"`
*QueueConfigPart `mapstructure:"queue"`
}
func DefaultExecuteConfig ¶
func DefaultExecuteConfig() ExecuteConfig
func (*ExecuteConfig) ToJson ¶ added in v0.8.0
func (config *ExecuteConfig) ToJson() (string, error)
type FunctionContextUploadUnit ¶
type FunctionContextUploadUnit struct {
WorkspaceConfig *WorkspaceConfig `json:"workspace"`
FunctionContexts []*sibyl2.FunctionContext `json:"functionContext"`
}
func DeserializeFuncCtxUploadUnit ¶
func DeserializeFuncCtxUploadUnit(data []byte) (*FunctionContextUploadUnit, error)
type FunctionUploadUnit ¶
type FunctionUploadUnit struct {
WorkspaceConfig *WorkspaceConfig `json:"workspace"`
FunctionResult *extractor.FunctionFileResult `json:"funcResult"`
}
func DeserializeFuncUploadUnit ¶
func DeserializeFuncUploadUnit(data []byte) (*FunctionUploadUnit, error)
type FunctionWithSignature ¶
type FunctionWithSignature struct {
*sibyl2.FunctionWithPath
Signature string `json:"signature"`
}
type QueueConfigPart ¶ added in v0.9.0
type QueueConfigPart struct {
// queue
QueueType QueueType `mapstructure:"queueType"`
KafkaAddrs string `mapstructure:"kafkaAddrs"`
KafkaFuncTopic string `mapstructure:"kafkaFuncTopic"`
KafkaFuncConsumerGroup string `mapstructure:"kafkaFuncConsumerGroup"`
KafkaFuncCtxTopic string `mapstructure:"kafkaFuncCtxTopic"`
KafkaFuncCtxConsumerGroup string `mapstructure:"kafkaFuncCtxConsumerGroup"`
}
type QueueType ¶
type QueueType = string
const QueueTypeKafka QueueType = "KAFKA"
const QueueTypeMemory QueueType = "MEMORY"
type ServerConfigPart ¶ added in v0.9.0
type ServerConfigPart struct {
// server
Port int `mapstructure:"port"`
Mode ServerType `mapstructure:"mode"`
}
type ServerType ¶ added in v0.9.0
type ServerType = string
const ( StAll ServerType = "ALL" StWorker ServerType = "WORKER" StGateway ServerType = "GATEWAY" )
type WorkerConfigPart ¶ added in v0.9.0
type WorkspaceConfig ¶
WorkspaceConfig
as an infra lib, it will not assume what kind of repo you used.
just two fields: - repoId: unique id of your repo, no matter git or svn, even appId. - revHash: unique id of your version.
func (*WorkspaceConfig) Key ¶
func (wc *WorkspaceConfig) Key() (string, error)
func (*WorkspaceConfig) Verify ¶
func (wc *WorkspaceConfig) Verify() error
Click to show internal directories.
Click to hide internal directories.