fastly

package
v0.21.3 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2021 License: MPL-2.0 Imports: 16 Imported by: 5

Documentation

Index

Constants

View Source
const (
	// ServiceTypeVCL is the type for VCL services.
	ServiceTypeVCL = "vcl"
	// ServiceTypeCompute is the type for Compute services.
	ServiceTypeCompute = "wasm"
)
View Source
const (
	WAFStatusCheckDelay      = 5 * time.Second
	WAFStatusCheckMinTimeout = 5 * time.Second
)
View Source
const TerraformProviderProductUserAgent = "terraform-provider-fastly"

Variables

This section is empty.

Functions

func DefaultWAFDeploymentChecker added in v0.20.3

func DefaultWAFDeploymentChecker(conn *gofastly.Client) func(wafID string, version int) (*gofastly.WAFVersion, error)

func Provider

func Provider() terraform.ResourceProvider

Provider returns a terraform.ResourceProvider.

Types

type ACLServiceAttributeHandler added in v0.20.3

type ACLServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*ACLServiceAttributeHandler) Process added in v0.20.3

func (h *ACLServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*ACLServiceAttributeHandler) Read added in v0.20.3

func (*ACLServiceAttributeHandler) Register added in v0.20.3

type BackendServiceAttributeHandler added in v0.20.3

type BackendServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*BackendServiceAttributeHandler) Process added in v0.20.3

func (h *BackendServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*BackendServiceAttributeHandler) Read added in v0.20.3

func (*BackendServiceAttributeHandler) Register added in v0.20.3

type BaseServiceDefinition added in v0.20.3

type BaseServiceDefinition struct {
	Attributes []ServiceAttributeDefinition
	Type       string
}

BaseServiceDefinition is the base implementation of the BaseServiceDefinition interface.

func (*BaseServiceDefinition) GetAttributeHandler added in v0.20.3

func (d *BaseServiceDefinition) GetAttributeHandler() []ServiceAttributeDefinition

func (*BaseServiceDefinition) GetType added in v0.20.3

func (d *BaseServiceDefinition) GetType() string

type BigQueryLoggingServiceAttributeHandler added in v0.20.3

type BigQueryLoggingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*BigQueryLoggingServiceAttributeHandler) Process added in v0.20.3

func (h *BigQueryLoggingServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*BigQueryLoggingServiceAttributeHandler) Read added in v0.20.3

func (*BigQueryLoggingServiceAttributeHandler) Register added in v0.20.3

type BlobStorageLoggingServiceAttributeHandler added in v0.20.3

type BlobStorageLoggingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*BlobStorageLoggingServiceAttributeHandler) Process added in v0.20.3

func (*BlobStorageLoggingServiceAttributeHandler) Read added in v0.20.3

func (*BlobStorageLoggingServiceAttributeHandler) Register added in v0.20.3

type CacheSettingServiceAttributeHandler added in v0.20.3

type CacheSettingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*CacheSettingServiceAttributeHandler) Process added in v0.20.3

func (h *CacheSettingServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*CacheSettingServiceAttributeHandler) Read added in v0.20.3

func (*CacheSettingServiceAttributeHandler) Register added in v0.20.3

type CloudfilesServiceAttributeHandler added in v0.20.3

type CloudfilesServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*CloudfilesServiceAttributeHandler) Process added in v0.20.3

func (h *CloudfilesServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*CloudfilesServiceAttributeHandler) Read added in v0.20.3

func (*CloudfilesServiceAttributeHandler) Register added in v0.20.3

type ConditionServiceAttributeHandler added in v0.20.3

type ConditionServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*ConditionServiceAttributeHandler) Process added in v0.20.3

func (h *ConditionServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*ConditionServiceAttributeHandler) Read added in v0.20.3

func (*ConditionServiceAttributeHandler) Register added in v0.20.3

type Config

type Config struct {
	ApiKey  string
	BaseURL string
	// contains filtered or unexported fields
}

func (*Config) Client

func (c *Config) Client() (interface{}, error)

type DatadogServiceAttributeHandler added in v0.20.3

type DatadogServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*DatadogServiceAttributeHandler) Process added in v0.20.3

func (h *DatadogServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*DatadogServiceAttributeHandler) Read added in v0.20.3

func (*DatadogServiceAttributeHandler) Register added in v0.20.3

type DefaultServiceAttributeHandler added in v0.20.3

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

DefaultServiceAttributeHandler provides a base implementation for ServiceAttributeDefinition.

func (*DefaultServiceAttributeHandler) GetKey added in v0.20.3

GetKey is provided since most attributes will just use their private "key" for interacting with the service.

func (*DefaultServiceAttributeHandler) GetServiceMetadata added in v0.20.3

func (h *DefaultServiceAttributeHandler) GetServiceMetadata() ServiceMetadata

GetServiceMetadata is provided to allow internal methods to get the service Metadata

func (*DefaultServiceAttributeHandler) HasChange added in v0.20.3

See interface definition for comments.

func (*DefaultServiceAttributeHandler) MustProcess added in v0.20.3

func (h *DefaultServiceAttributeHandler) MustProcess(d *schema.ResourceData, initialVersion bool) bool

See interface definition for comments.

type DictionaryServiceAttributeHandler added in v0.20.3

type DictionaryServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*DictionaryServiceAttributeHandler) Process added in v0.20.3

func (h *DictionaryServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*DictionaryServiceAttributeHandler) Read added in v0.20.3

func (*DictionaryServiceAttributeHandler) Register added in v0.20.3

type DiffResult added in v0.20.3

type DiffResult struct {
	Added      []interface{}
	Modified   []interface{}
	Deleted    []interface{}
	Unmodified []interface{}
}

DiffResult contains the differences between two sets

type DigitalOceanServiceAttributeHandler added in v0.20.3

type DigitalOceanServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*DigitalOceanServiceAttributeHandler) Process added in v0.20.3

func (h *DigitalOceanServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*DigitalOceanServiceAttributeHandler) Read added in v0.20.3

func (*DigitalOceanServiceAttributeHandler) Register added in v0.20.3

type DirectorServiceAttributeHandler added in v0.20.3

type DirectorServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*DirectorServiceAttributeHandler) Process added in v0.20.3

func (h *DirectorServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*DirectorServiceAttributeHandler) Read added in v0.20.3

func (*DirectorServiceAttributeHandler) Register added in v0.20.3

type DomainServiceAttributeHandler added in v0.20.3

type DomainServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*DomainServiceAttributeHandler) Process added in v0.20.3

func (h *DomainServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*DomainServiceAttributeHandler) Read added in v0.20.3

func (*DomainServiceAttributeHandler) Register added in v0.20.3

type DynamicSnippetServiceAttributeHandler added in v0.20.3

type DynamicSnippetServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*DynamicSnippetServiceAttributeHandler) Process added in v0.20.3

func (h *DynamicSnippetServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*DynamicSnippetServiceAttributeHandler) Read added in v0.20.3

func (*DynamicSnippetServiceAttributeHandler) Register added in v0.20.3

type ElasticSearchServiceAttributeHandler added in v0.20.3

type ElasticSearchServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*ElasticSearchServiceAttributeHandler) Process added in v0.20.3

func (h *ElasticSearchServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*ElasticSearchServiceAttributeHandler) Read added in v0.20.3

func (*ElasticSearchServiceAttributeHandler) Register added in v0.20.3

type FTPServiceAttributeHandler added in v0.20.3

type FTPServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*FTPServiceAttributeHandler) Process added in v0.20.3

func (h *FTPServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*FTPServiceAttributeHandler) Read added in v0.20.3

func (*FTPServiceAttributeHandler) Register added in v0.20.3

type FastlyClient

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

type GCSLoggingServiceAttributeHandler added in v0.20.3

type GCSLoggingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*GCSLoggingServiceAttributeHandler) Process added in v0.20.3

func (h *GCSLoggingServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*GCSLoggingServiceAttributeHandler) Read added in v0.20.3

func (*GCSLoggingServiceAttributeHandler) Register added in v0.20.3

