package runtime
import "github.com/Azure/azure-sdk-for-go/sdk/azcore/arm/runtime"
Index ¶
- Constants
- func NewPoller(pollerID string, finalState string, resp *http.Response, pl pipeline.Pipeline, eu func(*http.Response) error) (*pollers.Poller, error)
- func NewPollerFromResumeToken(pollerID string, token string, pl pipeline.Pipeline, eu func(*http.Response) error) (*pollers.Poller, error)
- func NewRPRegistrationPolicy(endpoint string, cred azcore.Credential, o *RegistrationOptions) policy.Policy
- type Provider
- type ProviderResponse
- type RegistrationOptions
Constants ¶
const ( // LogRPRegistration entries contain information specific to the automatic registration of an RP. // Entries of this classification are written IFF the policy needs to take any action. LogRPRegistration log.Classification = "RPRegistration" )
Functions ¶
func NewPoller ¶
func NewPoller(pollerID string, finalState string, resp *http.Response, pl pipeline.Pipeline, eu func(*http.Response) error) (*pollers.Poller, error)
NewPoller creates a Poller based on the provided initial response. pollerID - a unique identifier for an LRO. it's usually the client.Method string.
func NewPollerFromResumeToken ¶
func NewPollerFromResumeToken(pollerID string, token string, pl pipeline.Pipeline, eu func(*http.Response) error) (*pollers.Poller, error)
NewPollerFromResumeToken creates a Poller from a resume token string. pollerID - a unique identifier for an LRO. it's usually the client.Method string.
func NewRPRegistrationPolicy ¶
func NewRPRegistrationPolicy(endpoint string, cred azcore.Credential, o *RegistrationOptions) policy.Policy
NewRPRegistrationPolicy creates a policy object configured using the specified endpoint, credentials and options. The policy controls if an unregistered resource provider should automatically be registered. See https://aka.ms/rps-not-found for more information. Pass nil to accept the default options; this is the same as passing a zero-value options.
Types ¶
type Provider ¶
type Provider struct { // The provider ID. ID *string `json:"id,omitempty"` // The namespace of the resource provider. Namespace *string `json:"namespace,omitempty"` // The registration policy of the resource provider. RegistrationPolicy *string `json:"registrationPolicy,omitempty"` // The registration state of the resource provider. RegistrationState *string `json:"registrationState,omitempty"` }
Provider - Resource provider information.
type ProviderResponse ¶
type ProviderResponse struct { // Resource provider information. Provider *Provider // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
ProviderResponse is the response envelope for operations that return a Provider type.
type RegistrationOptions ¶
type RegistrationOptions struct { // MaxAttempts is the total number of times to attempt automatic registration // in the event that an attempt fails. // The default value is 3. // Set to a value less than zero to disable the policy. MaxAttempts int // PollingDelay is the amount of time to sleep between polling intervals. // The default value is 15 seconds. // A value less than zero means no delay between polling intervals (not recommended). PollingDelay time.Duration // PollingDuration is the amount of time to wait before abandoning polling. // The default valule is 5 minutes. // NOTE: Setting this to a small value might cause the policy to prematurely fail. PollingDuration time.Duration // HTTPClient sets the transport for making HTTP requests. HTTPClient policy.Transporter // Retry configures the built-in retry policy behavior. Retry policy.RetryOptions // Telemetry configures the built-in telemetry policy behavior. Telemetry policy.TelemetryOptions // Logging configures the built-in logging policy behavior. Logging policy.LogOptions }
RegistrationOptions configures the registration policy's behavior. All zero-value fields will be initialized with their default values.
Source Files ¶
policy_register_rp.go poller.go
- Version
- v0.19.0
- Published
- Aug 26, 2021
- Platform
- linux/amd64
- Imports
- 19 packages
- Last checked
- 29 minutes ago –
Tools for package owners.