[TM-1520] POC Unified DB Bulk Upload #36
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
https://gfw.atlassian.net/browse/TM-1520
This ticket ended up being a lot bigger than I originally thought because I also fleshed out the full Project record for Airtable, which turned out to be a lot more involved than I thought it would be. I'm also going to be making some changes to how this works in the next ticket because the process as it stands is optimized to limit the number of queries as much as possible, but this ends up causing a different inefficiency: It means that there is a row returned from the DB per included record, which can mean thousands of rows for only a couple of projects once you get down to the tree species and workdays data. So, that system is going to need a change as well.
As with the previous ticket, this is a POC and does not include tests. The next ticket will end up getting those whole project to a stable state and will include tests.