client

package
v0.0.44 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 26, 2021 License: Apache-2.0 Imports: 16 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewError

func NewError(message string) error

Types

type AuthRequestPayload

type AuthRequestPayload struct {
	GrantType    string `json:"grant_type"`
	Audience     string `json:"audience"`
	ClientId     string `json:"client_id"`
	ClientSecret string `json:"client_secret"`
}

func NewAuthRequestPayload

func NewAuthRequestPayload(clientId string, clientSecret string) AuthRequestPayload

type AuthResponsePayload

type AuthResponsePayload struct {
	AccessToken string `json:"access_token"`
	Scope       string `json:"scope"`
	ExpiresIn   int    `json:"expires_in"`
	TokenType   string `json:"token_type"`
}

type CCClient added in v0.0.39

type CCClient struct {
	AuthResponsePayload AuthResponsePayload

	ClusterParams ClusterParams

	ClusterCreatedResponse ClusterCreatedResponse

	ClusterStatusResponse ClusterStatusResponse

	ZeebeClientCreate ZeebeClientCreatedResponse
	// contains filtered or unexported fields
}

func (*CCClient) CreateClusterCustomConfig added in v0.0.39

func (c *CCClient) CreateClusterCustomConfig(clusterParams ClusterCreationParams) (string, error)

func (*CCClient) CreateClusterCustomConfigWithContext added in v0.0.42

func (c *CCClient) CreateClusterCustomConfigWithContext(ctx context.Context, clusterParams ClusterCreationParams) (string, error)

func (*CCClient) CreateClusterDefault added in v0.0.39

func (c *CCClient) CreateClusterDefault(clusterName string) (string, error)

func (*CCClient) CreateClusterDefaultWithContext added in v0.0.42

func (c *CCClient) CreateClusterDefaultWithContext(ctx context.Context, clusterName string) (string, error)

func (*CCClient) CreateClusterWithParams added in v0.0.39

func (c *CCClient) CreateClusterWithParams(clusterName string, clusterPlanName string, channelName string, generationName string, clusterRegion string) (string, error)

func (*CCClient) CreateClusterWithParamsAndContext added in v0.0.42

func (c *CCClient) CreateClusterWithParamsAndContext(ctx context.Context, clusterName string, clusterPlanName string, channelName string, generationName string, clusterRegion string) (string, error)

func (*CCClient) CreateZeebeClient added in v0.0.39

func (c *CCClient) CreateZeebeClient(clusterID string, clientName string) (ZeebeClientCreatedResponse, error)

func (*CCClient) CreateZeebeClientWithContext added in v0.0.42

func (c *CCClient) CreateZeebeClientWithContext(ctx context.Context, clusterID string, clientName string) (ZeebeClientCreatedResponse, error)

func (*CCClient) DeleteCluster added in v0.0.39

func (c *CCClient) DeleteCluster(clusterId string) (bool, error)

func (*CCClient) DeleteClusterWithContext added in v0.0.42

func (c *CCClient) DeleteClusterWithContext(ctx context.Context, clusterId string) (bool, error)

func (*CCClient) DeleteZeebeClient added in v0.0.39

func (c *CCClient) DeleteZeebeClient(clusterID string, clientID string) (bool, error)

func (*CCClient) DeleteZeebeClientWithContext added in v0.0.42

func (c *CCClient) DeleteZeebeClientWithContext(ctx context.Context, clusterID string, clientID string) (bool, error)

func (*CCClient) GetClusterByName added in v0.0.39

func (c *CCClient) GetClusterByName(name string) (Cluster, error)

func (*CCClient) GetClusterByNameWithContext added in v0.0.42

func (c *CCClient) GetClusterByNameWithContext(ctx context.Context, name string) (Cluster, error)

func (*CCClient) GetClusterDetails added in v0.0.39

func (c *CCClient) GetClusterDetails(clusterId string) (ClusterStatus, error)

func (*CCClient) GetClusterDetailsWithContext added in v0.0.42

func (c *CCClient) GetClusterDetailsWithContext(ctx context.Context, clusterId string) (ClusterStatus, error)

func (*CCClient) GetClusterParams added in v0.0.39

func (c *CCClient) GetClusterParams() (*ClusterParams, error)

func (*CCClient) GetClusterParamsWithContext added in v0.0.42

func (c *CCClient) GetClusterParamsWithContext(ctx context.Context) (*ClusterParams, error)

func (*CCClient) GetClusters added in v0.0.39

func (c *CCClient) GetClusters() ([]Cluster, error)

func (*CCClient) GetClustersWithContext added in v0.0.42

func (c *CCClient) GetClustersWithContext(ctx context.Context) ([]Cluster, error)

GetClusters from Camunda Cloud

func (*CCClient) GetZeebeClientDetails added in v0.0.39

func (c *CCClient) GetZeebeClientDetails(clusterID string, clientID string) (ZeebeClientDetailsResponse, error)

func (*CCClient) GetZeebeClientDetailsWithContext added in v0.0.42

func (c *CCClient) GetZeebeClientDetailsWithContext(ctx context.Context, clusterID string, clientID string) (ZeebeClientDetailsResponse, error)

func (*CCClient) GetZeebeClients added in v0.0.39

func (c *CCClient) GetZeebeClients(clusterID string) ([]ZeebeClientResponse, error)

func (*CCClient) GetZeebeClientsWithContext added in v0.0.42

