Documentation
¶
Overview ¶
packae edgecluster implements used edge cluster related types in the GraphQL transport layer
packae edgecluster implements used edge cluster related types in the GraphQL transport layer
packae edgecluster implements used edge cluster related types in the GraphQL transport layer
Index ¶
- type CreateEdgeClusterContract
- type CreateEdgeClusterInput
- type CreateEdgeClusterInputArgument
- type CreateEdgeClusterPayloadResolverContract
- type DeleteEdgeClusterContract
- type DeleteEdgeClusterInput
- type DeleteEdgeClusterInputArgument
- type DeleteEdgeClusterPayloadResolverContract
- type EdgeClusterClientContract
- type EdgeClusterClusterEdgeClusterInputArgument
- type EdgeClusterDetail
- type EdgeClusterEdgeClustersInputArgument
- type EdgeClusterProvisionDetailResolverContract
- type EdgeClusterResolverContract
- type EdgeClusterTenantResolverContract
- type EdgeClusterTypeConnectionResolverContract
- type EdgeClusterTypeEdgeResolverContract
- type IngressResolverContract
- type MutationResolverCreatorContract
- type PortResolverContract
- type QueryResolverCreatorContract
- type RootResolverContract
- type UpdateEdgeClusterContract
- type UpdateEdgeClusterInput
- type UpdateEdgeClusterInputArgument
- type UpdateEdgeClusterPayloadResolverContract
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateEdgeClusterContract ¶
type CreateEdgeClusterContract interface {
// MutateAndGetPayload creates a new edge cluster and returns the payload contains the result of creating a new edge cluster
// ctx: Mandatory. Reference to the context
// args: Mandatory. Reference to the input argument contains edge cluster information to create
// Returns the new edge cluster payload or error if something goes wrong
MutateAndGetPayload(
ctx context.Context,
args CreateEdgeClusterInputArgument) (CreateEdgeClusterPayloadResolverContract, error)
}
CreateEdgeClusterContract declares the type to use when creating a new edge cluster
type CreateEdgeClusterInput ¶
type CreateEdgeClusterInputArgument ¶
type CreateEdgeClusterInputArgument struct {
Input CreateEdgeClusterInput
}
type CreateEdgeClusterPayloadResolverContract ¶
type CreateEdgeClusterPayloadResolverContract interface {
// EdgeCluster returns the new edge cluster inforamtion
// ctx: Mandatory. Reference to the context
// Returns the new edge cluster inforamtion
EdgeCluster(ctx context.Context) (EdgeClusterTypeEdgeResolverContract, error)
// ClientMutationId returns the client mutation ID that was provided as part of the mutation request
// ctx: Mandatory. Reference to the context
// Returns the provided clientMutationId as part of mutation request
ClientMutationId(ctx context.Context) *string
}
CreateEdgeClusterPayloadResolverContract declares the resolver that can return the payload contains the result of creating a new edge cluster
type DeleteEdgeClusterContract ¶
type DeleteEdgeClusterContract interface {
// MutateAndGetPayload update an existing edge cluster and returns the payload contains the result of deleting an existing edge cluster
// ctx: Mandatory. Reference to the context
// args: Mandatory. Reference to the input argument contains edge cluster information to update
// Returns the deleted edge cluster payload or error if something goes wrong
MutateAndGetPayload(
ctx context.Context,
args DeleteEdgeClusterInputArgument) (DeleteEdgeClusterPayloadResolverContract, error)
}
DeleteEdgeClusterContract declares the type to use when updating an existing edge cluster
type DeleteEdgeClusterInput ¶
type DeleteEdgeClusterInputArgument ¶
type DeleteEdgeClusterInputArgument struct {
Input DeleteEdgeClusterInput
}
type DeleteEdgeClusterPayloadResolverContract ¶
type DeleteEdgeClusterPayloadResolverContract interface {
// DeletedEdgeClusterID returns the unique identifier of the edge cluster that got deleted
// ctx: Mandatory. Reference to the context
// Returns the unique identifier of the the edge cluster that got deleted
DeletedEdgeClusterID(ctx context.Context) graphql.ID
// ClientMutationId returns the client mutation ID that was provided as part of the mutation request
// ctx: Mandatory. Reference to the context
// Returns the provided clientMutationId as part of mutation request
ClientMutationId(ctx context.Context) *string
}
DeleteEdgeClusterPayloadResolverContract declares the resolver that can return the payload contains the result of deleting an existing edge cluster
type EdgeClusterClientContract ¶
type EdgeClusterClientContract interface {
// CreateClient creats a new edge cluster gRPC client and returns the connection
// and the client to the caller.
// Returns connection and the edge cluster gRPC client or error if something goes wrong.
CreateClient() (*grpc.ClientConn, edgeClusterGrpcContract.EdgeClusterServiceClient, error)
}
EdgeClusterClientContract wraps the edge cluser gRPC client to make it easy for testing
type EdgeClusterDetail ¶
type EdgeClusterDetail struct {
EdgeCluster *edgeclusterGrpcContract.EdgeCluster
ProvisionDetail *edgeclusterGrpcContract.EdgeClusterProvisionDetail
}
type EdgeClusterEdgeClustersInputArgument ¶
type EdgeClusterEdgeClustersInputArgument struct {
relay.ConnectionArgument
EdgeClusterIDs *[]graphql.ID
SortOption *string
}
type EdgeClusterProvisionDetailResolverContract ¶ added in v0.4.1
type EdgeClusterProvisionDetailResolverContract interface {
// Ingress returns the ingress details of the edge cluster master node
// ctx: Mandatory. Reference to the context
// Returns the ingress details of the edge cluster master node
Ingress(ctx context.Context) (*[]IngressResolverContract, error)
// Ports is a list of records of edge-cluster master ports
// ctx: Mandatory. Reference to the context
// Returns the Ports is a list of records of edge-cluster master ports
Ports(ctx context.Context) (*[]PortResolverContract, error)
// KubeconfigContent returns the edge cluster Kubeconfig content
// ctx: Mandatory. Reference to the context
// Returns the edge cluster Kubeconfig content
KubeconfigContent(ctx context.Context) *string
}
EdgeClusterProvisionDetailResolverContract declares the resolver that returns edge cluster provisioning details
type EdgeClusterResolverContract ¶
type EdgeClusterResolverContract interface {
// ID returns edge cluster unique identifier
// ctx: Mandatory. Reference to the context
// Returns the edge cluster unique identifier
ID(ctx context.Context) graphql.ID
// Name returns edge cluster name
// ctx: Mandatory. Reference to the context
// Returns the edge cluster name
Name(ctx context.Context) string
// ClusterSecret returns edge cluster secret
// ctx: Mandatory. Reference to the context
// Returns the edge cluster secret
ClusterSecret(ctx context.Context) string
// ClusterType returns the edge cluster current type
// ctx: Mandatory. Reference to the context
// Returns the edge cluster current type or error if something went wrong
ClusterType(ctx context.Context) (string, error)
// Tenant returns edge cluster tenant
// ctx: Mandatory. Reference to the context
// Returns the edge cluster tenant
Tenant(ctx context.Context) (EdgeClusterTenantResolverContract, error)
// ProvisionDetail returns edge cluster provisioning detail
// ctx: Mandatory. Reference to the context
// Returns the edge cluster provisioning detail
ProvisionDetail(ctx context.Context) (EdgeClusterProvisionDetailResolverContract, error)
}
EdgeClusterResolverContract declares the resolver that can retrieve edge cluster information
type EdgeClusterTenantResolverContract ¶
type EdgeClusterTenantResolverContract interface {
// ID returns tenant unique identifier
// ctx: Mandatory. Reference to the context
// Returns the tenant unique identifier
ID(ctx context.Context) graphql.ID
// Name returns tenant name
// ctx: Mandatory. Reference to the context
// Returns the tenant name
Name(ctx context.Context) string
}
EdgeClusterTenantResolverContract declares the resolver that returns edge cluster tenant
type EdgeClusterTypeConnectionResolverContract ¶
type EdgeClusterTypeConnectionResolverContract interface {
// PageInfo returns the paging information compatible with graphql-relay
// ctx: Mandatory. Reference to the context
// Returns the paging information
PageInfo(ctx context.Context) (relay.PageInfoResolverContract, error)
// Edges returns the edge cluster edges compatible with graphql-relay
// ctx: Mandatory. Reference to the context
// Returns the edge cluster edges
Edges(ctx context.Context) (*[]EdgeClusterTypeEdgeResolverContract, error)
// TotalCount returns total count of the matched edge clusters
// ctx: Mandatory. Reference to the context
// Returns the total count of the matched edge cluster
TotalCount(ctx context.Context) *int32
}
EdgeClusterTypeConnectionResolverContract declares the resolver that returns edge cluster edge compatible with graphql-relay
type EdgeClusterTypeEdgeResolverContract ¶
type EdgeClusterTypeEdgeResolverContract interface {
// Node returns the edge cluster resolver
// ctx: Mandatory. Reference to the context
// Returns the edge cluster resolver or error if something goes wrong
Node(ctx context.Context) (EdgeClusterResolverContract, error)
// Cursor returns the cursor for the edge cluster edge compatible with graphql-relay
// ctx: Mandatory. Reference to the context
// Returns the cursor
Cursor(ctx context.Context) string
}
EdgeClusterTypeEdgeResolverContract declares the resolver that returns edge cluster edge compatible with graphql-relay
type IngressResolverContract ¶ added in v0.4.1
type IngressResolverContract interface {
// IP is set for load-balancer ingress points that are IP based
// (typically GCE or OpenStack load-balancers)
// ctx: Mandatory. Reference to the context
// Returns the IP is set for load-balancer ingress points that are IP based
IP(ctx context.Context) *string
// Hostname is set for load-balancer ingress points that are DNS based
// (typically AWS load-balancers)
// ctx: Mandatory. Reference to the context
// Returns the Hostname is set for load-balancer ingress points that are DNS based
Hostname(ctx context.Context) *string
}
IngressResolverContract declares the resolver that returns Ingress
type MutationResolverCreatorContract ¶
type MutationResolverCreatorContract interface {
// NewCreateEdgeCluster creates new instance of the CreateEdgeClusterContract, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// Returns the new instance or error if something goes wrong
NewCreateEdgeCluster(ctx context.Context) (CreateEdgeClusterContract, error)
// NewCreateEdgeClusterPayloadResolver creates new instance of the CreateEdgeClusterPayloadResolverContract, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// clientMutationId: Optional. Reference to the client mutation ID to correlate the request and response
// edgeClusterID: Mandatory. The edge cluster unique identifier
// edgeClusterDetail: Mandatory. The edge cluster details
// cursor: Mandatory. The edge cluster cursor
// Returns the new instance or error if something goes wrong
NewCreateEdgeClusterPayloadResolver(
ctx context.Context,
clientMutationId *string,
edgeClusterID string,
edgeClusterDetail *EdgeClusterDetail,
cursor string) (CreateEdgeClusterPayloadResolverContract, error)
// NewUpdateEdgeCluster creates new instance of the UpdateEdgeClusterContract, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// Returns the new instance or error if something goes wrong
NewUpdateEdgeCluster(ctx context.Context) (UpdateEdgeClusterContract, error)
// NewUpdateEdgeClusterPayloadResolver creates new instance of the UpdateEdgeClusterPayloadResolverContract, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// clientMutationId: Optional. Reference to the client mutation ID to correlate the request and response
// edgeClusterID: Mandatory. The edge cluster unique identifier
// edgeClusterDetail: Mandatory. The edge cluster details
// cursor: Mandatory. The edge cluster cursor
// Returns the new instance or error if something goes wrong
NewUpdateEdgeClusterPayloadResolver(
ctx context.Context,
clientMutationId *string,
edgeClusterID string,
edgeClusterDetail *EdgeClusterDetail,
cursor string) (UpdateEdgeClusterPayloadResolverContract, error)
// NewDeleteEdgeCluster creates new instance of the DeleteEdgeClusterContract, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// Returns the new instance or error if something goes wrong
NewDeleteEdgeCluster(ctx context.Context) (DeleteEdgeClusterContract, error)
// NewDeleteEdgeClusterPayloadResolver creates new instance of the DeleteEdgeClusterPayloadResolverContract, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// edgeClusterID: Mandatory. The edge cluster unique identifier
// clientMutationId: Optional. Reference to the client mutation ID to correlate the request and response
// Returns the new instance or error if something goes wrong
NewDeleteEdgeClusterPayloadResolver(
ctx context.Context,
edgeClusterID string,
clientMutationId *string) (DeleteEdgeClusterPayloadResolverContract, error)
}
type PortResolverContract ¶ added in v0.4.1
type PortResolverContract interface {
// Port returns the port number of the edge-cluster master port of which status is recorded here
// ctx: Mandatory. Reference to the context
// Returns the port number of the edge-cluster master port of which status is recorded here
Port(ctx context.Context) int32
// Protocol returns the protocol of the edge-cluster master port of which status is recorded here
// ctx: Mandatory. Reference to the context
// Returns the protocol of the edge-cluster master port of which status is recorded here
Protocol(ctx context.Context) string
}
PortResolverContract declares the resolver that returns Port
type QueryResolverCreatorContract ¶
type QueryResolverCreatorContract interface {
// NewEdgeClusterResolver creates new EdgeClusterResolverContract and returns it
// ctx: Mandatory. Reference to the context
// edgeClusterID: Mandatory. The edge cluster unique identifier
// edgeClusterDetail: Optional. The edge cluster details, if provided, the value be used instead of contacting the edge cluster service
// Returns the EdgeClusterResolverContract or error if something goes wrong
NewEdgeClusterResolver(
ctx context.Context,
edgeClusterID string,
edgeClusterDetail *EdgeClusterDetail) (EdgeClusterResolverContract, error)
// NewEdgeClusterTypeEdgeResolver creates new EdgeClusterTypeEdgeResolverContract and returns it
// ctx: Mandatory. Reference to the context
// edgeClusterID: Mandatory. The edge cluster unique identifier
// cursor: Mandatory. The cursor
// edgeClusterDetail: Optional. The edge cluster details, if provided, the value be used instead of contacting the edge cluster service
// Returns the EdgeClusterTypeEdgeResolverContract or error if something goes wrong
NewEdgeClusterTypeEdgeResolver(
ctx context.Context,
edgeClusterID string,
cursor string,
edgeClusterDetail *EdgeClusterDetail) (EdgeClusterTypeEdgeResolverContract, error)
// NewEdgeClusterTypeConnectionResolver creates new EdgeClusterTypeConnectionResolverContract and returns it
// ctx: Mandatory. Reference to the context
// edgeClusters: Mandatory. Reference the list of edge clusters
// hasPreviousPage: Mandatory. Indicates whether more edges exist prior to the set defined by the clients arguments
// hasNextPage: Mandatory. Indicates whether more edges exist following the set defined by the clients arguments
// totalCount: Mandatory. The total count of matched edge clusters
// Returns the EdgeClusterTypeConnectionResolverContract or error if something goes wrong
NewEdgeClusterTypeConnectionResolver(
ctx context.Context,
edgeClusters []*edgeclusterGrpcContract.EdgeClusterWithCursor,
hasPreviousPage bool,
hasNextPage bool,
totalCount int32) (EdgeClusterTypeConnectionResolverContract, error)
// NewEdgeClusterTenantResolver creates new EdgeClusterTenatnResolverContract and returns it
// ctx: Mandatory. Reference to the context
// tenantID: Mandatory. The tenant unique identifier
// Returns the EdgeClusterTenatnResolverContract or error if something goes wrong
NewEdgeClusterTenantResolver(
ctx context.Context,
tenantID string) (EdgeClusterTenantResolverContract, error)
// NewEdgeClusterProvisionDetailResolver creates new EdgeClusterProvisionDetailResolverContract and returns it
// ctx: Mandatory. Reference to the context
// provisionDetail: Optional. The edge cluster provisioning details
// Returns the EdgeClusterProvisionDetailResolverContract or error if something goes wrong
NewEdgeClusterProvisionDetailResolver(
ctx context.Context,
provisionDetail *edgeclusterGrpcContract.EdgeClusterProvisionDetail) (EdgeClusterProvisionDetailResolverContract, error)
// NewIngressResolver creates new instance of the ingressResolver, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// ingress: Mandatory. The ingress details
// Returns the new instance or error if something goes wrong
NewIngressResolver(
ctx context.Context,
ingress *edgeclusterGrpcContract.Ingress) (IngressResolverContract, error)
// NewPortResolver creates new instance of the PortResolver, setting up all dependencies and returns the instance
// ctx: Mandatory. Reference to the context
// logger: Mandatory. Reference to the logger service
// Port: Mandatory. The PostStatus details
// Returns the new instance or error if something goes wrong
NewPortResolver(
ctx context.Context,
Port *edgeclusterGrpcContract.Port) (PortResolverContract, error)
}
type RootResolverContract ¶
type RootResolverContract interface {
// CreateEdgeCluster returns create edge cluster mutator
// ctx: Mandatory. Reference to the context
// Returns the create edge cluster mutator or error if something goes wrong
CreateEdgeCluster(
ctx context.Context,
args CreateEdgeClusterInputArgument) (CreateEdgeClusterPayloadResolverContract, error)
// UpdateEdgeCluster returns update edge cluster mutator
// ctx: Mandatory. Reference to the context
// Returns the update edge cluster mutator or error if something goes wrong
UpdateEdgeCluster(
ctx context.Context,
args UpdateEdgeClusterInputArgument) (UpdateEdgeClusterPayloadResolverContract, error)
// DeleteEdgeCluster returns delete edge cluster mutator
// ctx: Mandatory. Reference to the context
// Returns the delete edge cluster mutator or error if something goes wrong
DeleteEdgeCluster(
ctx context.Context,
args DeleteEdgeClusterInputArgument) (DeleteEdgeClusterPayloadResolverContract, error)
}
RootResolverContract declares the root resolver
type UpdateEdgeClusterContract ¶
type UpdateEdgeClusterContract interface {
// MutateAndGetPayload update an existing edge cluster and returns the payload contains the result of updating an existing edge cluster
// ctx: Mandatory. Reference to the context
// args: Mandatory. Reference to the input argument contains edge cluster information to update
// Returns the updated edge cluster payload or error if something goes wrong
MutateAndGetPayload(
ctx context.Context,
args UpdateEdgeClusterInputArgument) (UpdateEdgeClusterPayloadResolverContract, error)
}
UpdateEdgeClusterContract declares the type to use when updating an existing edge cluster
type UpdateEdgeClusterInput ¶
type UpdateEdgeClusterInputArgument ¶
type UpdateEdgeClusterInputArgument struct {
Input UpdateEdgeClusterInput
}
type UpdateEdgeClusterPayloadResolverContract ¶
type UpdateEdgeClusterPayloadResolverContract interface {
// EdgeCluster returns the updated edge cluster inforamtion
// ctx: Mandatory. Reference to the context
// Returns the updated edge cluster inforamtion
EdgeCluster(ctx context.Context) (EdgeClusterTypeEdgeResolverContract, error)
// ClientMutationId returns the client mutation ID that was provided as part of the mutation request
// ctx: Mandatory. Reference to the context
// Returns the provided clientMutationId as part of mutation request
ClientMutationId(ctx context.Context) *string
}
UpdateEdgeClusterPayloadResolverContract declares the resolver that can return the payload contains the result of updating an existing edge cluster