Skip to content

Commit

Permalink
Merge pull request #183 from mbonig/feat/adhoc
Browse files Browse the repository at this point in the history
exposing adhoc
  • Loading branch information
mbonig authored Jan 14, 2022
2 parents cebbc2c + 189a043 commit 3832ab4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
1 change: 1 addition & 0 deletions API.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ Name | Type | Description
-----|------|-------------
**adhocConnections** | <code>[aws_ec2.Connections](#aws-cdk-lib-aws-ec2-connections)</code> | <span></span>
**connections** | <code>[aws_ec2.Connections](#aws-cdk-lib-aws-ec2-connections)</code> | The network connections associated with this resource.
**adhocHandler**? | <code>[aws_lambda.IFunction](#aws-cdk-lib-aws-lambda-ifunction)</code> | The underlying Lambda handler function for making adhoc commands against the database.<br/>__*Optional*__

### Methods

Expand Down
10 changes: 7 additions & 3 deletions src/DatabaseScript.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,13 @@ export interface DatabaseScriptProps {

export class DatabaseScript extends Construct implements IConnectable {

private handler: aws_lambda.IFunction;
private adhocHandler?: aws_lambda.IFunction;
private providerLayer: aws_lambda.LayerVersion;
/**
* The underlying Lambda handler function for making adhoc commands against the database.
* Undefined unless 'enableAdhoc' is true
*/
adhocHandler?: aws_lambda.IFunction;
private readonly handler: aws_lambda.IFunction;
private readonly providerLayer: aws_lambda.LayerVersion;

constructor(scope: Construct, id: string, props: DatabaseScriptProps) {
super(scope, id);
Expand Down

0 comments on commit 3832ab4

Please sign in to comment.