1
0
mirror of synced 2026-01-04 00:04:25 -05:00
Commit Graph

73 Commits

Author SHA1 Message Date
LiRen Tu
779c39c088 Copy job attempt state to configs database (#7219)
* Add migration to create latest state table

* Log migration name

* Expose db variables to airbyte-db

* Implement migration

* Fix migration test

* temp

* Rebase on master

* Save state in temporal (#7253)

* Copy state to airbyte_configs table

* Add standard sync state

* Move state methods to config repository

* Add unit tests

* Fix unit tests

* Register standard sync state in migration

* Add comment

* Use config model instead of json node

* Add comments

* Remove unnecessary method

* Fix migration query

* Remove unused config database

* Move persist statement and log the call

* Update dev doc

* Add unit tests for sync workflow

Co-authored-by: Charles <giardina.charles@gmail.com>
2021-10-25 17:08:08 -07:00
Jared Rhizor
f82c9ce90e temporarily re-add webapp papercups/openreplay vars (#7015) 2021-10-13 10:28:08 -07:00
Artem Astapenko
fea3bf6798 Remove papercups (#6955)
* Remove papercups

* Remove support chat
2021-10-13 15:59:28 +03:00
Artem Astapenko
d0d92011e6 Remove openreplay (#6940)
* Remove openreplay

* Add lock file. Fix openreplay import
2021-10-13 15:17:59 +03:00
Jared Rhizor
f88b8313a8 add the ability to use a secret persistence (#6415)
* test exposing secrets in configrepo

* fix local persistence sql

* working propagation, just without check/discover replacements and without feature flagging

* switch if statement

* set up secret persistence for google secrets manager

* add ttl-based secret persistence for check/discover usage in the future

* set up check/discover to pass around necessary parts

* Revert "set up check/discover to pass around necessary parts"

This reverts commit 489d2d5f5d.

* working updates + check/discover operations

* fix additional configs created on deletion

* clean up docker compose file

* finish up configrepo

* make api path optional

* clean up schedulerapp and local testing persistence

* make optional in the worker app

* add rest of feature flagging

* fmt

* remove completed todo

* fix refactoring typo

* fix another refactoring typo

* fix compilation error in test case

* fix tests

* final cleanups

* fix conditional

* address a couple of things

* add hydrator interface

* add replaceAllConfigs

* specfetcher handling

* fix constructor

* fix test

* fix typo

* fix merge build error

* remove extra config

* fix integration test

* fix final piece
2021-09-29 11:53:29 -07:00
Jared Rhizor
c7d8055731 split scheduler and worker (#5737)
* docker-compose split of scheduler and worker

* fix heartbeat location bug + add support for kubernetes

* use two workers in integration tests

* capture logs in AirbyteTestContainer

* add waiting

* rename to make it easier to review

* rename module

* fix remaining conflicts

* allow configuring max workers of each type and document usage

* fix build

* remove comment

* add worker resource requiremetns

* try to fix for connector build

* fix regression in biuld

* add env comments for SUBMITTER_NUM_THREADS

* Update airbyte-workers/src/main/java/io/airbyte/workers/WorkerApp.java

Co-authored-by: Davin Chia <davinchia@gmail.com>

* Update airbyte-workers/src/main/java/io/airbyte/workers/temporal/TemporalPool.java

Co-authored-by: Davin Chia <davinchia@gmail.com>

* merge temporalpool into workerapp

* output docker system info

* move check to before

* remove unnecessary parts of the patch

* could this be the problem? i thought i added this

* show disk usage

* add print statements

* add pruning

* fix prune option

* use force

Co-authored-by: Davin Chia <davinchia@gmail.com>
2021-09-08 11:27:32 -07:00
LiRen Tu
36ebf95b32 Revert "add data volume again (#5715)" (#5719) 2021-08-30 08:56:34 -07:00
Marcos Marx
32c2a6b1ad add data volume again (#5715) 2021-08-27 18:04:37 -03:00
Jared Rhizor
164d13866e allow scheduler and server to run on separate nodes (#5506)
* allow scheduler and server to run on separate nodes

* re-add workspace mount for docker compose only

* remove stacktrace printing

* add affinity testing components

* reorder mounts

* just try a two node cluster

* add waiting log line

* seed containers are now axed

* remove unused var

* add comment

* rename to integration-test
2021-08-26 15:51:16 -04:00
LiRen Tu
37c53db4bb Integrate database with Flyway and jOOQ (#5543)
* Implement database migrator

* Add unit tests

* Add RUN_FLYWAY_MIGRATION variable

* Run flyway migration in server

* Add db migration info api

* Add db migration migrate api

* Add unit test

* Remove base airbyte migration

* Implement migration dev helper

* Dry and format code

* Fix url

* Use camel case

* Add db migration page

* Add button to run migration

* Update migration table

* Fix resource warning

* Update readme

* Revert package-lock changes

* Update readme

* Address simple frontend review comments

* Add java migration template (not completed yet)

* Add method to generate migration file

* Set up jooq code generation

* Check in generated code

* Move generated code to build directory

* Exclude db dev center methods in gradle

* Update airbyte-db/README.md

Co-authored-by: Davin Chia <davinchia@gmail.com>

* Mark getMigrator as private

Co-authored-by: Davin Chia <davinchia@gmail.com>

* Address review comments

* Format code

* Fix format output column name

* Remove config persistence builder

* Remove dumpSchemaToFile method

* Run baseline in server

* Rename info to list

Co-authored-by: Charles <giardina.charles@gmail.com>

* Rename executeDbMigrationInfo to listMigrations

Co-authored-by: Charles <giardina.charles@gmail.com>

* Rename RUN_FLYWAY_MIGRATION

* Clean up migration apis

* Remove redundant version comparison

* Refactor db migrator

* Add migration file location parameter back

This is necessary because other databases may exist in a different module and follow different patterns.

* Fix build

* Generate jooq code in gradle

* Remove frontend changes

* Remove testing migration

Co-authored-by: Davin Chia <davinchia@gmail.com>
Co-authored-by: Charles <giardina.charles@gmail.com>
2021-08-25 04:34:19 -07:00
Davin Chia
9dd05d4790 🔪 Get rid of retries within an attempt. (#5570)
See https://airbytehq.slack.com/archives/C019WEENQRM/p1629383779144300 for more details.

TLDR:
Retrying within an attempt is confusing for a UX perspective (we already have attempts), does not provides more value from a retries perspective (we already have attempts) and inefficient from a resource perspective (hogs up api limits and compute/memory resources).

Follow up ticket: #5571
2021-08-24 10:11:20 +08:00
Vladimir remar
fe8f7faf8d 🎉 Set max_sync_timeout in days by env vars (#5297)
* Set max_sync_timeout in days by env vars

* update name var to MAX_SYNC_TIMEOUT_DAYS
2021-08-23 18:38:20 -03:00
LiRen Tu
79b8fd5c12 Remove seed generation task and seed from YAML files (#5335)
## What
- This is the first PR for #4890.
  - This PR does not remove the config volume.
  - This PR does not mount the directories for the local connectors.
- Resolves #5373.

## How
-  Previously the seed container copies the configs to the storage root, it may take some time for the operation to complete and for the `CONFIG_DIR` to show up. So we cannot infer anything based on the existence of this directory. Now this seed generation step has been removed. So we can tell immediately whether `CONFIG_DIR` exists or not.
  - If `CONFIG_DIR` exists, it means the user has just migrated Airbyte from an old version that uses this file system config persistence.
  - Otherwise, we can seed the config persistence from the YAML files.
2021-08-17 11:40:06 -07:00
Vladimir remar
9e5054b891 Set MAX_RETRIES and MAX_SYNC_JOB_ATTEMPTS by env vars (#5098)
* Set MAX_RETRIES and MAX_SYNC_JOB_ATTEMPTS by env vars
2021-08-02 16:33:18 +08:00
Davin Chia
196cbd51df Add worker env to docker deploy to silence any logs about picking default values. (#5068) 2021-07-29 17:06:48 +08:00
Artem Astapenko
660fca03e2 Add openreplay variable (#4844) 2021-07-20 07:13:03 +07:00
Davin Chia
8034aa5e57 Make number of Concurrent Jobs configurable. (#4687) 2021-07-19 20:17:59 +08:00
LiRen Tu
e577b4987e 🎉 Migrate config persistence to database (#4670)
* Implement db config persistence

* Fix database readiness check

* Reduce logging noise

* Setup config database in config persistence factory

* Update documentation

* Load seed from yaml files

* Refactor config persistence factory

* Add one more test to mimic migration

* Remove unnecessary changes

* Run code formatter

* Update placeholder env values

* Set default config database parameters in docker compose

Co-authored-by: Christophe Duong <christophe.duong@gmail.com>

* Default setupDatabase to false

* Rename variable

* Set default config db parameters for server

* Remove config db parameters from the env file

* Remove unnecessary environment statements

* Hide config persistence factory (#4772)

* Remove CONFIG_DATABASE_HOST

* Use builder in the test

* Simplify config persistence builder

* Clarify config db connection readiness

* Format code

* Add logging

* Fix typo

Co-authored-by: Christophe Duong <christophe.duong@gmail.com>

* Add a config_id only index

* Reuse record insertion code

* Add id field name to config schema

* Support data loading from legacy config schemas

* Log missing logs in migration test

* Move airbyte configs table to separate directory

* Update exception message

* Dump specific tables from the job database

* Remove postgres specific uuid extension

* Comment out future branch

* Default configs db variables to empty

When defaulting them to the jobs db variables, it somehow does not work.

* Log inserted config records

* Log all db write operations

* Add back config db variables in env file to mute warnings

* Log connection exception to debug flaky e2e test

* Leave config db variables empty

`.env` file does not support variable expansion.

Co-authored-by: Christophe Duong <christophe.duong@gmail.com>
Co-authored-by: Charles <giardina.charles@gmail.com>
2021-07-19 03:52:40 -07:00
Davin Chia
d0b994926b 🐛 Stub out the GCP Env Var in Docker to prevent noisy and harmless errors. (#4642)
* Add this to prevent noisy errors.
2021-07-09 16:37:48 +08:00
George Claireaux
2ca4f9441b 🐛 Kubernetes: Fix server starting up before Temporal ready to operate (#4567)
* refactor waitForTemporalServerAndLog into TemporalUtils

* remove use of docker-compose-wait
2021-07-07 09:51:00 +01:00
Duk Panhavad
a7196d40c9 Add LOG_LEVEL for Temporal docker (#4532) 2021-07-05 15:26:30 +08:00
Davin Chia
fd5c5be352 Inject LOG_LEVEL for docker. (#4498) 2021-07-02 16:57:12 +08:00
Christophe Duong
8b6093ce61 Configure kube pod resources for workers/syncs (#4381)
* Configure kube pod resources for workers/syncs
2021-07-01 12:25:14 +02:00
Subodh Kant Chaturvedi
4b6465d853 fix versioning for server in docker compose (#4430) 2021-06-30 13:05:33 +05:30
Subodh Kant Chaturvedi
0e194fb331 use old seed mount (#4413) 2021-06-30 01:21:48 +05:30
Subodh Kant Chaturvedi
887752822c 🎉 introduce automatic migration at the startup of server for docker environment (#3980)
* introduce automatic migration at the startup of server

* handle versions with non-zero patch

* it works!!!

* add dummy data

* cleanup orphan configs

* add more assertions

* format + add comments

* move migration acceptance test to acceptance test directory

* add automatic migration test to the build

* address review comments

* missed out on these

* format

* add more assertions

* format

* fix test

* format

* use default port for temporal

* move seed to server + introduce atomice replacement for config

* make tests better

* remove unwanted changes

* move atomic replacement logic behind persistence + pass path to latest seeds

* format

* update seeds

* review comments

* update seeds

* merge latest seeds with configs

* fix bug around latest seed

* update seed

* update seed

* seeds should be populated by separate container

* address review comment + change latest definition url

* update seeds

* format

* update seed references

* update seed

* update seed

* update seed

* update seed references

* update seed references + add Migration Acceptance Test

* update seed container in kube + disable automatic migration for kube + update docs

* update docs

* address review comments from Michel

* update doc

* temporary commmit to see if build becomes green

* delete seeds from airbyte config + undo temp commit
2021-06-29 23:50:00 +05:30
Jared Rhizor
0e5ec6a1b6 revert log-breaking change and add comments (#4303) 2021-06-23 11:27:35 -07:00
Jared Rhizor
38ed70c816 remove s3 logging from docker-compose and update upgrade docs (#4278) 2021-06-23 08:12:55 -07:00
Jared Rhizor
27ae6f182e fix build (#4250) 2021-06-21 11:17:05 -07:00
Christophe Duong
6b112b0bd7 Write how to connect to external db (#4211) 2021-06-21 12:30:52 +02:00
Davin Chia
e60f5369e0 🎉 Kube Logs support stored and reading from S3. (#4053)
Use Log4j2 appender to support routing logs to S3.

Create LogClient to support reading from S3.

Some clean up of the Log4j2 xml variables.

Several dependency changes to be more explicit when configuring jackson.
2021-06-19 12:15:15 +08:00
Jared Rhizor
34a695829e add fullstory (#4171)
* add fullstory

* fixes

* fix
2021-06-16 19:57:23 -07:00
Subodh Kant Chaturvedi
d0d337839c docker: limit the log size to 500MB (#3702) 2021-05-28 15:07:02 +05:30
Jared Rhizor
581b27335f 🎉 allow users to access both the api and webapp from the same port (#3603)
* single port v2

* fix upstream location

* add kube support

* fix .env.dev

* set INTERNAL_API_HOST for kube
2021-05-26 13:57:34 -07:00
Jared Rhizor
42ecf1f4cd restart containers if they fail automatically (#3423) 2021-05-17 10:03:19 -07:00
Christophe Duong
57dd38b4e6 Revert default value for API_URL (#2947) 2021-04-19 18:38:46 +02:00
Jared Rhizor
5216ea78d6 stop creating two databases (#2841)
* stop creating two databases

* remove line completely
2021-04-11 22:58:40 -07:00
Charles
470b7a3863 bugfix: pass local_root (#2839) 2021-04-09 15:29:38 -07:00
Christophe Duong
03fdd65319 Job Failure Notification (#2706)
* Add webhook to workspace for notifications when sync fail
* API to test notifications webhook (#2809)
2021-04-09 21:56:22 +02:00
Charles
cac6808af8 Remove outdated docs about running scheduler and server with gradle run (#2676) 2021-04-08 14:39:39 -07:00
Charles
b5bf9df2eb Move Temporal Client to .env (#2675) 2021-04-08 14:37:06 -07:00
Jared Rhizor
27d8a7852f rename temporal container to airbyte-temporal (#2316) 2021-03-04 17:40:09 -08:00
Jared Rhizor
e0e89ba352 only add temporal (#2259)
* only add temporal

* remove unnecessary containers

* add max retention

* fix retention specification

* increase history conns

* remove problematic retention

* fmt
2021-03-03 10:57:02 -08:00
Michel Tricot
54f9979dee Add a simple message on the webapp when it is configured to run in demo mode (#1835) 2021-01-25 19:47:00 -08:00
Jared Rhizor
c990ec6f4a output server and scheduler logs to files (#1427)
* output server and scheduler logs to files

* add workspace root env variable to docker compose up

* add workspace root to kubernetes as well
2020-12-28 12:35:24 -08:00
Jared Rhizor
1f90cf97a8 local kubernetes support (#1254)
* initial attempt at generating local kube setup from docker compose

* update current state

* mounts not working

* working mounts, failing cors

* working UI

* add remaining todos

* update todos

* A

* use kustomize to select image versions

* kube process builder factory

* fix misalignment

* don't allow any retries for requested jobs

* fix log waiting and path handling

* update todos

* local volume handling

* propagate return code correctly

* update todos

* update docs

* fmt

* add to docs

* fix conflicting config file bug

* fmt

* delete unused file

* remove comment

* add job id and attempt as inputs

* rename to WorkerEnvironment

* fix example custom overlay

* less trigger-happy docs

* rename mounts

* show local csv as not working in kube in the docs

* use config maps for everything

* fix paths

* fix build

* fix stripe integration test usage

* fix papercups on kube
2020-12-16 14:34:55 -08:00
Michel Tricot
57d9e3047e Use papercups for in-app support (#1329) 2020-12-15 15:13:26 -08:00
Christophe Duong
b9bc9c8313 Add tutorial on docker persistence (#1276)
* Give names to docker volumes used in airbyte

* Add tutorial on config persistence (#993 and #994)

* Include output results in markdown file

* Update outputs of notebook

* Update docs

* Update workspace numbers

* Tweaks from review
2020-12-11 18:45:19 +01:00
Michel Tricot
b53256aa89 Allow systematic exclusion of tracked identity (#1274) 2020-12-10 19:20:27 -08:00
Charles
b3463a52f0 Add Attempts to Job Persistence (#1151) 2020-12-03 12:55:40 -08:00