func (c *CCClient) GetZeebeClientsWithContext(ctx context.Context, clusterID string) ([]ZeebeClientResponse, error)

GetZeebeClients - List all Zeebe clients

func (*CCClient) InitTracer added in v0.0.40

func (c *CCClient) InitTracer() func()

func (*CCClient) Login added in v0.0.39

func (c *CCClient) Login(clientId string, clientSecret string) (bool, error)

func (*CCClient) LoginWithContext added in v0.0.42

func (c *CCClient) LoginWithContext(ctx context.Context, clientId string, clientSecret string) (bool, error)

func (*CCClient) SetCCApiURL added in v0.0.44

func (c *CCClient) SetCCApiURL(ccApiURL string)

func (*CCClient) SetTracerURL added in v0.0.44

func (c *CCClient) SetTracerURL(tracerURL string)

func (*CCClient) TracingEnabled added in v0.0.44

func (c *CCClient) TracingEnabled(tracingEnabled bool)

type Channel

type Channel struct {
	Id                string       `json:"uuid"`
	Name              string       `json:"name"`
	AllowedGeneration []Generation `json:"allowedGenerations"`
	DefaultGeneration Generation   `json:"defaultGeneration"`
}

type Cluster

type Cluster struct {
	ID         string     `json:"uuid"`
	Name       string     `json:"name"`
	Channel    Channel    `json:"channel"`
	Generation Generation `json:"generation"`
	Created    string     `json:"created"`
	//K8sContext      K8sContext      `json:"k8sContext"`
	ClusterMetadata  ClusterMetadata  `json:"metadata"`
	ClusterPlantType ClusterPlantType `json:"planType"`
}

type ClusterCreatedResponse

type ClusterCreatedResponse struct {
	ClusterId string `json:"clusterId"`
}

type ClusterCreationParams

type ClusterCreationParams struct {
	ClusterName  string `json:"name"`
	ChannelId    string `json:"channelId"`
	GenerationId string `json:"generationId"`
	RegionId     string `json:"regionId"`
	PlanTypeId   string `json:"planTypeId"`
}

func NewClusterCreationParams

func NewClusterCreationParams(clusterName string, channelId string,
	generationId string, regionId string,
	planTypeId string) ClusterCreationParams

type ClusterMetadata

type ClusterMetadata struct {
	ID                string `json:"uid"`
	CreationTimestamp string `json:"creationTimestamp"`
	Generation        int    `json:"generation"`
	Name              string `json:"name"`
	ResourceVersion   string `json:"resourceVersion"`
	SelfLink          string `json:"selfLink"`
}

type ClusterParams

type ClusterParams struct {
	Channels         []Channel          `json:"channels"`
	ClusterPlanTypes []ClusterPlantType `json:"clusterPlanTypes"`
	Regions          []Region           `json:"regions"`
}

type ClusterPlantType

type ClusterPlantType struct {
	Id         string     `json:"uuid"`
	Name       string     `json:"name"`
	K8sContext K8sContext `json:"k8sContext"`
}

type ClusterStatus

type ClusterStatus struct {
	OperateStatus  string `json:"operateStatus"`
	OperateURL     string `json:"operateUrl"`
	Ready          string `json:"ready"`
	ZeebeStatus    string `json:"zeebeStatus"`
	ZeebeURL       string `json:"zeebeUrl"`
	TaskListStatus string `json:"tasklistStatus"`
	TaskListURL    string `json:"tasklistUrl"`
}

type ClusterStatusResponse

type ClusterStatusResponse struct {
	ClusterId     string        `json:"uuid"`
	ClusterStatus ClusterStatus `json:"status"`
}

type ErrorString

type ErrorString struct {
	// contains filtered or unexported fields
}

func (*ErrorString) Error

func (e *ErrorString) Error() string

type Generation

type Generation struct {
	Id   string `json:"uuid"`
	Name string `json:"name"`
}

type K8sContext

type K8sContext struct {
	UUID   string `json:"uuid"`
	Name   string `json:"name"`
	Region string `json:"region"`
	Zone   string `json:"zone"`
}

type Region

type Region struct {
	Id   string `json:"uuid"`
	Name string `json:"name"`
}

type ZeebeClientCreatePayload added in v0.0.27

type ZeebeClientCreatePayload struct {
	ClientName string `json:"clientName"`
}

type ZeebeClientCreatedResponse added in v0.0.27

type ZeebeClientCreatedResponse struct {
	Name         string `json:"name"`
	ClientID     string `json:"clientId"`
	ClientSecret string `json:"clientSecret"`
}

type ZeebeClientDetailsResponse added in v0.0.27

type ZeebeClientDetailsResponse struct {
	Name                        string `json:"name"`
	ZEEBEADDRESS                string `json:"ZEEBE_ADDRESS"`
	ZEEBECLIENTID               string `json:"ZEEBE_CLIENT_ID"`
	ZEEBEAUTHORIZATIONSERVERURL string `json:"ZEEBE_AUTHORIZATION_SERVER_URL"`
}

type ZeebeClientResponse added in v0.0.27

type ZeebeClientResponse struct {
	ClientID    string   `json:"clientId"`
	Created     string   `json:"created"`
	CreatedBy   string   `json:"createdBy"`
	UUID        string   `json:"uuid"`
	Name        string   `json:"name"`
	Internal    bool     `json:"internal"`
	Permissions []string `json:"permissions"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL