-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is load_method applicable to this target? #266
Comments
@sebastianswms @visch I implemented these load_methods in meltano/sdk#1893. I dont think any of them do anything by default yet other than I would like to see this target implement the ability to run in all 3 modes! It seems to support only upsert today. I wonder what is different in prepare_table and if its still necessary to override that method, if not then we'd get |
|
@visch yeah thats how its always been and probably will be for a long time for non-SDK targets but I agree I think its a lot clearer for users to explicitly set how they want data loaded. Sometimes even if key properties are set I'd want to append only and its kind of an advanced move to know how to override them. You make a good point though, maybe we shouldnt have a default load_method but rather None/null so the target can keep the status quo and decide based on key properties if its not explicitly set. So load_method is used more for overriding whatever load method the target would have used. |
Hello, We would like to use the Apart from this, the method So far it works because the built-in function Why not make the signature the same as the original ( |
Hello, I had a closer look. If I am understanding this correctly, it seems that a lot of the code customization came because of too many requests being done to the Postgres instance. It seems that these queries were reduced from O(n) to O(1) for each table, which is a great improvement. However, I wonder if this big amount of queries just comes from somewhere else also. I see that the function I solved it in the PR (draft yet) here just by creating a simple call to the SQLAlchemy What do you think? I am willing to take over the refactoring of the code with some guidance. |
@raulbonet thanks for digging into this more. I'm curious if anything is changed based on what came out of the caching bug conversation meltano/sdk#2325. I still think having load_method supported in this target is a great feature to add. @visch @edgarrmondragon @sebastianswms if you have any updated thoughts on this! 😄 |
Today, load methods are supported but not through the load_method configuration. We could certainly support them. The only "tricky" one would be Overwrite, which would require a slightly different insert method, but it'd pretty much match what I just described here - #340 (comment). How load methods are supported today:
|
I'm very interested in having a well-optimized |
Hello, |
When running
--about
, a load_method config option is automatically included from SDK v32. This came up in #240 but we decided not to add it the README there. Many functions in target-postgres override the SDK versions, so not sure if setting load_method will do anything.As a separate question, should it? Or is other target-postgres functionality already adequate for handling load_method functionality? Worth diving into further.
The text was updated successfully, but these errors were encountered: