This PR is step 5 of this tech spec - https://docs.google.com/document/d/1qFk4YqnwxE4MCGeJ9M2scGOYej6JnDy9A0zbICP_zjI/edit.
The first of (at least) 2 PRs to implement this on the source side. I made some headway before deciding to break the changes into one PR implementing this for discover schema job, and another PR implementing this for read. The combined PR would have been too big otherwise.
Also refactor MoreResources as the test method was attempting to write to the location classes where loaded out from - the issue is we cannot guarantee where the class is loaded from can be written to. Changing this to write to a random folder in the temp directory.
* Handle destination sync mode in destinations
* Source & Destination sync modes are required (#2500)
* Provide Migration script making sure it is always defined for previous sync configs
Add the latestSyncJobStatus field to the WbConnectionRead struct. Take the chance to rename the lastSync field to latestSyncJobCreatedAt to better reflect what the field captures. lastSync was confusing as I expect it to return the Id/object of the last sync and not the last sync's timestamp.
We keep the current expectation when setting status - the same job that sets the timestamp field is used to set the status field.
We surface the job's status as is. This gives the UI flexibility on displaying the various statuses.
Since the 'latest' sync job is determined by the JobHistoryHandler, I buffed up the job history handler test cases to make sure we do always return the latest sync job.
What:
Swagger UI has bad-UI and extensibility. It's not intuitive and often displays information badly (especially for more complicated structs), which leads to initial API confusion.
How:
Switch over to use Rapidoc. This is our new api docs!
Created the airbyte-public-api-docs bucket and uploaded our new html docs. Set up a CloudFront distribution to enable HTTPS.
A copy of our html docs is checked in in this PR. As you can see, this is a minimal file that relies on a React component published by Rapidoc. It is pointed to the api docs in our master branch and will automatically update itself; do not expect us to need to touch this api file unless we want to make display changes.
I consolidated all files involving api documentation into the docs/api folder for simplicity. I also moved the generated html file to the generated-api-html folder within the api folder to make it clear it was generated. Finally, added a README to document our set up.
Benefits:
UI is much cleaner.
We control the html source file, which means it'll be easier for us to make changes in the future.