-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* support cached builds for base -> base-java -> snowflake * use plugin for image building * fix matching on COPY from * remove docker.gradle * tmp commit * update connectors * finish rest of build files * fix ide errors * more build fixes * clean up * clean up for new soruces * fix spotless * fix flake problems * add recommended empty file * python caching * fixes upon review * clean up docker and build test files * clean up python * clean up * fix integration test dependencies * fix standard tests * fix * remove symlink * re-add requirements to fix normalizatioon build * fix symlink * fix dumbest build problem of all * add missing integration test def * fix missing dep * remove class exclusion * move trim so null source versions are allowed * rename map * fix hardcoded value * remove unnecessary dep * use dashes for salesforce package name * fix typo * DRY and fix test image name * Fix edit * assert string is not empty * build integration test image only for integrationTest * move code generator to tools and rename docker build tasks * make source test depend on integration test build, not the other way * remove guard because the docker build should exist before the integrationtest is applied * remove comment * DRY up airbyte-source-test * fix plugin compilation * add missing dependency * rename getTaggedImage to getDevTaggedImage * fix test vs main docker build bug
- Loading branch information
Showing
64 changed files
with
703 additions
and
701 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,9 +2,9 @@ | |
.idea | ||
*.iml | ||
build | ||
!tools/build | ||
.DS_Store | ||
data | ||
.dockerversions | ||
|
||
secrets | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,19 @@ | ||
project.ext.pyModule = 'airbyte_protocol' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
plugins { | ||
id 'airbyte-python' | ||
id 'airbyte-docker' | ||
} | ||
|
||
airbytePython { | ||
moduleDirectory 'airbyte_protocol' | ||
} | ||
|
||
task generateProtocolClassFilesWithoutLicense(type: Exec) { | ||
environment 'ROOT_DIR', rootDir.absolutePath | ||
commandLine 'bin/generate-protocol-files.sh' | ||
dependsOn ':airbyte-integrations:bases:airbyte-protocol:code-generator:buildImage' | ||
dependsOn ':tools:code-generator:airbyteDocker' | ||
} | ||
|
||
// todo: figure out dependencies | ||
task generateProtocolClassFiles(dependsOn: [generateProtocolClassFilesWithoutLicense, rootProject.spotlessPython]) | ||
rootProject.spotlessPython.mustRunAfter(generateProtocolClassFilesWithoutLicense) | ||
|
||
rootProject.build.dependsOn generateProtocolClassFiles |
2 changes: 0 additions & 2 deletions
2
airbyte-integrations/bases/airbyte-protocol/code-generator/build.gradle
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,13 @@ | ||
plugins { | ||
id 'java-library' | ||
id 'airbyte-docker' | ||
} | ||
|
||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
|
||
dependencies { | ||
implementation 'commons-cli:commons-cli:1.4' | ||
|
||
implementation project(':airbyte-config:models') | ||
implementation project(':airbyte-protocol:models') | ||
} | ||
|
||
buildImage.dependsOn ':airbyte-integrations:bases:base:buildImage' | ||
implementation files(project(':airbyte-integrations:bases:base').airbyteDocker.outputs) | ||
} |
19 changes: 9 additions & 10 deletions
19
airbyte-integrations/bases/base-normalization/build.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,12 @@ | ||
project.ext.pyModule = 'normalization' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
plugins { | ||
id 'airbyte-docker' | ||
id 'airbyte-python' | ||
} | ||
|
||
task unitTest(type: PythonTask){ | ||
command = "setup.py test" | ||
airbytePython { | ||
moduleDirectory 'normalization' | ||
} | ||
|
||
unitTest.dependsOn(installReqs) | ||
build.dependsOn(unitTest) | ||
build.dependsOn ':airbyte-integrations:bases:airbyte-protocol:build' | ||
buildImage.dependsOn ':airbyte-integrations:bases:base:buildImage' | ||
buildImage.dependsOn ':airbyte-integrations:bases:airbyte-protocol:buildImage' | ||
dependencies { | ||
implementation files(project(':airbyte-integrations:bases:airbyte-protocol').airbyteDocker.outputs) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
airbyte-integrations/bases/base-python-test/base_python_test/base_python_test
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
project.ext.pyModule = 'base_python_test' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
plugins { | ||
id 'airbyte-docker' | ||
id 'airbyte-python' | ||
} | ||
|
||
build.dependsOn(':airbyte-integrations:bases:base-python:build') | ||
buildImage.dependsOn(':airbyte-integrations:bases:base-python:buildImage') | ||
airbytePython { | ||
moduleDirectory 'base_python_test' | ||
} | ||
|
||
dependencies { | ||
implementation files(project(':airbyte-integrations:bases:base-python').airbyteDocker.outputs) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,13 @@ | ||
project.ext.pyModule = 'base_python' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
plugins { | ||
id 'airbyte-docker' | ||
id 'airbyte-python' | ||
} | ||
|
||
build.dependsOn ':airbyte-integrations:bases:airbyte-protocol:build' | ||
buildImage.dependsOn ':airbyte-integrations:bases:base:buildImage' | ||
buildImage.dependsOn ':airbyte-integrations:bases:airbyte-protocol:buildImage' | ||
airbytePython { | ||
moduleDirectory 'base_python' | ||
} | ||
|
||
dependencies { | ||
implementation files(project(':airbyte-integrations:bases:airbyte-protocol').airbyteDocker.outputs) | ||
implementation files(project(':airbyte-integrations:bases:base').airbyteDocker.outputs) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,12 @@ | ||
project.ext.pyModule = 'base_singer' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
plugins { | ||
id 'airbyte-docker' | ||
id 'airbyte-python' | ||
} | ||
|
||
build.dependsOn ':airbyte-integrations:bases:airbyte-protocol:build' | ||
build.dependsOn ':airbyte-integrations:bases:base-python:build' | ||
buildImage.dependsOn ':airbyte-integrations:bases:base-python:buildImage' | ||
airbytePython { | ||
moduleDirectory 'base_singer' | ||
} | ||
|
||
dependencies { | ||
implementation files(project(':airbyte-integrations:bases:base-python').airbyteDocker.outputs) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
plugins { | ||
id 'airbyte-docker' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 6 additions & 9 deletions
15
airbyte-integrations/connector-templates/java-destination/build.gradle.hbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,19 @@ | ||
plugins { | ||
id 'application' | ||
id 'airbyte-docker' | ||
id 'airbyte-integration-test-java' | ||
} | ||
|
||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/integration-test.gradle') | ||
application { | ||
mainClass = 'io.airbyte.integrations.destination.{{snakeCase name}}.{{properCase name}}Destination' | ||
} | ||
|
||
dependencies { | ||
implementation project(':airbyte-config:models') | ||
implementation project(':airbyte-protocol:models') | ||
implementation project(':airbyte-integrations:bases:base-java') | ||
|
||
integrationTestImplementation project(':airbyte-integrations:bases:destination-test-lib') | ||
} | ||
|
||
application { | ||
mainClass = 'io.airbyte.integrations.destination.{{snakeCase name}}.{{properCase name}}Destination' | ||
implementation files(project(':airbyte-integrations:bases:base-java').airbyteDocker.outputs) | ||
} | ||
|
||
buildImage.dependsOn(assemble) | ||
buildImage.dependsOn(':airbyte-integrations:bases:base-java:buildImage') | ||
integrationTest.dependsOn(buildImage) |
36 changes: 8 additions & 28 deletions
36
airbyte-integrations/connector-templates/source-python/build.gradle.hbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,13 @@ | ||
project.ext.pyModule = 'source_{{snakeCase name}}' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/test-image.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/integration-test.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/standard-source-test-python.gradle') | ||
|
||
|
||
standardSourceTestPython { | ||
ext { | ||
imageName = "${extractImageName(project.file('Dockerfile'))}:dev" | ||
pythonContainerName = "${extractImageName(project.file('Dockerfile.test'))}:dev" | ||
} | ||
plugins { | ||
id 'airbyte-python' | ||
id 'airbyte-docker' | ||
id 'airbyte-source-test' | ||
} | ||
|
||
task installTestDeps(type: PythonTask){ | ||
module = "pip" | ||
command = "install .[tests]" | ||
airbytePython { | ||
moduleDirectory 'source_{{snakeCase name}}' | ||
} | ||
|
||
task unitTest(type: PythonTask){ | ||
module = "pytest" | ||
command = "unit_tests" | ||
dependencies { | ||
implementation files(project(':airbyte-integrations:bases:base-python').airbyteDocker.outputs) | ||
} | ||
|
||
unitTest.dependsOn(installTestDeps) | ||
build.dependsOn(unitTest) | ||
build.dependsOn ':airbyte-integrations:bases:base-python-test:build' | ||
buildImage.dependsOn ':airbyte-integrations:bases:base-python:buildImage' | ||
integrationTest.dependsOn(buildImage) | ||
|
||
buildTestImage.dependsOn ':airbyte-integrations:bases:base-python-test:buildImage' | ||
standardSourceTestPython.dependsOn(buildTestImage) |
37 changes: 8 additions & 29 deletions
37
airbyte-integrations/connector-templates/source-singer/build.gradle.hbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,13 @@ | ||
project.ext.pyModule = 'source_{{snakeCase name}}_singer' | ||
apply from: rootProject.file('tools/gradle/commons/integrations/python.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/image.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/test-image.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/integration-test.gradle') | ||
apply from: rootProject.file('tools/gradle/commons/integrations/standard-source-test-python.gradle') | ||
|
||
|
||
standardSourceTestPython { | ||
ext { | ||
imageName = "${extractImageName(project.file('Dockerfile'))}:dev" | ||
pythonContainerName = "${extractImageName(project.file('Dockerfile.test'))}:dev" | ||
} | ||
plugins { | ||
id 'airbyte-python' | ||
id 'airbyte-docker' | ||
id 'airbyte-source-test' | ||
} | ||
|
||
task installTestDeps(type: PythonTask){ | ||
module = "pip" | ||
command = "install .[tests]" | ||
airbytePython { | ||
moduleDirectory 'source_{{snakeCase name}}_singer' | ||
} | ||
|
||
task unitTest(type: PythonTask){ | ||
module = "pytest" | ||
command = "unit_tests" | ||
dependencies { | ||
implementation files(project(':airbyte-integrations:bases:base-singer').airbyteDocker.outputs) | ||
} | ||
|
||
unitTest.dependsOn(installTestDeps) | ||
build.dependsOn(unitTest) | ||
build.dependsOn ':airbyte-integrations:bases:base-python-test:build' | ||
|
||
buildImage.dependsOn ':airbyte-integrations:bases:base-singer:buildImage' | ||
buildTestImage.dependsOn ':airbyte-integrations:bases:base-python-test:buildImage' | ||
|
||
integrationTest.dependsOn(buildImage) | ||
standardSourceTestPython.dependsOn(buildTestImage) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.