Skip to content

Conversation

@patchwork01
Copy link
Collaborator

@patchwork01 patchwork01 commented Nov 7, 2025

Make sure you have checked all steps below.

Issue

  • My PR fully resolves the following issues. I've referenced an issue in the PR title, for example "Issue 1234 - My
    Feature". Note that before an issue is finished, you can still make a pull request by raising a separate issue
    for your progress.

Tests

  • My PR adds the following tests based on our test strategy OR does not need testing for this extremely good reason:
    • Ran deployAll in AWS
    • Ran quick system test suite in AWS
    • Torn down instances

Documentation

@patchwork01 patchwork01 force-pushed the 5869-instance-cdk-stack branch from d2b4d9a to 2c948ee Compare November 10, 2025 08:43
@patchwork01 patchwork01 marked this pull request as ready for review November 10, 2025 11:05
@patchwork01 patchwork01 marked this pull request as draft November 10, 2025 11:06
@patchwork01 patchwork01 force-pushed the 5869-instance-cdk-stack branch from b7e4732 to 9e76ac8 Compare November 10, 2025 11:53
@patchwork01 patchwork01 changed the base branch from 5390-use-artefacts-cdk-app to 6001-rename-stacks November 10, 2025 11:56
@patchwork01 patchwork01 changed the base branch from 6001-rename-stacks to 6005-separate-instance-deployment-from-stack November 10, 2025 16:05
@patchwork01 patchwork01 changed the base branch from 6005-separate-instance-deployment-from-stack to 6013-refactor-tracking-dead-letters November 11, 2025 16:02
@patchwork01 patchwork01 force-pushed the 5869-instance-cdk-stack branch from c1ea861 to b7d0d54 Compare November 12, 2025 08:59
@patchwork01 patchwork01 marked this pull request as ready for review November 12, 2025 13:17
@patchwork01 patchwork01 added needs-reviewer Pull requests that need a reviewer to be assigned pr-stacked-top A stacked pull request that we don't want to merge into its target until the target PR is merged labels Nov 12, 2025
@rtjd6554 rtjd6554 self-assigned this Nov 13, 2025
@rtjd6554 rtjd6554 removed the needs-reviewer Pull requests that need a reviewer to be assigned label Nov 13, 2025
import sleeper.core.properties.instance.InstanceProperties;

/**
* Deploys an instance of Sleeper, including any configured optional stacks. Does not create Sleeper tables. If the
Copy link
Collaborator

@rtjd6554 rtjd6554 Nov 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be better to have the "Does not create Sleeper tables" on a seperate line to make it more visible.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

DeployInstanceConfiguration configuration = DeployInstanceConfiguration.fromLocalConfiguration(propertiesFile);
return builder(configuration.getInstanceProperties(), s3Client, dynamoClient)
.tableProperties(configuration.getTableProperties())
.validateProperties(!"false".equalsIgnoreCase(context.tryGetContext("validate")))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are inverted logic checks for this line and the one below the best for this here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems necessary in order to handle the case where the context variable is unset. If we had validateProperties("true".equalsIgnoreCase(context.tryGetContext("validate"))), then it would default to false if the context variable is unset. We want it to default to true. It'd be good if there was a nicer way to do this.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've avoided the inverted booleans.

Copy link
Collaborator

@rtjd6554 rtjd6554 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small queries to answer

@rtjd6554 rtjd6554 assigned patchwork01 and unassigned rtjd6554 Nov 13, 2025
Base automatically changed from 6013-refactor-tracking-dead-letters to develop November 13, 2025 10:25
@patchwork01 patchwork01 removed their assignment Nov 13, 2025
@patchwork01 patchwork01 added needs-reviewer Pull requests that need a reviewer to be assigned and removed pr-stacked-top A stacked pull request that we don't want to merge into its target until the target PR is merged labels Nov 13, 2025
@patchwork01 patchwork01 removed the needs-reviewer Pull requests that need a reviewer to be assigned label Nov 13, 2025
@patchwork01 patchwork01 merged commit fcd8a9a into develop Nov 13, 2025
3 checks passed
@patchwork01 patchwork01 deleted the 5869-instance-cdk-stack branch November 13, 2025 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Deploy Sleeper as part of a larger CDK app

4 participants