CDK override bind when using LambdaIntegration
问题 When using LambdaIntegration class the bind function add permission to the lambda automatically: bind(method) { super.bind(method); const principal = new iam.ServicePrincipal('apigateway.amazonaws.com'); const desc = `${method.restApi.node.uniqueId}.${method.httpMethod}.${method.resource.path.replace(/\//g, '.')}`; this.handler.addPermission(`ApiPermission.${desc}`, { principal, scope: method, sourceArn: method.methodArn, }); // add permission to invoke from the console if (this.enableTest) {