type GooglePubSubServiceAttributeHandler added in v0.20.3

type GooglePubSubServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*GooglePubSubServiceAttributeHandler) Process added in v0.20.3

func (h *GooglePubSubServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*GooglePubSubServiceAttributeHandler) Read added in v0.20.3

func (*GooglePubSubServiceAttributeHandler) Register added in v0.20.3

type GzipServiceAttributeHandler added in v0.20.3

type GzipServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*GzipServiceAttributeHandler) Process added in v0.20.3

func (h *GzipServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*GzipServiceAttributeHandler) Read added in v0.20.3

func (*GzipServiceAttributeHandler) Register added in v0.20.3

type HTTPSLoggingServiceAttributeHandler added in v0.20.3

type HTTPSLoggingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*HTTPSLoggingServiceAttributeHandler) Process added in v0.20.3

func (h *HTTPSLoggingServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*HTTPSLoggingServiceAttributeHandler) Read added in v0.20.3

func (*HTTPSLoggingServiceAttributeHandler) Register added in v0.20.3

type HeaderServiceAttributeHandler added in v0.20.3

type HeaderServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*HeaderServiceAttributeHandler) Process added in v0.20.3

func (h *HeaderServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*HeaderServiceAttributeHandler) Read added in v0.20.3

func (*HeaderServiceAttributeHandler) Register added in v0.20.3

type HealthCheckServiceAttributeHandler added in v0.20.3

type HealthCheckServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*HealthCheckServiceAttributeHandler) Process added in v0.20.3

func (h *HealthCheckServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*HealthCheckServiceAttributeHandler) Read added in v0.20.3

func (*HealthCheckServiceAttributeHandler) Register added in v0.20.3

type HerokuServiceAttributeHandler added in v0.20.3

type HerokuServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*HerokuServiceAttributeHandler) Process added in v0.20.3

func (h *HerokuServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*HerokuServiceAttributeHandler) Read added in v0.20.3

func (*HerokuServiceAttributeHandler) Register added in v0.20.3

type HoneycombServiceAttributeHandler added in v0.20.3

type HoneycombServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*HoneycombServiceAttributeHandler) Process added in v0.20.3

func (h *HoneycombServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*HoneycombServiceAttributeHandler) Read added in v0.20.3

func (*HoneycombServiceAttributeHandler) Register added in v0.20.3

type KafkaServiceAttributeHandler added in v0.20.3

type KafkaServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*KafkaServiceAttributeHandler) Process added in v0.20.3

func (h *KafkaServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*KafkaServiceAttributeHandler) Read added in v0.20.3

func (*KafkaServiceAttributeHandler) Register added in v0.20.3

type KeyFunc added in v0.20.3

type KeyFunc func(interface{}) (interface{}, error)

KeyFunc calculates a key from an element

type LogentriesServiceAttributeHandler added in v0.20.3

type LogentriesServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*LogentriesServiceAttributeHandler) Process added in v0.20.3

func (h *LogentriesServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*LogentriesServiceAttributeHandler) Read added in v0.20.3

func (*LogentriesServiceAttributeHandler) Register added in v0.20.3

type LogglyServiceAttributeHandler added in v0.20.3

type LogglyServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*LogglyServiceAttributeHandler) Process added in v0.20.3

func (h *LogglyServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*LogglyServiceAttributeHandler) Read added in v0.20.3

func (*LogglyServiceAttributeHandler) Register added in v0.20.3

type LogshuttleServiceAttributeHandler added in v0.20.3

type LogshuttleServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*LogshuttleServiceAttributeHandler) Process added in v0.20.3

func (h *LogshuttleServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*LogshuttleServiceAttributeHandler) Read added in v0.20.3

func (*LogshuttleServiceAttributeHandler) Register added in v0.20.3

type NewRelicServiceAttributeHandler added in v0.20.3

type NewRelicServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*NewRelicServiceAttributeHandler) Process added in v0.20.3

func (h *NewRelicServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*NewRelicServiceAttributeHandler) Read added in v0.20.3

func (*NewRelicServiceAttributeHandler) Register added in v0.20.3

