In Wire is there a way to inject named dependency?

Viewed 18

This is required by a scenario that one business Service Object struct depends on multiple storages, say, *sql.DB pointing to different MySQL backend.

Note that type is probably insufficient to determine which provider here cos they are all *sql.DB. I’m wondering if named dependency is the recommended way & does wire support it?

0 Answers
Related