How to use where clause in Knex
Create refunds with Stripe
Load HTML with Cheerio
How to send POST request with Axios
Find intersection of array in Lodash
Powered by Official white Bloop logo with a period

Terms / Privacy / Search / Support

  • import { App, Stack } from '@aws-cdk/core';
    import * as ec2 from '@aws-cdk/aws-ec2';
    import * as ecs from '@aws-cdk/aws-ecs';
    import * as ecsPatterns from '@aws-cdk/aws-ecs-patterns';
    import * as cxapi from '@aws-cdk/cx-api';
    import * as path from 'path';
    
    const app = new App();
    
    const stack = new Stack(app, 'aws-ecs-patterns-queue');
    stack.node.setContext(cxapi.ECS_REMOVE_DEFAULT_DESIRED_COUNT, true);
    
    const vpc = new ec2.Vpc(stack, 'VPC', {
      maxAzs: 2,
    });
    
    new ecsPatterns.QueueProcessingFargateService(stack, 'QueueProcessingService', {
      vpc,
      memoryLimitMiB: 512,
      image: new ecs.AssetImage(path.join(__dirname, '..', 'sqs-reader')),
    });
    
    Docs
  • // The code below shows an example of how to instantiate this type.
    // The values are placeholders you should change.
    import * as cx_api from '@aws-cdk/cx-api';
    import * as pipelines from '@aws-cdk/pipelines';
    
    declare const cloudFormationStackArtifact: cx_api.CloudFormationStackArtifact;
    const stackDeployment = pipelines.StackDeployment.fromArtifact(cloudFormationStackArtifact);
    
    Docs
  • import { HttpAlbIntegration } from '@aws-cdk/aws-apigatewayv2-integrations';
    
    declare const lb: elbv2.ApplicationLoadBalancer;
    const listener = lb.addListener('listener', { port: 80 });
    listener.addTargets('target', {
      port: 80,
    });
    
    const httpEndpoint = new apigwv2.HttpApi(this, 'HttpProxyPrivateApi', {
      defaultIntegration: new HttpAlbIntegration('DefaultIntegration', listener, {
        parameterMapping: new apigwv2.ParameterMapping()
          .appendHeader('header2', apigwv2.MappingValue.requestHeader('header1'))
          .removeHeader('header1'),
      }),
    });
    
    Docs
  • import { HttpAlbIntegration } from '@aws-cdk/aws-apigatewayv2-integrations';
    
    declare const lb: elbv2.ApplicationLoadBalancer;
    const listener = lb.addListener('listener', { port: 80 });
    listener.addTargets('target', {
      port: 80,
    });
    
    const httpEndpoint = new apigwv2.HttpApi(this, 'HttpProxyPrivateApi', {
      defaultIntegration: new HttpAlbIntegration('DefaultIntegration', listener, {
        parameterMapping: new apigwv2.ParameterMapping().custom('myKey', 'myValue'),
      }),
    });
    
    Docs
  • // The code below shows an example of how to instantiate this type.
    // The values are placeholders you should change.
    import * as cloud_assembly_schema from '@aws-cdk/cloud-assembly-schema';
    import * as cx_api from '@aws-cdk/cx-api';
    
    declare const cloudAssembly: cx_api.CloudAssembly;
    
    const cloudArtifact = cx_api.CloudArtifact.fromManifest(cloudAssembly, 'MyCloudArtifact', {
      type: cloud_assembly_schema.ArtifactType.NONE,
    
      // the properties below are optional
      dependencies: ['dependencies'],
      displayName: 'displayName',
      environment: 'environment',
      metadata: {
        metadataKey: [{
          type: 'type',
    
          // the properties below are optional
          data: 'data',
          trace: ['trace'],
        }],
      },
      properties: {
        templateFile: 'templateFile',
    
        // the properties below are optional
        assumeRoleArn: 'assumeRoleArn',
        assumeRoleExternalId: 'assumeRoleExternalId',
        bootstrapStackVersionSsmParameter: 'bootstrapStackVersionSsmParameter',
        cloudFormationExecutionRoleArn: 'cloudFormationExecutionRoleArn',
        parameters: {
          parametersKey: 'parameters',
        },
        requiresBootstrapStackVersion: 123,
        stackName: 'stackName',
        stackTemplateAssetObjectUrl: 'stackTemplateAssetObjectUrl',
        tags: {
          tagsKey: 'tags',
        },
        terminationProtection: false,
        validateOnSynth: false,
      },
    });
    
    Docs
  • Powered by Official black Bloop logo with a period
    download the IDE extension

    View other examples