Skip to content
This repository was archived by the owner on Jul 9, 2024. It is now read-only.

Commit bad5114

Browse files
zxkanegithub-actions
and
github-actions
authored
fix: explicitly pin neptune engine version to 1.2.0.1 (#962)
* fix: explicitly pin neptune version to 1.2.0.1 * chore: self mutation Signed-off-by: github-actions <github-actions@github.com> Signed-off-by: github-actions <github-actions@github.com> Co-authored-by: github-actions <github-actions@github.com>
1 parent b652f6e commit bad5114

File tree

9 files changed

+55
-50
lines changed

9 files changed

+55
-50
lines changed

.projen/deps.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.projen/tasks.json

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.projenrc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ const cdkAlphaDeps = [
1616
'@aws-cdk/aws-glue-alpha',
1717
'@aws-cdk/aws-lambda-python-alpha',
1818
'@aws-cdk/aws-neptune-alpha',
19-
].map(dep => `${dep}@2.0.0-alpha.11`);
19+
].map(dep => `${dep}@^2.51.1-alpha.0`);
2020
const awsSDKDeps = [
2121
'@aws-sdk/client-glue',
2222
'@aws-sdk/client-secrets-manager',

package.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/lib/dashboard-stack.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
HttpMethod,
88
HttpStage,
99
} from '@aws-cdk/aws-apigatewayv2-alpha';
10-
import { LambdaProxyIntegration } from '@aws-cdk/aws-apigatewayv2-integrations-alpha';
10+
import { HttpLambdaIntegration } from '@aws-cdk/aws-apigatewayv2-integrations-alpha';
1111
import {
1212
GraphqlApi,
1313
Schema,
@@ -538,7 +538,7 @@ export class TransactionDashboardStack extends NestedStack {
538538
'GeneratorStartIntegration',
539539
{
540540
apiId: httpApi.httpApiId,
541-
integrationType: HttpIntegrationType.LAMBDA_PROXY,
541+
integrationType: HttpIntegrationType.AWS_PROXY,
542542
integrationSubtype: 'StepFunctions-StartExecution',
543543
connectionType: HttpConnectionType.INTERNET,
544544
credentialsArn: apiRole.roleArn,
@@ -595,8 +595,7 @@ export class TransactionDashboardStack extends NestedStack {
595595
},
596596
],
597597
});
598-
const tokenFnIntegration = new LambdaProxyIntegration({
599-
handler: tokenFn,
598+
const tokenFnIntegration = new HttpLambdaIntegration('TokenInteg', tokenFn, {
600599
payloadFormatVersion: PayloadFormatVersion.VERSION_2_0,
601600
});
602601
httpApi.addRoutes({

src/lib/stack.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { ClusterParameterGroup, ParameterGroup, DatabaseCluster, InstanceType, IDatabaseCluster } from '@aws-cdk/aws-neptune-alpha';
1+
import { ClusterParameterGroup, ParameterGroup, DatabaseCluster, InstanceType, IDatabaseCluster, EngineVersion, ParameterGroupFamily } from '@aws-cdk/aws-neptune-alpha';
22
import { RemovalPolicy, Stack, StackProps, Duration, CfnParameter, CfnOutput, CfnResource } from 'aws-cdk-lib';
33
import { GatewayVpcEndpointAwsService, Vpc, FlowLogDestination, SubnetType, IVpc, SecurityGroup } from 'aws-cdk-lib/aws-ec2';
44
import { Role, ServicePrincipal } from 'aws-cdk-lib/aws-iam';
@@ -177,13 +177,15 @@ export class FraudDetectionStack extends Stack {
177177
neptune_enable_audit_log: '1',
178178
neptune_streams: '1',
179179
},
180+
family: ParameterGroupFamily.NEPTUNE_1_2,
180181
});
181182

182183
const dbParams = new ParameterGroup(this, 'DBParamGroup', {
183184
description: 'Neptune DB Param Group',
184185
parameters: {
185186
neptune_query_timeout: '600000',
186187
},
188+
family: ParameterGroupFamily.NEPTUNE_1_2,
187189
});
188190

189191
const neptuneRole = new Role(this, 'NeptuneBulkLoadRole', {
@@ -224,6 +226,7 @@ export class FraudDetectionStack extends Stack {
224226
removalPolicy: RemovalPolicy.DESTROY,
225227
backupRetention: Duration.days(7),
226228
securityGroups: [graphDBSG],
229+
engineVersion: new EngineVersion('1.2.0.1'),
227230
});
228231
graphDBCluster.node.findAll().filter(c => (c as CfnDBInstance).cfnOptions)
229232
.forEach(c => (c as CfnDBInstance).autoMinorVersionUpgrade = true);

test/stack.test.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,12 +88,16 @@ describe('fraud detection stack test suite', () => {
8888
test('Neptune cluster and dbs created', () => {
8989

9090
Template.fromStack(stack).hasResourceProperties('AWS::Neptune::DBClusterParameterGroup', {
91-
Family: 'neptune1',
91+
Family: 'neptune1.2',
9292
Parameters: {
9393
neptune_enable_audit_log: '1',
9494
},
9595
});
9696

97+
Template.fromStack(stack).hasResourceProperties('AWS::Neptune::DBParameterGroup', {
98+
Family: 'neptune1.2',
99+
});
100+
97101
Template.fromStack(stack).hasResource('AWS::Neptune::DBCluster', {
98102
Properties: {
99103
AssociatedRoles: [
@@ -116,6 +120,7 @@ describe('fraud detection stack test suite', () => {
116120
Port: 8182,
117121
BackupRetentionPeriod: 7,
118122
StorageEncrypted: true,
123+
EngineVersion: '1.2.0.1',
119124
VpcSecurityGroupIds: [
120125
{
121126
'Fn::GetAtt': [

test/training-stack.test.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -628,7 +628,6 @@ describe('training stack test suite', () => {
628628
Statement: [
629629
{
630630
Action: [
631-
'glue:BatchDeletePartition',
632631
'glue:BatchGetPartition',
633632
'glue:GetPartition',
634633
'glue:GetPartitions',
@@ -692,7 +691,6 @@ describe('training stack test suite', () => {
692691
},
693692
{
694693
Action: [
695-
'glue:BatchDeletePartition',
696694
'glue:BatchGetPartition',
697695
'glue:GetPartition',
698696
'glue:GetPartitions',

yarn.lock

Lines changed: 24 additions & 24 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)