-
Notifications
You must be signed in to change notification settings - Fork 134
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
Multi-site support #107
Comments
Doesn't each stream get a unique ID that comes in with the events? See What does your source .yml file look like? Can you share? |
dbt has on the roadmap namespacing and cross-project references, which might be the preferred way to handling this: dbt-labs/dbt-core#5244 Not sure when it's coming, obviously, but I'd be cautious about going too deep on this feature and veering away from what might become best practice. |
I had mentally identified variable-driven source.yml as an issue. I hand-coded my source.yml with different datasets in the same project while ignoring the variable. Presumably, we would prefer to support datasets in any project. I put this in its src_ga4.yml.
|
Worst-case scenario is that we move from a variable-driven source file to a hand-coded one. |
There are some interesting concepts in linked PR and linked from that PR. Namespacing dbt resources, if we could link tagging with namespacing (namespace However, I don't, based on a limited reading of the various PRs, see a complete solution to this particular problem. |
I'm playing with this right now. It seems like the easiest route to go is to do the reverse of what I have in the screenshot and immediately The reason for doing the The remaining issue when doing
YML does have some interesting properties that let you expand on a base dictionary, but the
@adamribaudo-velir, do you have any preferences? I'm leaning towards number 2. I think we can have a default, single-site config and then have multi-site users override the settings. |
Still need to review your suggestion, but is this request the same as #19 ? I feel like we discussed this (though maybe there are new ideas to consider) |
In Slack someone ended up using macros as part of the pre/post run hooks which seems like an interesting path to pursue: https://getdbt.slack.com/archives/C2JRRQDTL/p1665516903423559?thread_ts=1656004021.576959&cid=C2JRRQDTL |
Looping back to your suggestions... For suggestions 1 and 2, would we move Because if we let them override the package |
#52 is a bit related too, as far as the part about source dataset name being hardcoded to one project variable. I like the idea of using something that defaults like it does now, but can be more easily overridden in the project that's embedding the project. I believe both macros and views can be overridden, can sources do that too? |
I need to experiment with source overrides @willbryant . I hope that they can. It's also possible that dis-used sources don't cause a problem so that switching between a I think for suggestions 1 and 2, @adamribaudo-velir, I would experiment with the source overrides to understand my options before committing. I'm not sure that this will work yet, but I think we default to single source in the package and disable the single source files when it detects that the Maybe to prevent variable collisions similar to #52, we look for a ga4_datasets variable configured at the project level and disable the model associated with the ga4.dataset model. |
This is related to #19. I have a client with the need and some time to put into it whereas, in that initial issue, I only had the outline of a solution. I didn't look at YAML macros. I'll explore that option. |
Sorry to clarify, I was talking about DBT macros, not YAML macros - or did you have YAML macros in mind already? |
I'm not sure what a YAML macro is. I was referring to something like this:
|
I'm currently deploying a customized multi-site installation and want to integrate it into the main package so that the site can update.
The architecture I currently have set up looks like this.
In this draft, base_ga4__events is a View that
union all
each site. Each site gets its own base_ga4__events_* incremental table.I'll also need to integrate intraday tables and configure the sessions and users tables to flag sessions and users from each site. That shouldn't be necessary with pages and other tables as the page_location column should identify the separate sites.
The text was updated successfully, but these errors were encountered: