Documentation
¶
Index ¶
- Variables
- func DeleteNetwork(store Store, req *DeleteNetworkRequest) error
- func ImportNetwork(store Store, net *Network, overwrite bool) error
- type APIConfig
- type DeleteNetworkRequest
- type DescribeNetworkRequest
- type DescribeNetworkResponse
- type GRPCConfig
- type GraphQLConfig
- type ImportNetworkFromSourceRequest
- type ImportNetworkFromSourceResponse
- type ListNetworksResponse
- type Network
- type NetworkAlreadyExistsError
- type NetworkDoesNotExistError
- type RESTConfig
- type Reader
- type Readers
- type Store
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNetworkDoesNotHaveGRPCHostConfigured = errors.New("network configuration does not have any gRPC host set")
Functions ¶
func DeleteNetwork ¶
func DeleteNetwork(store Store, req *DeleteNetworkRequest) error
Types ¶
type APIConfig ¶
type APIConfig struct { GRPC GRPCConfig `json:"grpc"` REST RESTConfig `json:"rest"` GraphQL GraphQLConfig `json:"graphQl"` }
type DeleteNetworkRequest ¶
type DeleteNetworkRequest struct {
Name string `json:"name"`
}
type DescribeNetworkRequest ¶
type DescribeNetworkRequest struct {
Name string `json:"name"`
}
type DescribeNetworkResponse ¶
type DescribeNetworkResponse struct { Name string `json:"name"` Level string `json:"logLevel"` TokenExpiry string `json:"tokenExpiry"` Port int `json:"port"` Host string `json:"host"` API struct { GRPCConfig struct { Hosts []string `json:"hosts"` Retries uint64 `json:"retries"` } `json:"grpcConfig"` RESTConfig struct { Hosts []string `json:"hosts"` } `json:"restConfig"` GraphQLConfig struct { Hosts []string `json:"hosts"` } `json:"graphQLConfig"` } `json:"api"` }
func DescribeNetwork ¶
func DescribeNetwork(store Store, req *DescribeNetworkRequest) (*DescribeNetworkResponse, error)
type GRPCConfig ¶
type GraphQLConfig ¶
type GraphQLConfig struct {
Hosts []string `json:"hosts"`
}
type ImportNetworkFromSourceResponse ¶
type ImportNetworkFromSourceResponse struct { Name string `json:"name"` FilePath string `json:"filePath"` }
func ImportNetworkFromSource ¶
func ImportNetworkFromSource(s Store, rs Readers, req *ImportNetworkFromSourceRequest) (*ImportNetworkFromSourceResponse, error)
type ListNetworksResponse ¶
type ListNetworksResponse struct {
Networks []string `json:"networks"`
}
func ListNetworks ¶
func ListNetworks(store Store) (*ListNetworksResponse, error)
type Network ¶
type Network struct { Name string `json:"name"` Level encoding.LogLevel `json:"level"` TokenExpiry encoding.Duration `json:"tokenExpiry"` Port int `json:"port"` Host string `json:"host"` API APIConfig `json:"api"` }
func (*Network) EnsureCanConnectGRPCNode ¶
type NetworkAlreadyExistsError ¶
type NetworkAlreadyExistsError struct {
Name string
}
func NewNetworkAlreadyExistsError ¶
func NewNetworkAlreadyExistsError(n string) NetworkAlreadyExistsError
func (NetworkAlreadyExistsError) Error ¶
func (e NetworkAlreadyExistsError) Error() string
type NetworkDoesNotExistError ¶
type NetworkDoesNotExistError struct {
Name string
}
func NewNetworkDoesNotExistError ¶
func NewNetworkDoesNotExistError(n string) NetworkDoesNotExistError
func (NetworkDoesNotExistError) Error ¶
func (e NetworkDoesNotExistError) Error() string
type RESTConfig ¶
type RESTConfig struct {
Hosts []string `json:"hosts"`
}
type Readers ¶
func NewReaders ¶
func NewReaders() Readers
Click to show internal directories.
Click to hide internal directories.