type OpenstackServiceAttributeHandler added in v0.20.3

type OpenstackServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*OpenstackServiceAttributeHandler) Process added in v0.20.3

func (h *OpenstackServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*OpenstackServiceAttributeHandler) Read added in v0.20.3

func (*OpenstackServiceAttributeHandler) Register added in v0.20.3

type PackageServiceAttributeHandler added in v0.20.3

type PackageServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*PackageServiceAttributeHandler) Process added in v0.20.3

func (h *PackageServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*PackageServiceAttributeHandler) Read added in v0.20.3

func (*PackageServiceAttributeHandler) Register added in v0.20.3

type PaperTrailServiceAttributeHandler added in v0.20.3

type PaperTrailServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*PaperTrailServiceAttributeHandler) Process added in v0.20.3

func (h *PaperTrailServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*PaperTrailServiceAttributeHandler) Read added in v0.20.3

func (*PaperTrailServiceAttributeHandler) Register added in v0.20.3

type RequestSettingServiceAttributeHandler added in v0.20.3

type RequestSettingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*RequestSettingServiceAttributeHandler) Process added in v0.20.3

func (h *RequestSettingServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*RequestSettingServiceAttributeHandler) Read added in v0.20.3

func (*RequestSettingServiceAttributeHandler) Register added in v0.20.3

type ResponseObjectServiceAttributeHandler added in v0.20.3

type ResponseObjectServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*ResponseObjectServiceAttributeHandler) Process added in v0.20.3

func (h *ResponseObjectServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*ResponseObjectServiceAttributeHandler) Read added in v0.20.3

func (*ResponseObjectServiceAttributeHandler) Register added in v0.20.3

type S3LoggingServiceAttributeHandler added in v0.20.3

type S3LoggingServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*S3LoggingServiceAttributeHandler) Process added in v0.20.3

func (h *S3LoggingServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*S3LoggingServiceAttributeHandler) Read added in v0.20.3

func (*S3LoggingServiceAttributeHandler) Register added in v0.20.3

type SFTPServiceAttributeHandler added in v0.20.3

type SFTPServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*SFTPServiceAttributeHandler) Process added in v0.20.3

func (h *SFTPServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*SFTPServiceAttributeHandler) Read added in v0.20.3

func (*SFTPServiceAttributeHandler) Register added in v0.20.3

type ScalyrServiceAttributeHandler added in v0.20.3

type ScalyrServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*ScalyrServiceAttributeHandler) Process added in v0.20.3

func (h *ScalyrServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*ScalyrServiceAttributeHandler) Read added in v0.20.3

func (*ScalyrServiceAttributeHandler) Register added in v0.20.3

type ServiceAttributeDefinition added in v0.20.3

type ServiceAttributeDefinition interface {
	// Register add the attribute to the resource schema.
	Register(s *schema.Resource) error

	// Read refreshes the attribute state against the Fastly API.
	Read(d *schema.ResourceData, s *gofastly.ServiceDetail, conn *gofastly.Client) error

	// Process creates or updates the attribute against the Fastly API.
	Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

	// HasChange returns whether the state of the attribute has changed against Terraform stored state.
	HasChange(d *schema.ResourceData) bool

	// MustProcess returns whether we must process the resource (usually HasChange==true but allowing exceptions).
	// For example: at present, the settings attributeHandler (block_fastly_service_v1_settings.go) must process when
	// default_ttl==0 and it is the initialVersion - as well as when default_ttl or default_host have changed.
	MustProcess(d *schema.ResourceData, initialVersion bool) bool
}

ServiceAttributeDefinition provides an interface for service attributes. We compose a service resource out of attribute objects to allow us to construct both the VCL and Compute service resources from common components.

func NewServiceACL added in v0.20.3

func NewServiceBackend added in v0.20.3

