1
0
mirror of synced 2026-01-14 21:06:21 -05:00
Commit Graph

787 Commits

Author SHA1 Message Date
Benoit Moriceau
0b97ce3d6c Extract split the server into 2 modules (#21736)
* tmp

* For diff

* Extract common server

* Format

* Better way to get resources

* Extract the old mapper

* Move test as well

* Format
2023-01-24 07:51:20 -08:00
Octavia Squidington III
b9de100058 Bump Airbyte version from 0.40.28 to 0.40.29 (#21767)
Co-authored-by: lmossman <lmossman@users.noreply.github.com>
2023-01-23 23:22:45 -08:00
Xiaohan Song
083778183e Add write discover fetch event API (#21506)
* api changes for writing discover catalog

* api changes

* format

* change return type of the API to return catalogId

* PR comments fix

* format
2023-01-23 11:02:30 -08:00
Benoit Moriceau
b7d5be9e80 Add No content status code (#21655)
* Add No content status code

* Format
2023-01-23 18:32:36 +00:00
Jonathan Pearlin
b786a180f0 Add required roles to API endpoints (#21664)
* Restore auth poc

* Formatting

* Custom Netty pipeline handler to aid authorization

* Fix handler name

* Cleanup

* Remove cloud code

* Disable API authorization in OSS

* Remove unused dependency

* Add newline

* Add required roles
2023-01-23 12:42:43 -05:00
Anne
6026465c52 Remove jobPersistence dependency (#21625)
* Remove JobPersistence from ConfigFetchActivityImpl
2023-01-20 16:32:23 -08:00
Michael Siega
5257f69e04 fix column selection handling for syncs without cursors (#21647) 2023-01-20 22:26:31 +00:00
Benoit Moriceau
8531530016 Allow all origin in cors (#21668)
* Allow all origin in cors

* Update cors filter
2023-01-20 14:19:53 -08:00
Pedro S. Lopez
b24d575903 feat: return whether configuration was updated as part of api response (#21466)
* wip: return whether configuration was updated

* updated outputs working

* fix pmd

* update description, format

* add didUpdateConfiguration to metadata, rm unneeded generics

* add didUpdateConfiguration to api response

* update name to fix pmd

* not required

* rename to match api response

* remove unused field

* match naming
2023-01-18 18:00:37 +00:00
Charles
9415eb55cb add attempt metrics (#21286) 2023-01-17 16:13:06 -08:00
Mohit Reddy
2abfdd6ef4 airbyte server: ignore aws secret manager value for default secret persistence (#21468) 2023-01-17 10:59:10 -05:00
Benoit Moriceau
f1f0f03ea5 Allow the OSS server only on OSS (#21416) 2023-01-13 14:03:06 -06:00
Jimmy Ma
0a71b019b5 Add records committed to job stats (#21364) 2023-01-12 17:51:51 -08:00
Octavia Squidington III
02e0258948 Bump Airbyte version from 0.40.27 to 0.40.28 (#21359)
Co-authored-by: lmossman <lmossman@users.noreply.github.com>
2023-01-12 16:47:07 -08:00
Augustin
2dc5b2f818 airbyte-common-workers: Collect trace message on failed connection_status (#20721) 2023-01-12 21:49:21 +00:00
Jonathan Pearlin
7676af5f5f Migrate airbyte-bootloader to Micronaut (#21073)
* Migrate airbyte-bootloader to Micronaut

* PR feedback

* More PR feedback

* Rename variable for clarity

* Add properties to support cloud

* Formatting

* Use default values for env vars

* Re-organization to support cloud overrides

* Disable conditional logging

* More singleton cleanup

* test: try CI without fluentbit

* Revert "test: try CI without fluentbit"

This reverts commit 8fa0f74106.

* test: enable SSH on EC2 runner

* Revert "test: enable SSH on EC2 runner"

This reverts commit e4867aae09.

* Avoid early database connection on startup

* Fix compile issues from refactor

* Formatting

Co-authored-by: perangel <perangel@gmail.com>
2023-01-12 09:47:25 -05:00
Benoit Moriceau
449b2528e8 Bmoric/restore old interface (#21235)
* Re introduce old exception mapper

* Use mapper
2023-01-11 08:56:16 -08:00
Jonathan Pearlin
e571b2bfd5 Upgrade to Micronaut 3.8.0 and related dependencies (#21077)
* Upgrade to Micronaut 3.8.0 and related dependencies

* Define hostname/subdomain to be compatible with updated AWS SDK

* Use bucket name for hostname

* Pin dependencies to avoid behavior change

* Add comment
2023-01-11 10:40:29 -05:00
Tim Roes
4556b612c2 Adjust connector icons (#20547)
* Adjust connector icons

* Update icons

* Add missing icons

* Remove missing icon from spec

* Add trailing newline

* Fix test
2023-01-10 12:30:16 +01:00
Benoit Moriceau
9adb63cc0b Revert "Revert Convert the server to micronaut" (#21133)
* Revert "Revert "Convert the server to micronaut (#19194)" (#21132)"

This reverts commit 31c65f8eea.

* Fix the cors

* Fix cloud
2023-01-09 10:52:19 -08:00
Michael Siega
21b5eabc96 allow the cursors and primary keys to be deselected when the sync mode does not require it (#21117) 2023-01-09 19:03:41 +01:00
Augustin
e4707f5ed1 normalization: delete supportsDbt and supportsNormalization from DestinationDefinitionSpecificationRead (#21005)
* delete supportsDbt and supportsNormalization from DestinationDefinitionSpecificationRead

* FE changes

* add new fields to the DestinationDefinitionRead API model

* update handlers

* update api doc

* update handlers

* remove debug loggin

* implement suggestions

* update octavia-cli tests

* fix supported check

* update octavia-cli

* fix integration tests

* fix mocks

* fix forgotten renaming

Co-authored-by: Evan Tahler <evan@airbyte.io>
2023-01-07 01:12:50 +00:00
Octavia Squidington III
00fb4bba09 Bump Airbyte version from 0.40.26 to 0.40.27 (#21135)
Co-authored-by: lmossman <lmossman@users.noreply.github.com>
2023-01-06 14:27:01 -08:00
Davin Chia
f3ec113036 Remerge Progress Bar Read API. (#21124)
Let's try #20937 again, this time with better test for error cases.

See original PR for description.

This PR adds testing and logic to handle empty/bad job input.
2023-01-06 14:19:41 -08:00
Benoit Moriceau
31c65f8eea Revert "Convert the server to micronaut (#19194)" (#21132)
This reverts commit 0b153d11f9.
2023-01-06 15:08:22 -06:00
Pedro S. Lopez
01e256f579 process config control messages during check and discover (#20894)
* track latest config message

* pass new config as part of outputs

* persist new config

* persist config as the messages come through, dont set output

* clean up old implementation

* accept control messages for destinations

* get api client from micronaut

* mask instance-wide oauth params when updating configs

* defaultreplicationworker tests

* formatting

* tests for source/destination handlers

* rm todo

* refactor test a bit to fix pmd

* fix pmd

* fix test

* add PersistConfigHelperTest

* update message tracker comment

* fix pmd

* format

* move ApiClientBeanFactory to commons-worker, use in container-orchestrator

* pull out config updating to separate methods

* add jitter

* rename PersistConfigHelper -> UpdateConnectorConfigHelper, docs

* fix exception type

* fmt

* move message type check into runnable

* formatting

* pass api client env vars to container orchestrator

* pass micronaut envs to container orchestrator

* print stacktrace for debugging

* different api host for container orchestrator

* fix default env var

* format

* fix errors after merge

* set source and destination actor id as part of the sync input

* fix: get destination definition

* fix null ptr

* remove "actor" from naming

* fix missing change from rename

* revert ContainerOrchestratorConfigBeanFactory changes

* inject sourceapi/destinationapi directly rather than airbyteapiclient

* UpdateConnectorConfigHelper -> ConnectorConfigUpdater

* rm log

* fix test

* dont fail on config update error

* process control messages for discover jobs

* process control messages for CHECK

* persist config updates on check_connection_for_update

* get last config message rather than first

* fix pmd

* fix failing tests

* add tests

* source id not required for check connection (create case)

* suppress pmd warning for BusyWait literal

* source id not required for checkc onnection (create case) (p2)

* pass id, not full config to runnables/accept control message

* add new config required for api client

* add test file

* remove debugging logs

* rename method (getLast -> getMostRecent)

* rm version check (re-added this in by mistake on merge)

* fix test compatibility

* simplify
2023-01-06 15:24:24 -04:00
Benoit Moriceau
0b153d11f9 Convert the server to micronaut (#19194)
* Extract Operation API

* Extract scheduler API

* Format

* extract source api

* Extract source definition api

* Add path

* Extract State API

* extract webbackend api

* extract webbackend api

* extract workspace api

* Extract source definition specification api

* Remove configuration API

* tmp

* Checkstyle

* tmp

* tmp

* Inject but don't resolve Bean

* tmp

* Tmp

* fix build

* TMP

* Tmp

* Clean up

* better thread pool

* Change port to 8080

* Fix port

* Rm unused

* Cors filter

* Format

* rename

* Tmp

* Config based

* Rm health controller ref

* tmp

* Pool size

* Mock healthcheck

* Revert "Mock healthcheck"

This reverts commit 466677636b.

* Revert "Revert "Mock healthcheck""

This reverts commit 267094ae14.

* Restore health check

* Tmp

* format

* Rm deprecated

* Fix PMD

* Tmp

* Fix proxy test

* Remove useless annotation

* set auto commit as false

* Clean up and PR comments

* Bmoric/convert attempt micronaut (#19847)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* Comments and banner

* Non related files

* rm tmp

* Fix build

* Format

* Hit the micronaut server directly

* micronaut OperationApiController (#20270)

* micronaut OperationApiController

* pass micronaut client to OperationApi

* Bmoric/convert connection micronaut (#20211)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* tmp

* Convert Connection Api Controller

* PR Comments

* convert openapiapicontroller to micronaut (#20258)

* convert openapiapicontroller to micronaut

* merge health/openapi locations into one entry

* Fix build

* Format

* Remove media type

* Format

Co-authored-by: Cole Snodgrass <cole@airbyte.io>

* Bmoric/convert destination controller micronaut (#20269)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* tmp

* Convert Connection Api Controller

* Tmp

* PR Comments

* convert openapiapicontroller to micronaut (#20258)

* convert openapiapicontroller to micronaut

* merge health/openapi locations into one entry

* Fix bean

* Add JsonSchemaValidator as a Bean

* Fix build

* Format

* Format

* Test fix

* Pr comments

* Remove media type

* Format

* Remove media type

* Format

* format

* Add missing airbyte api client

Co-authored-by: Cole Snodgrass <cole@airbyte.io>

* Bmoric/convert destination definition controller micronaut (#20277)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* tmp

* Convert Connection Api Controller

* Tmp

* PR Comments

* convert openapiapicontroller to micronaut (#20258)

* convert openapiapicontroller to micronaut

* merge health/openapi locations into one entry

* Fix bean

* Add JsonSchemaValidator as a Bean

* Fix build

* Format

* Format

* Test fix

* Pr comments

* Remove media type

* Format

* Remove media type

* Format

* Remove media type

* Format

* api client

* missing annotation

* format

Co-authored-by: Cole Snodgrass <cole@airbyte.io>

* convert StateApiController to Micronaut (#20329)

* convert to micronaut

* nginx updates

* format

* Move dest oauth to micronaut (#20318)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* tmp

* Convert Connection Api Controller

* PR Comments

* convert openapiapicontroller to micronaut (#20258)

* convert openapiapicontroller to micronaut

* merge health/openapi locations into one entry

* Fix build

* Format

* Remove media type

* Format

* Move dest oauth to micronaut

* Pr comments

* format

Co-authored-by: Cole Snodgrass <cole@airbyte.io>

* Bmoric/convert source micronaut (#20334)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* tmp

* Convert Connection Api Controller

* PR Comments

* convert openapiapicontroller to micronaut (#20258)

* convert openapiapicontroller to micronaut

* merge health/openapi locations into one entry

* Fix build

* Format

* Remove media type

* Format

* Tmp

* tmp

* Build

* missing bean

* format

Co-authored-by: Cole Snodgrass <cole@airbyte.io>

* Migrate to micronaut (#20339)

* Migrate source to micronaut

* convert SchedulerApiController to Micronaut (#20337)

* wip; SchedulerApiController

* remove @Named

* remove @Singleton

* add back todo message

* Bmoric/convert source definition micronaut (#20338)

* tmp

* Fix build

* tmp

* Tmp

* tmp

* tmp

* Tmp

* tmp

* tmp

* Clean up

* tmp

* Convert Connection Api Controller

* PR Comments

* convert openapiapicontroller to micronaut (#20258)

* convert openapiapicontroller to micronaut

* merge health/openapi locations into one entry

* Fix build

* Format

* Remove media type

* Format

* Tmp

* tmp

* Build

* missing bean

* Tmp

* Add Beans

* fix Bean

* Add passthrough

* Clean up

* Missing path

* FIx typo

* Fix conflicts

* for mat

Co-authored-by: Cole Snodgrass <cole@airbyte.io>

* update SourceOauthApiController to Micronaut (#20386)

* convert SourceOauthApiController to Micronaut

* remove SourceOauthApi reference

* convert WorkspaceApiController to micronaut (#20214)

* wip; broken

* convert WorkspaceApiController to micronaut

* remove test controller

* format

* format

* add @Body to SourceOauthApiController

* consolidate nginx settings

* remove unnecessary factories

* Bmoric/convert jobs micronaut (#20382)

* Convert jobs to micronaut

* Nit

* Format

* Bmoric/convert source definition specification micronaut (#20379)

* Migrate source definition specifications to micronaut

* Format

* Format

* convert database assert call to Micronaut (#20406)

* remove dupe config section; add DatabaseEventListener

* move eventlistner to correct package; update implementation

* convert NotificationsApiController to Micronaut (#20396)

* convert NotificationsApiController to Micronaut

* format

* Migrate logs to micronaut (#20400)

* Bmoric/convert webbackend micronaut (#20403)

* Convert jobs to micronaut

* Nit

* Format

* Migrate the webbackend to micronaut

* Add missing Bean

* Cleanup (#20459)

* Cleanup

* More cleanup

* Disable in order to test cloud

* Restore missing files

* Fix test

* Format and fix pmd

* Add transactional

* Fix version

* Tentative

* Cleanup the cleanup

* Rm reference to the micronaut server

* format

* pmd

* more pmd

* fix build

* Delete logs API

* Revert "Delete logs API"

This reverts commit fcb271dcdf.

* Rm flaky test

* Format

* Try to fix test

* Format

* Remove optional

* Rm import

* Test sleep

* Simplify injection

* update import

* Remove sleep

* More injection

* Remove more requirement

* imports

* Remove more requirement

* Fix yaml

* Remove unused conf

* Add role

* Test acceptance test

* Update env

* Revert "Update to Micronaut 3.8.0 (#20716)"

This reverts commit a28f93747f.

* Update helm chart

* Fix helm chart

* Convert Application Listener

* Format

* Add explicit deployment mode

* Change check port

* Update version and bump version to the right value

* Cleanup

* Update FE end to end test

* Allow head request

* Fix controller

* Format

* Fix http client Bean

* Format

Co-authored-by: Cole Snodgrass <cole@airbyte.io>
2023-01-06 11:04:03 -08:00
Pedro S. Lopez
2a3817748a feat(Platform): update actor configuration when receiving control messages from connectors during sync (#19811)
* track latest config message

* pass new config as part of outputs

* persist new config

* persist config as the messages come through, dont set output

* clean up old implementation

* accept control messages for destinations

* get api client from micronaut

* mask instance-wide oauth params when updating configs

* defaultreplicationworker tests

* formatting

* tests for source/destination handlers

* rm todo

* refactor test a bit to fix pmd

* fix pmd

* fix test

* add PersistConfigHelperTest

* update message tracker comment

* fix pmd

* format

* move ApiClientBeanFactory to commons-worker, use in container-orchestrator

* pull out config updating to separate methods

* add jitter

* rename PersistConfigHelper -> UpdateConnectorConfigHelper, docs

* fix exception type

* fmt

* move message type check into runnable

* formatting

* pass api client env vars to container orchestrator

* pass micronaut envs to container orchestrator

* print stacktrace for debugging

* different api host for container orchestrator

* fix default env var

* format

* fix errors after merge

* set source and destination actor id as part of the sync input

* fix: get destination definition

* fix null ptr

* remove "actor" from naming

* fix missing change from rename

* revert ContainerOrchestratorConfigBeanFactory changes

* inject sourceapi/destinationapi directly rather than airbyteapiclient

* UpdateConnectorConfigHelper -> ConnectorConfigUpdater

* rm log

* fix test

* dont fail on config update error

* pass id, not full config to runnables/accept control message

* add new config required for api client

* add test file

* fix test compatibility

* mount data plane credentials secret to container orchestrator (#20724)

* mount data plane credentials secret to container orchestrator

* rm copy-pasta

* properly handle empty strings

* set env vars like before

* use the right config vars
2023-01-06 13:17:25 -04:00
Topher Lubaway
ef335e283f Revert "Progress Bar Read APIs (#20937)" (#21115)
Breaks when there is no config present
https://github.com/airbytehq/airbyte/issues/21112
This reverts commit 3a2b0405c4.
2023-01-06 10:09:31 -06:00
Davin Chia
3a2b0405c4 Progress Bar Read APIs (#20937)
Follow up PR to #20787 . Make stats available to the read apis so these are available to the webapp.

After this, all that is left is writing these stats as the job progresses.

Add the required logic in JobHistoryHandler.java.

Took the chance to also rename our internal Attempt models field from id to attemptNumber to better reflect that the field stores not the row's database id, but the job's attempt number. Most of the files changes here are due to that rename.
2023-01-05 16:32:19 -08:00
Anne
bb84fac8d1 Add new actorCatalogWithUpdatedAt endpoint 2023-01-05 22:12:31 +00:00
Jimmy Ma
ff1ebb0e0a Improve performance of list connection operations (#20264)
* Enable source/destination filtering in /web_backend/connection/list

* Add tests on connection filtering

* Remove redundant DB call

* Make some methods static to avoid sneaky db calls

* Minor refactor

* Small refactoring + add filtering by source for catalog fetch events

* Add comment

* Trim WebBackendConnectionList response payload

* fix build errors

* Remove requests to list_by_workspace and list_latest

* Add sourcedefid and destdefid to source/dest snippets read

* fixed sourceDefinitionId and destinationDefinitionId

* Fix webbackend handler tests

Co-authored-by: Volodymyr Petrov <volodymyr.s.petrov@globallogic.com>
Co-authored-by: KC <krishna@airbyte.io>
2023-01-03 13:54:44 -08:00
Pedro S. Lopez
5bb3240dd1 fix: add HashMap import again (#20968) 2023-01-03 11:26:30 -04:00
Pedro S. Lopez
15689adcdb fix(oauth): dont convert config values to string when building consent url (#20932)
* fix: don't convert config values to strings

* tests

* add note
2023-01-03 09:25:44 -04:00
Pedro S. Lopez
c7f8e67ad6 fix(oauth): handle fields missing in the stored config when building consent url (#20933)
* fix: handle missing fields

* test
2023-01-03 09:25:25 -04:00
Michael Siega
baf9d1144b tolerate missing source catalog used to make the configured catalog (#20928) 2022-12-29 15:42:36 -06:00
Davin Chia
2deac0f244 Prep for Java 19 Upgrade (#20911)
Upgrade all the necessary tooling dependencies to get us to Java 19.
2022-12-29 12:32:42 -08:00
Davin Chia
d98ddbbae7 Implement Progress Bar Persistence Read/Write (#20787)
Implement the persistence layer changes following #19191.

This PR handles writing and reading stats to the new stream stat_table and columns in the existing sync_stats table.

At the same time we introduce upserts of stats records - i.e. merge updates into a single record - in preparation for real time stats updates vs the current approach where a new stat record is always written.

There will be two remaining PRs after this:
- First PR will be to fully wire up and test the API.
- Second PR will be to actually save stats while jobs are running.
2022-12-28 13:47:42 -08:00
Benoit Moriceau
56c3a73abf Check for null (#20832) 2022-12-22 13:19:19 -06:00
Octavia Squidington III
27bd807fd1 Bump Airbyte version from 0.40.25 to 0.40.26 (#20630)
Co-authored-by: lmossman <lmossman@users.noreply.github.com>
2022-12-18 15:54:55 -08:00
Augustin
8af748e5e6 airbyte-server: tag span of additional OAuth routes (#20610) 2022-12-16 22:59:40 +01:00
Augustin
71d71a465b airbyte-metrics/server: add tags to root span from OAuth handler (#20468) 2022-12-15 14:18:58 +01:00
andriikorotkov
eecfafd10e Remove NormalizationRunnerFactory (#20245)
* updated IntegrationLauncherConfig.yaml and added to this class suportDBT and normalizationImage fields. Added to the GenerateInputActivityImpl and TemporalClient classes code parts for read destination_definition.yaml and get suportDBT and normalizationImage fields. Added logging and comparing normalization images from NormalizationRunnerFactory and destination_definition.yaml

* updated minor remarks

* updated minor remarks

* fixed minor remarks

* added normalization data to the tests

* fixed minor remarks

* removed NormalizationRunnerFactory

* fixed remarks

* fixed remarks

* fixed remarks

* updated acceptance tests

* updated acceptance tests

* updated check_images_exist.sh script

* updated method for get normalization image name for destination acceptance test

* fixed code style

* fixed code style and removed tests data

* updated JobErrorReporterTest.java

* updated JobErrorReporterTest.java

* fixed remarks

* added integration type field to the dectination_definition file and actor_definition table

* fixed tests

* fixed tests

* fixed minor changes after pulling master changes

* fixed minor changes after pulling master changes

* renamed integrationType to normalizationIntegrationType/ fixed minor remarks

* renamed extra dependencies

* updated docs

* updated docs

* fixed minor remarks

* added NormalizationDestinationDefinitionConfig.yaml for StandardDestinationDefinition.yaml and updated configuration

* updated normalization tag

* updated DestinationAcceptanceTest.java

* updated DestinationAcceptanceTest.java

* updated imports and descriptions
2022-12-15 12:15:34 +02:00
Michael Siega
b89f3e7fcd prevent the cursor or primary key fields from being deselected (#20481)
* prevent the cursor or primary key fields from being deselected

* fix format
2022-12-14 23:15:37 +01:00
Anne
3dae1f16aa Set breaking change to false when connection is fixed (#20315)
* Set breaking change to false when connection is fixed
2022-12-14 12:16:50 -08:00
Michael Siega
f05ac16a66 Update web backend get connection to properly handle field selection and schema refresh (#20323)
* update web backend get connection to properly handle field selection and schema refresh with newly-discovered fields

* remove debug logging

* additional unit testing around field selection in web backend handlers

* readability improvement in web backend catalog handling
2022-12-11 22:17:00 +01:00
Anne
0a8fc9e187 Disable all broken connections when source is refreshed (#20208) 2022-12-09 10:36:39 -08:00
Octavia Squidington III
f5e15dee77 Bump Airbyte version from 0.40.24 to 0.40.25 (#20279)
Co-authored-by: girarda <girarda@users.noreply.github.com>
2022-12-08 17:30:50 -08:00
Michael Siega
70ee6b00ed API changes to support configuring column selection (#20259)
* database migration to add column for field selection info

* add field selection info to standard sync persistence

* fix around persistence of field selection info

* API changes to support configuring column selection

* style and testing improvements around column selection api impl

* acceptance test fix for field selection api changes
2022-12-08 23:32:16 +01:00
Augustin
76aed344c7 airbyte-server: set tags on span in OAuthHandler (#20229) 2022-12-08 21:29:15 +01:00