Documentation ¶
Index ¶
- Constants
- Variables
- func IsBlackListError(e error) bool
- func NewBlackListError(blackListedClass string, blackListedInstance string) error
- type BlackListError
- type ExtraConfig
- type LuigiClientInterface
- type PagerDutyClientInterface
- type SSAMClientInterface
- type ServiceCentralStoreInterface
- type ServiceHandler
- func (h *ServiceHandler) ServiceCreate(ctx context.Context, service *creator_v1.Service) (*creator_v1.Service, error)
- func (h *ServiceHandler) ServiceDelete(ctx context.Context, name voyager.ServiceName) (*creator_v1.Service, error)
- func (h *ServiceHandler) ServiceGet(ctx context.Context, name voyager.ServiceName) (*creator_v1.Service, error)
- func (h *ServiceHandler) ServiceList(w http.ResponseWriter, r *http.Request)
- func (h *ServiceHandler) ServiceListNew(ctx context.Context) (*creator_v1.ServiceList, error)
- func (h *ServiceHandler) ServiceUpdate(ctx context.Context, name voyager.ServiceName, objInfo rest.UpdatedObjectInfo) (*creator_v1.Service, error)
Constants ¶
View Source
const ( ServiceNameMinimumLength = 1 ServiceNameMaximumLength = 24 ServiceNameExpr = schema.ResourceNameSchemaPattern EC2ComputeNameMaximumLength = ec2compute_v2.MaximumServiceNameLength )
Variables ¶
View Source
var ( ServiceNameRegExp = regexp.MustCompile(ServiceNameExpr) ServiceGroupResource = creator_v1.Resource(creator_v1.ServiceResourceSingular) )
Functions ¶
func IsBlackListError ¶
IsBlackListError checks if 'e' is a BlackListError. Returns true when it is a BlackListError and is not nil.
func NewBlackListError ¶
NewBlackListError creates a BlackListError. blackListedClass is the the type of thing that is blacklisted, like a name or URL, and blackListedInstance is the actual instance that was inputted, like the name "voyager" or the URL "https://atlassian.com".
Types ¶
type BlackListError ¶
type BlackListError struct {
// contains filtered or unexported fields
}
lackListError is for cases where a particular input has been reserved.
func (*BlackListError) Error ¶
func (e *BlackListError) Error() string
Error is to implement the 'error' interface.
type ExtraConfig ¶
type LuigiClientInterface ¶
type PagerDutyClientInterface ¶
type PagerDutyClientInterface interface { FindOrCreate(serviceName voyager.ServiceName, user auth.User, email string) (creator_v1.PagerDutyMetadata, error) Delete(serviceName voyager.ServiceName) error }
type SSAMClientInterface ¶
type SSAMClientInterface interface { GetExpectedServiceContainerName(ctx context.Context, metadata *ssam.ServiceMetadata) string CreateService(ctx context.Context, metadata *ssam.ServiceMetadata) (string, ssam.AccessLevels, error) DeleteService(ctx context.Context, metadata *ssam.ServiceMetadata) error }
type ServiceCentralStoreInterface ¶
type ServiceCentralStoreInterface interface { FindOrCreateService(ctx context.Context, user auth.User, service *creator_v1.Service) (*creator_v1.Service, error) GetService(ctx context.Context, user auth.OptionalUser, name servicecentral.ServiceName) (*creator_v1.Service, error) ListServices(ctx context.Context, user auth.OptionalUser) ([]creator_v1.Service, error) ListModifiedServices(ctx context.Context, user auth.OptionalUser, modifiedSince time.Time) ([]creator_v1.Service, error) PatchService(ctx context.Context, user auth.User, service *creator_v1.Service) error DeleteService(ctx context.Context, user auth.User, name servicecentral.ServiceName) error }
type ServiceHandler ¶
type ServiceHandler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler(config *ExtraConfig) (*ServiceHandler, error)
func (*ServiceHandler) ServiceCreate ¶
func (h *ServiceHandler) ServiceCreate(ctx context.Context, service *creator_v1.Service) (*creator_v1.Service, error)
func (*ServiceHandler) ServiceDelete ¶
func (h *ServiceHandler) ServiceDelete(ctx context.Context, name voyager.ServiceName) (*creator_v1.Service, error)
func (*ServiceHandler) ServiceGet ¶
func (h *ServiceHandler) ServiceGet(ctx context.Context, name voyager.ServiceName) (*creator_v1.Service, error)
func (*ServiceHandler) ServiceList ¶
func (h *ServiceHandler) ServiceList(w http.ResponseWriter, r *http.Request)
func (*ServiceHandler) ServiceListNew ¶
func (h *ServiceHandler) ServiceListNew(ctx context.Context) (*creator_v1.ServiceList, error)
func (*ServiceHandler) ServiceUpdate ¶
func (h *ServiceHandler) ServiceUpdate(ctx context.Context, name voyager.ServiceName, objInfo rest.UpdatedObjectInfo) (*creator_v1.Service, error)
Directories ¶
Path | Synopsis |
---|---|
This package has the automatically generated clientset.
|
This package has the automatically generated clientset. |
fake
This package has the automatically generated fake clientset.
|
This package has the automatically generated fake clientset. |
scheme
This package contains the scheme of the automatically generated clientset.
|
This package contains the scheme of the automatically generated clientset. |
typed/creator/v1
This package has the automatically generated typed clients.
|
This package has the automatically generated typed clients. |
typed/creator/v1/fake
Package fake has the automatically generated clients.
|
Package fake has the automatically generated clients. |
Click to show internal directories.
Click to hide internal directories.