-
Notifications
You must be signed in to change notification settings - Fork 4.6k
🐛Destination-dynamodb: enforce ssl connection #18672
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🐛Destination-dynamodb: enforce ssl connection #18672
Conversation
NOTE
|
/test connector=connectors/destination-dynamodb
Build PassedTest summary info:
|
...dynamodb/src/main/java/io/airbyte/integrations/destination/dynamodb/DynamodbDestination.java
Outdated
Show resolved
Hide resolved
NOTE
|
/test connector=connectors/destination-dynamodb
Build PassedTest summary info:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Affected Connector ReportNOTE
|
Connector | Version | Changelog | Publish |
---|
- See "Actionable Items" below for how to resolve warnings and errors.
✅ Destinations (1)
Connector | Version | Changelog | Publish |
---|---|---|---|
destination-dynamodb |
0.1.7 |
✅ | ✅ |
- See "Actionable Items" below for how to resolve warnings and errors.
Actionable Items
(click to expand)
Category | Status | Actionable Item |
---|---|---|
Version | ❌ mismatch |
The version of the connector is different from its normal variant. Please bump the version of the connector. |
⚠ doc not found |
The connector does not seem to have a documentation file. This can be normal (e.g. basic connector like source-jdbc is not published or documented). Please double-check to make sure that it is not a bug. |
|
Changelog | ⚠ doc not found |
The connector does not seem to have a documentation file. This can be normal (e.g. basic connector like source-jdbc is not published or documented). Please double-check to make sure that it is not a bug. |
❌ changelog missing |
There is no chnagelog for the current version of the connector. If you are the author of the current version, please add a changelog. | |
Publish | ⚠ not in seed |
The connector is not in the seed file (e.g. source_definitions.yaml ), so its publication status cannot be checked. This can be normal (e.g. some connectors are cloud-specific, and only listed in the cloud seed file). Please double-check to make sure that it is not a bug. |
❌ diff seed version |
The connector exists in the seed file, but the latest version is not listed there. This usually means that the latest version is not published. Please use the /publish command to publish the latest version. |
/publish connector=connectors/destination-dynamodb
if you have connectors that successfully published but failed definition generation, follow step 4 here |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I am reading the code correctly, this change will always enforce HTTPS for DynamoDB. However, we only need this to happen in Airbyte Cloud and we want to continue allowing non-SSL connections in Open Source. @ryankfu could you walk @etsybaev through how to introduce strict encrypt variant to an existing destination connector w/o creating a new image and how to add the check only in Airbyte Cloud scope (what you did for destination-S3)?
Hi @etsybaev, in case you weren't aware there's a PR that captures a very similar change here. Basically the main pieces that would help to separate this functionality so that it only affects cloud is to:
If you have any questions regarding the work, let's set up a quick 1:1 to knowledge share. For most context the Also note that you'd probably want to create a new |
...main/java/io/airbyte/integrations/destination/dynamodb/DynamodbDestinationStrictEncrypt.java
Outdated
Show resolved
Hide resolved
.../java/io/airbyte/integrations/destination/dynamodb/DynamodbDestinationStrictEncryptTest.java
Outdated
Show resolved
Hide resolved
.../java/io/airbyte/integrations/destination/dynamodb/DynamodbDestinationStrictEncryptTest.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor code reusability changes but overall looks good
} | ||
|
||
/** | ||
* Test that check failes if user is using a non-secure (http) connection |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: type for fails
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated, thanks
build.gradle
Outdated
@@ -156,7 +156,7 @@ spotless { | |||
format 'styling', { | |||
target createSpotlessTarget(['**/*.yaml', '**/*.json']) | |||
|
|||
prettier() | |||
// prettier() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How come you've commented out the prettier()
method? presume this is simply pretty printing but regardless doesn't seem relevant to this PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Accidentally committed. Already rolled back.
How this could come? There was a version bumping change in check-style some time ago. Since then some linux users started seeing issues with importing and refreshing project in IntellijIdea but still works when executing build from console. I raised that issue but it seems like the author was busy with other tasks and wasn't going to switch back to his changes. I tried to check it in my free time and found that the issue comes from "prettier" and then stuck. Also found a few similar issues raised on the internet but without answers. So since then every time I have to comment it while working with code and then uncomment from time to time to run "./gradlew --no-daemon format --scan" command to format code and then comment it back.
Here is what the issue looks like for me in IntellijIdea when I refresh gradle project with uncommented Prettier
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good, there's a minor nit and a question regarding a prettier()
method getting commented out in build.gradle
/test connector=connectors/destination-dynamodb
Build PassedTest summary info:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@etsybaev now that you've made the changes to enforce SSL only in Cloud you also need to bump the version again and publish the newer version before merging
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved assuming you'll bump the connector version and publish ;)
/test connector=connectors/destination-dynamodb
Build PassedTest summary info:
|
/publish connector=connectors/destination-dynamodb
if you have connectors that successfully published but failed definition generation, follow step 4 here |
What
Users are able to use a non-secure connection
How
Updated check method to enforce SSL connection.
🚨 User Impact 🚨
No breaking changes expected
Pre-merge Checklist
Expand the relevant checklist and delete the others.
New Connector
Community member or Airbyter
airbyte_secret
./gradlew :airbyte-integrations:connectors:<name>:integrationTest
.README.md
bootstrap.md
. See description and examplesdocs/integrations/<source or destination>/<name>.md
including changelog. See changelog exampledocs/integrations/README.md
airbyte-integrations/builds.md
Airbyter
If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.
/test connector=connectors/<name>
command is passing/publish
command described hereUpdating a connector
Community member or Airbyter
airbyte_secret
./gradlew :airbyte-integrations:connectors:<name>:integrationTest
.README.md
bootstrap.md
. See description and examplesdocs/integrations/<source or destination>/<name>.md
including changelog. See changelog exampleAirbyter
If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.
/test connector=connectors/<name>
command is passing/publish
command described hereConnector Generator
-scaffold
in their name) have been updated with the latest scaffold by running./gradlew :airbyte-integrations:connector-templates:generator:testScaffoldTemplates
then checking in your changesTests
Unit
Put your unit tests output here.
Integration
Put your integration tests output here.
Acceptance
Put your acceptance tests output here.