Documentation ¶
Index ¶
Constants ¶
const ProviderName = "azurerm"
ProviderName is the provider that this package implements
const RegistryName = "registry.terraform.io/hashicorp/azurerm"
RegistryName is the fully qualified name under which this provider is stored in the registry.
Variables ¶
var ( // ErrNotSupportedService reports that the service is not supported ErrNotSupportedService = errors.New("not supported service") )
var TerraformProviderInitializer = terraform.ProviderInitializer{ MatchNames: []string{ProviderName, RegistryName}, Provider: func(values map[string]interface{}) (terraform.Provider, error) { return azurermtf.NewProvider(ProviderName) }, }
TerraformProviderInitializer is a terraform.ProviderInitializer that initializes the default GCP provider.
Functions ¶
func DefaultFilter ¶
func DefaultFilter(_ *price.WithProduct) bool
DefaultFilter ingests all the records without filtering.
func MinimalFilter ¶
func MinimalFilter(pp *price.WithProduct) bool
MinimalFilter only ingests the supported records, skipping those that would never be used.
func ServiceStrings ¶
func ServiceStrings() []string
ServiceStrings returns a slice of all String values of the enum
Types ¶
type Ingester ¶
type Ingester struct {
// contains filtered or unexported fields
}
Ingester is the entity that will manage the ingestion process from AzureRM
func NewIngester ¶
NewIngester returns a new Ingester for AzureRM for the specified service and region (ex: francecentral) with the given options
type IngestionFilter ¶
type IngestionFilter func(pp *price.WithProduct) bool
IngestionFilter allows control over what pricing data is ingested. Given a price.WithProduct the function returns true if the record should be ingested, false if it should be skipped.
type Option ¶
type Option func(ing *Ingester)
Option is used to configure the Ingester.
func WithEndpoint ¶
WithEndpoint sets a custom endpoint to user for the api calls
func WithIngestionFilter ¶
func WithIngestionFilter(filter IngestionFilter) Option
WithIngestionFilter sets a custom IngestionFilter to control which pricing data records should be ingested.
type Service ¶
type Service uint8
Service is the type defining the services
func ServiceString ¶
ServiceString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.
func (Service) IsAService ¶
IsAService returns "true" if the value is listed in the enum definition. "false" otherwise