diff --git a/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/.jsiirc.json b/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/.jsiirc.json new file mode 100644 index 0000000000000..9fbccc2314fc9 --- /dev/null +++ b/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/.jsiirc.json @@ -0,0 +1,13 @@ +{ + "targets": { + "dotnet": { + "namespace": "Amazon.CDK.AwsApigatewayv2Authorizers" + }, + "java": { + "package": "software.amazon.awscdk.aws_apigatewayv2_authorizers" + }, + "python": { + "module": "aws_cdk.aws_apigatewayv2_authorizers" + } + } +} diff --git a/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/README.md b/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/README.md index 2cef622ea1381..a633d395ce08a 100644 --- a/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/README.md +++ b/packages/aws-cdk-lib/aws-apigatewayv2-authorizers/README.md @@ -13,6 +13,9 @@ - [WebSocket APIs](#websocket-apis) - [Lambda Authorizer](#lambda-authorizer) - [IAM Authorizers](#iam-authorizer) +- [Import Issues](#import-issues) + - [DotNet Namespace](#dotnet-namespace) + - [Java Package](#java-package) ## Introduction @@ -280,3 +283,26 @@ user.attachInlinePolicy(new iam.Policy(this, 'AllowInvoke', { })); ``` + +## Import Issues + +`jsiirc.json` file is missing during the stablization process of this module, which caused import issues for DotNet and Java users who attempt to use this module. Unfortunately, to guarantee backward compatibility, we cannot simply correct the namespace for DotNet or package for Java. The following outlines the workaround. + +### DotNet Namespace + +Instead of the conventional namespace `Amazon.CDK.AWS.Apigatewayv2.Authorizers`, you would need to use the following namespace: + +```cs +using Amazon.CDK.AwsApigatewayv2Authorizers;; +``` + +### Java Package + +Instead of conventional package `import software.amazon.awscdk.services.apigatewayv2_authorizers.*`, you would need to use the following package: + +```java +import software.amazon.awscdk.aws_apigatewayv2_authorizers.*; + +// If you want to import a specific construct +import software.amazon.awscdk.aws_apigatewayv2_authorizers.WebSocketIamAuthorizer; +``` diff --git a/packages/aws-cdk-lib/aws-apigatewayv2-integrations/.jsiirc.json b/packages/aws-cdk-lib/aws-apigatewayv2-integrations/.jsiirc.json new file mode 100644 index 0000000000000..6ad7dc9b48919 --- /dev/null +++ b/packages/aws-cdk-lib/aws-apigatewayv2-integrations/.jsiirc.json @@ -0,0 +1,13 @@ +{ + "targets": { + "dotnet": { + "namespace": "Amazon.CDK.AwsApigatewayv2Integrations" + }, + "java": { + "package": "software.amazon.awscdk.aws_apigatewayv2_integrations" + }, + "python": { + "module": "aws_cdk.aws_apigatewayv2_integrations" + } + } +} diff --git a/packages/aws-cdk-lib/aws-apigatewayv2-integrations/README.md b/packages/aws-cdk-lib/aws-apigatewayv2-integrations/README.md index 4df90c5836218..9fd07172268e6 100644 --- a/packages/aws-cdk-lib/aws-apigatewayv2-integrations/README.md +++ b/packages/aws-cdk-lib/aws-apigatewayv2-integrations/README.md @@ -11,6 +11,9 @@ - [WebSocket APIs](#websocket-apis) - [Lambda WebSocket Integration](#lambda-websocket-integration) - [AWS WebSocket Integration](#aws-websocket-integration) +- [Import Issues](#import-issues) + - [DotNet Namespace](#dotnet-namespace) + - [Java Package](#java-package) ## HTTP APIs @@ -307,4 +310,27 @@ webSocketApi.addRoute('$connect', { ``` You can also set additional properties to change the behavior of your integration, such as `contentHandling`. -See [Working with binary media types for WebSocket APIs](https://docs.aws.amazon.com/apigateway/latest/developerguide/websocket-api-develop-binary-media-types.html). \ No newline at end of file +See [Working with binary media types for WebSocket APIs](https://docs.aws.amazon.com/apigateway/latest/developerguide/websocket-api-develop-binary-media-types.html). + +## Import Issues + +`jsiirc.json` file is missing during the stablization process of this module, which caused import issues for DotNet and Java users who attempt to use this module. Unfortunately, to guarantee backward compatibility, we cannot simply correct the namespace for DotNet or package for Java. The following outlines the workaround. + +### DotNet Namespace + +Instead of the conventional namespace `Amazon.CDK.AWS.Apigatewayv2.Integrations`, you would need to use the following namespace: + +```cs +using Amazon.CDK.AwsApigatewayv2Integrations; +``` + +### Java Package + +Instead of conventional package `import software.amazon.awscdk.services.apigatewayv2_integrations.*`, you would need to use the following package: + +```java +import software.amazon.awscdk.aws_apigatewayv2_integrations.*; + +// If you want to import a specific construct +import software.amazon.awscdk.aws_apigatewayv2_integrations.WebSocketAwsIntegration; +```