func NewServiceBackend(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceBigQueryLogging added in v0.20.3

func NewServiceBigQueryLogging(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceBlobStorageLogging added in v0.20.3

func NewServiceBlobStorageLogging(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceCacheSetting added in v0.20.3

func NewServiceCacheSetting(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceCondition added in v0.20.3

func NewServiceCondition(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceDictionary added in v0.20.3

func NewServiceDictionary(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceDirector added in v0.20.3

func NewServiceDirector(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceDomain added in v0.20.3

func NewServiceDomain(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceDynamicSnippet added in v0.20.3

func NewServiceDynamicSnippet(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceGCSLogging added in v0.20.3

func NewServiceGCSLogging(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceGzip added in v0.20.3

func NewServiceHTTPSLogging added in v0.20.3

func NewServiceHTTPSLogging(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceHeader added in v0.20.3

func NewServiceHeader(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceHealthCheck added in v0.20.3

func NewServiceHealthCheck(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLogentries added in v0.20.3

func NewServiceLogentries(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingCloudfiles added in v0.20.3

func NewServiceLoggingCloudfiles(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingDatadog added in v0.20.3

func NewServiceLoggingDatadog(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingDigitalOcean added in v0.20.3

func NewServiceLoggingDigitalOcean(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingElasticSearch added in v0.20.3

func NewServiceLoggingElasticSearch(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingFTP added in v0.20.3

func NewServiceLoggingFTP(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingGooglePubSub added in v0.20.3

func NewServiceLoggingGooglePubSub(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingHeroku added in v0.20.3

func NewServiceLoggingHeroku(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingHoneycomb added in v0.20.3

func NewServiceLoggingHoneycomb(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingKafka added in v0.20.3

func NewServiceLoggingKafka(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingLoggly added in v0.20.3

func NewServiceLoggingLoggly(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingLogshuttle added in v0.20.3

func NewServiceLoggingLogshuttle(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingNewRelic added in v0.20.3

func NewServiceLoggingNewRelic(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingOpenstack added in v0.20.3

func NewServiceLoggingOpenstack(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingSFTP added in v0.20.3

func NewServiceLoggingSFTP(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceLoggingScalyr added in v0.20.3

func NewServiceLoggingScalyr(sa ServiceMetadata) ServiceAttributeDefinition

func NewServicePackage added in v0.20.3

func NewServicePackage(sa ServiceMetadata) ServiceAttributeDefinition

func NewServicePaperTrail added in v0.20.3

func NewServicePaperTrail(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceRequestSetting added in v0.20.3

func NewServiceRequestSetting(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceResponseObject added in v0.20.3

func NewServiceResponseObject(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceS3Logging added in v0.20.3

func NewServiceS3Logging(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceSettings added in v0.20.3

func NewServiceSettings() ServiceAttributeDefinition

func NewServiceSnippet added in v0.20.3

func NewServiceSnippet(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceSplunk added in v0.20.3

func NewServiceSplunk(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceSumologic added in v0.20.3

func NewServiceSumologic(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceSyslog added in v0.20.3

func NewServiceSyslog(sa ServiceMetadata) ServiceAttributeDefinition

func NewServiceVCL added in v0.20.3

func NewServiceWAF added in v0.20.3

type ServiceDefinition added in v0.20.3

type ServiceDefinition interface {
	// GetType returns whether this is a VCL or Compute service.
	GetType() string

	// GetAttributeHandler returns the list of attributes/handlers supported by this service.
	GetAttributeHandler() []ServiceAttributeDefinition
}

ServiceDefinition defines the data model for service definitions There are two types of service: VCL and Compute. This interface specifies the data object from which service resources are constructed.

type ServiceMetadata added in v0.20.3

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

ServiceMetadata provides a container to pass service attributes into an Attribute handler.

type SetDiff added in v0.20.3

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

SetDiff diffs two sets using a key to identify which elements have been added, changed, removed or not modified.

This object compares sets using Terraform's schema.Set methods (e.g. Difference() and Intersection()) so that the same differences displayed to the user are honoured here.

SetDiff however is able to tell if two elements from two distinct sets have the same key. This is useful to detect that an element should be updated instead of recreated on the remote server.

func NewSetDiff added in v0.20.3

func NewSetDiff(keyFunc KeyFunc) *SetDiff

NewSetDiff creates a new SetDiff with a provided KeyFunc.

func (*SetDiff) Diff added in v0.20.3

func (h *SetDiff) Diff(oldSet, newSet *schema.Set) (*DiffResult, error)

Diff diffs two Set objects and returns a DiffResult object containing the diffs.

The DiffResult object will contain the elements from newSet on the Modified field.

func (*SetDiff) Filter added in v0.21.3

func (h *SetDiff) Filter(modified map[string]interface{}, oldSet *schema.Set) map[string]interface{}

Filter filters out unmodified fields of a Set elements map data structure by ranging over the original data and comparing each field against the new data.

type SettingsServiceAttributeHandler added in v0.20.3

type SettingsServiceAttributeHandler struct {
}

func (*SettingsServiceAttributeHandler) HasChange added in v0.20.3

func (*SettingsServiceAttributeHandler) MustProcess added in v0.20.3

func (h *SettingsServiceAttributeHandler) MustProcess(d *schema.ResourceData, initialVersion bool) bool

If the requested default_ttl is 0, and this is the first version being created, HasChange will return false, but we need to set it anyway, so ensure we update the settings in that case.

func (*SettingsServiceAttributeHandler) Process added in v0.20.3

func (h *SettingsServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*SettingsServiceAttributeHandler) Read added in v0.20.3

func (*SettingsServiceAttributeHandler) Register added in v0.20.3

type SnippetServiceAttributeHandler added in v0.20.3

type SnippetServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*SnippetServiceAttributeHandler) Process added in v0.20.3

func (h *SnippetServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*SnippetServiceAttributeHandler) Read added in v0.20.3

func (*SnippetServiceAttributeHandler) Register added in v0.20.3

type SplunkServiceAttributeHandler added in v0.20.3

type SplunkServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*SplunkServiceAttributeHandler) Process added in v0.20.3

func (h *SplunkServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*SplunkServiceAttributeHandler) Read added in v0.20.3

func (*SplunkServiceAttributeHandler) Register added in v0.20.3

type SumologicServiceAttributeHandler added in v0.20.3

type SumologicServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*SumologicServiceAttributeHandler) Process added in v0.20.3

func (h *SumologicServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*SumologicServiceAttributeHandler) Read added in v0.20.3

func (*SumologicServiceAttributeHandler) Register added in v0.20.3

type SyslogServiceAttributeHandler added in v0.20.3

type SyslogServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*SyslogServiceAttributeHandler) Process added in v0.20.3

func (h *SyslogServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*SyslogServiceAttributeHandler) Read added in v0.20.3

func (*SyslogServiceAttributeHandler) Register added in v0.20.3

type VCLLoggingAttributes added in v0.20.3

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

type VCLServiceAttributeHandler added in v0.20.3

type VCLServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*VCLServiceAttributeHandler) Process added in v0.20.3

func (h *VCLServiceAttributeHandler) Process(d *schema.ResourceData, latestVersion int, conn *gofastly.Client) error

func (*VCLServiceAttributeHandler) Read added in v0.20.3

func (*VCLServiceAttributeHandler) Register added in v0.20.3

type WAFDeploymentChecker added in v0.20.3

type WAFDeploymentChecker struct {
	Timeout    time.Duration
	Delay      time.Duration
	MinTimeout time.Duration
	Check      WAFDeploymentStatusCheck
}

type WAFDeploymentStatusCheck added in v0.20.3

type WAFDeploymentStatusCheck func(wafID string, version int) (*gofastly.WAFVersion, error)

type WAFServiceAttributeHandler added in v0.20.3

type WAFServiceAttributeHandler struct {
	*DefaultServiceAttributeHandler
}

func (*WAFServiceAttributeHandler) Process added in v0.20.3

func (h *WAFServiceAttributeHandler) Process(d *schema.ResourceData, serviceVersion int, conn *gofastly.Client) error

func (*WAFServiceAttributeHandler) Read added in v0.20.3

func (*WAFServiceAttributeHandler) Register added in v0.20.3

Source Files

Jump to

Keyboard shortcuts

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