11
11
* and limitations under the License.
12
12
*/
13
13
import * as path from 'path' ;
14
- import { Duration , Aws , Annotations } from 'aws-cdk-lib' ;
14
+ import { Duration , Aws } from 'aws-cdk-lib' ;
15
15
import * as appsync from 'aws-cdk-lib/aws-appsync' ;
16
16
import * as cognito from 'aws-cdk-lib/aws-cognito' ;
17
17
import * as ec2 from 'aws-cdk-lib/aws-ec2' ;
@@ -158,7 +158,7 @@ export interface QaAppsyncOpensearchProps {
158
158
* Optional. Allows to provide custom lambda code
159
159
* and settings instead of the existing
160
160
*/
161
- readonly sagemakerEndpointName ?: string
161
+ readonly sagemakerEndpointName ?: string ;
162
162
}
163
163
164
164
/**
@@ -465,13 +465,13 @@ export class QaAppsyncOpensearch extends BaseClass {
465
465
resources : [ '*' ] ,
466
466
} ) ,
467
467
) ;
468
-
469
- if ( props . sagemakerEndpointName ) {
468
+
469
+ if ( props . sagemakerEndpointName ) {
470
470
question_answering_function_role . addToPolicy (
471
471
new iam . PolicyStatement ( {
472
472
effect : iam . Effect . ALLOW ,
473
473
actions : [ 'sagemaker:InvokeEndpoint' ] ,
474
- resources : [ 'arn:' + Aws . PARTITION + ':sagemaker:' + Aws . ACCOUNT_ID + ':endpoint/*' ] ,
474
+ resources : [ 'arn:' + Aws . PARTITION + ':sagemaker:' + Aws . ACCOUNT_ID + ':endpoint/*' ] ,
475
475
} ) ,
476
476
) ;
477
477
}
@@ -554,7 +554,7 @@ export class QaAppsyncOpensearch extends BaseClass {
554
554
true ,
555
555
) ;
556
556
557
- const sagemakerEndpointNamestr = props . sagemakerEndpointName || ""
557
+ const sagemakerEndpointNamestr = props . sagemakerEndpointName || '' ;
558
558
const construct_docker_lambda_props = {
559
559
code : lambda . DockerImageCode . fromImageAsset (
560
560
path . join (
@@ -578,7 +578,7 @@ export class QaAppsyncOpensearch extends BaseClass {
578
578
OPENSEARCH_DOMAIN_ENDPOINT : opensearch_helper . getOpenSearchEndpoint ( props ) ,
579
579
OPENSEARCH_INDEX : props . openSearchIndexName ,
580
580
OPENSEARCH_SECRET_ID : SecretId ,
581
- SAGEMAKER_ENDPOINT :sagemakerEndpointNamestr
581
+ SAGEMAKER_ENDPOINT : sagemakerEndpointNamestr ,
582
582
} ,
583
583
...( props . lambdaProvisionedConcurrency && {
584
584
currentVersionOptions : {
0 commit comments