johann_du_toit
04/15/2021, 10:33 PMinput_tap | saas_transformer | output_target
. In our case the transformer does stuff like inserting a tenant id into the schemas and records. Or remapping the stream names to match our internal tables. Of course we could write our own custom target, but this way we can use ANY tap and ANY target. We use postgresql, so for instance our sync processes might run tap-pipedrive | saas_transformer | target-postgres
to get our clients' pipedrive data into our multi-tenant postgres db. And then we run dbt to clean it up even a bit further if needed (or create a consistent set of views for our saas app to use). But you could eg create a target-rest
or something as well to push into an API. Thoughts?aaronsteers
04/15/2021, 10:37 PMaaronsteers
04/15/2021, 10:40 PMOf course we could write our own custom target, but this way we can use ANY tap and ANY target .. [and] might run `tap-pipedrive | saas_transformer | target-postgres`…If you could keep the ability for a custom transformer in the middle, would you be interested to swap the target for a custom one that requires your properly shaped data? Like
tap-pipedrive | saas_transformer | target-wink-reports
?
Do I understand correctly, the transformer in the middle would need to be flexible and the target in either case requires a standard input shape?johann_du_toit
04/15/2021, 10:56 PMjohann_du_toit
04/15/2021, 10:57 PMjohann_du_toit
04/15/2021, 11:01 PMDo I understand correctly, the transformer in the middle would need to be flexible and the target in either case requires a standard input shape?I think most of the targets will shape whatever comes in - they're quite flexible. Eg target-postgres will flatten objects, create sub-tables etc. So if the schema-massaging in the middle is good enough, then you can control what the target will do. Along with the config options of the target itself.
aaronsteers
04/15/2021, 11:01 PMmT
! But yes, today, you’d have to implement that mT
using DBT, or a custom target or tap that supports at least minor config-driven inline transforms as I describe here.
The universal inline fix is as you describe, with a transformer in the middle accepting some dynamic transformation mappings, like described here, but not yet available.aaronsteers
04/15/2021, 11:04 PMjohann_du_toit
04/15/2021, 11:16 PMaaronsteers
04/15/2021, 11:26 PMsimplecalc
library:
https://github.com/danthedeckie/simpleeval
One idea we're evaluating is (rather than write our own expression language) would be to use a library like this one. The transformer in the middle would take a setting with a list/dict of stream transformations and the transformations might be defined using simplecalc expressions. Curious to your thoughts on of this approach...johann_du_toit
04/16/2021, 2:18 AMvisch
04/16/2021, 12:49 PMvisch
04/16/2021, 12:53 PMvisch
04/16/2021, 12:53 PMpnadolny
04/16/2021, 2:14 PMvisch
04/16/2021, 2:18 PMvisch
04/16/2021, 2:18 PMvisch
04/16/2021, 2:19 PMpnadolny
04/16/2021, 2:34 PMvisch
04/16/2021, 2:38 PMpnadolny
04/16/2021, 5:00 PMpnadolny
04/16/2021, 5:01 PMaaronsteers
04/16/2021, 5:03 PMjohann_du_toit
04/18/2021, 12:29 PMhung_dang
04/21/2021, 9:16 PM