Skip to content

Commit 7401cb6

Browse files
authored
Normalization: Checking --event-buffer-size on old dbt crashed entrypoint.sh (#12924)
* Fixed checking --event-buffer-size on old dbt crashed entrypoint.sh Signed-off-by: Sergey Chvalyuk <[email protected]>
1 parent 5ddef86 commit 7401cb6

File tree

4 files changed

+11
-4
lines changed

4 files changed

+11
-4
lines changed

airbyte-integrations/bases/base-normalization/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,5 @@ WORKDIR /airbyte
2828
ENV AIRBYTE_ENTRYPOINT "/airbyte/entrypoint.sh"
2929
ENTRYPOINT ["/airbyte/entrypoint.sh"]
3030

31-
LABEL io.airbyte.version=0.2.0
31+
LABEL io.airbyte.version=0.2.1
3232
LABEL io.airbyte.name=airbyte/normalization

airbyte-integrations/bases/base-normalization/entrypoint.sh

+8-2
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ function config_cleanup() {
1717
rm -f "${CONFIG_FILE}"
1818
}
1919

20+
function check_dbt_event_buffer_size() {
21+
ret=0
22+
dbt --help | grep -E -- '--event-buffer-size' && return
23+
ret=1
24+
}
25+
2026
PROJECT_DIR=$(pwd)
2127

2228
# How many commits should be downloaded from git to view history of a branch
@@ -116,8 +122,8 @@ function main() {
116122

117123
# We don't run dbt 1.0.x on all destinations (because their plugins don't support it yet)
118124
# So we need to only pass `--event-buffer-size` if it's supported by DBT.
119-
dbt --help | grep -E -- '--event-buffer-size'
120-
if [ $? -eq 0 ]; then
125+
check_dbt_event_buffer_size
126+
if [ "$ret" -eq 0 ]; then
121127
echo -e "\nDBT >=1.0.0 detected; using 10K event buffer size\n"
122128
dbt_additional_args="--event-buffer-size=10000"
123129
else

airbyte-workers/src/main/java/io/airbyte/workers/normalization/NormalizationRunnerFactory.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
public class NormalizationRunnerFactory {
1515

1616
public static final String BASE_NORMALIZATION_IMAGE_NAME = "airbyte/normalization";
17-
public static final String NORMALIZATION_VERSION = "0.2.0";
17+
public static final String NORMALIZATION_VERSION = "0.2.1";
1818

1919
static final Map<String, ImmutablePair<String, DefaultNormalizationRunner.DestinationType>> NORMALIZATION_MAPPING =
2020
ImmutableMap.<String, ImmutablePair<String, DefaultNormalizationRunner.DestinationType>>builder()

docs/understanding-airbyte/basic-normalization.md

+1
Original file line numberDiff line numberDiff line change
@@ -352,6 +352,7 @@ Therefore, in order to "upgrade" to the desired normalization version, you need
352352

353353
| Airbyte Version | Normalization Version | Date | Pull Request | Subject |
354354
|:----------------| :--- | :--- | :--- | :--- |
355+
| | 0.2.1 | 2022-05-17 | [\#12924](https://github.com/airbytehq/airbyte/pull/12924) | Fixed checking --event-buffer-size on old dbt crashed entrypoint.sh |
355356
| | 0.2.0 | 2022-05-15 | [\#12745](https://github.com/airbytehq/airbyte/pull/12745) | Snowflake: add datetime without timezone |
356357
| | 0.1.78 | 2022-05-06 | [\#12305](https://github.com/airbytehq/airbyte/pull/12305) | Mssql: use NVARCHAR and datetime2 by default |
357358
| 0.36.2-alpha | 0.1.77 | 2022-04-19 | [\#12064](https://github.com/airbytehq/airbyte/pull/12064) | Add support redshift SUPER type |

0 commit comments

Comments
 (0)