Class StageBase
Base class for an ApiGateway Stage.
Inherited Members
Namespace: Amazon.CDK.AWS.APIGateway
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public abstract class StageBase : Resource, IStage, IResource
Syntax (vb)
Public MustInherit Class StageBase
Inherits Resource
Implements IStage, IResource
Synopsis
Constructors
StageBase(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
StageBase(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
StageBase(Construct, String, IResourceProps) |
Properties
RestApi | RestApi to which this stage is associated. |
StageArn | Returns the resource ARN for this stage:. |
StageName | Name of this stage. |
Methods
AddApiKey(String, IApiKeyOptions) | Add an ApiKey to this stage. |
Metric(String, IMetricOptions) | Returns the given named metric for this stage. |
MetricCacheHitCount(IMetricOptions) | Metric for the number of requests served from the API cache in a given period. |
MetricCacheMissCount(IMetricOptions) | Metric for the number of requests served from the backend in a given period, when API caching is enabled. |
MetricClientError(IMetricOptions) | Metric for the number of client-side errors captured in a given period. |
MetricCount(IMetricOptions) | Metric for the total number API requests in a given period. |
MetricIntegrationLatency(IMetricOptions) | Metric for the time between when API Gateway relays a request to the backend and when it receives a response from the backend. |
MetricLatency(IMetricOptions) | The time between when API Gateway receives a request from a client and when it returns a response to the client. |
MetricServerError(IMetricOptions) | Metric for the number of server-side errors captured in a given period. |
UrlForPath(String) | Returns the invoke URL for a certain path. |
Constructors
StageBase(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected StageBase(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
StageBase(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected StageBase(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
StageBase(Construct, String, IResourceProps)
protected StageBase(Construct scope, string id, IResourceProps props = null)
Parameters
- scope Constructs.Construct
- id System.String
- props IResourceProps
Properties
RestApi
RestApi to which this stage is associated.
public abstract IRestApi RestApi { get; }
Property Value
StageArn
Returns the resource ARN for this stage:.
public virtual string StageArn { get; }
Property Value
System.String
Remarks
arn:aws:apigateway:{region}::/restapis/{restApiId}/stages/{stageName}
Note that this is separate from the execute-api ARN for methods and resources within this stage.
Attribute: true
StageName
Name of this stage.
public abstract string StageName { get; }
Property Value
System.String
Methods
AddApiKey(String, IApiKeyOptions)
Add an ApiKey to this stage.
public virtual IApiKey AddApiKey(string id, IApiKeyOptions options = null)
Parameters
- id System.String
- options IApiKeyOptions
Returns
Metric(String, IMetricOptions)
Returns the given named metric for this stage.
public virtual Metric Metric(string metricName, IMetricOptions props = null)
Parameters
- metricName System.String
- props IMetricOptions
Returns
MetricCacheHitCount(IMetricOptions)
Metric for the number of requests served from the API cache in a given period.
public virtual Metric MetricCacheHitCount(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
Default: - sum over 5 minutes
MetricCacheMissCount(IMetricOptions)
Metric for the number of requests served from the backend in a given period, when API caching is enabled.
public virtual Metric MetricCacheMissCount(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
Default: - sum over 5 minutes
MetricClientError(IMetricOptions)
Metric for the number of client-side errors captured in a given period.
public virtual Metric MetricClientError(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
Default: - sum over 5 minutes
MetricCount(IMetricOptions)
Metric for the total number API requests in a given period.
public virtual Metric MetricCount(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
Default: - sample count over 5 minutes
MetricIntegrationLatency(IMetricOptions)
Metric for the time between when API Gateway relays a request to the backend and when it receives a response from the backend.
public virtual Metric MetricIntegrationLatency(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
Default: - average over 5 minutes.
MetricLatency(IMetricOptions)
The time between when API Gateway receives a request from a client and when it returns a response to the client.
public virtual Metric MetricLatency(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
The latency includes the integration latency and other API Gateway overhead.
Default: - average over 5 minutes.
MetricServerError(IMetricOptions)
Metric for the number of server-side errors captured in a given period.
public virtual Metric MetricServerError(IMetricOptions props = null)
Parameters
- props IMetricOptions
Returns
Remarks
Default: - sum over 5 minutes
UrlForPath(String)
Returns the invoke URL for a certain path.
public virtual string UrlForPath(string path = null)
Parameters
- path System.String
The resource path.
Returns
System.String