connectapi icon indicating copy to clipboard operation
connectapi copied to clipboard

Shared Connect configuration across client packages

Open slodge opened this issue 1 year ago • 2 comments

I seem to be using connectapi more and more frequently:

  • Building adhoc admin scripts using connectapi directly
  • Building our CI/CD scripts using connectapi directly
  • Writing scripts, apps, and report which use pins - using https://github.com/rstudio/pins-r/blob/main/R/board_connect.R
  • Writing plumber client apps using our own client package (built on top of https://github.com/slodge/rapiclient - currently working out if we can publish this somehow... depends on plumber changes anyway - so won't happen soon)

All of these usages seem to somehow end up using their own custom conventions for connect connections - e.g. pins with its c("auto", "manual", "envvar", "rsconnect") setup.

Is it worth implementing a standard set of ways to configure Connect connections so that users can set these up once and then use any connectapi-dependent package? If so, should connectapi be the place for this?

slodge avatar Mar 02 '23 12:03 slodge

Whew - it's been a while here, sorry for the delay @slodge !! I love this idea! The differing connections is definitely a pain 😞

I agree that we should have a consistent set of connection primitives that can then be used across packages: pins, rsconnect, connectapi, connectwidgets, etc. connectapi could definitely be such a place, although we may also decide to have somewhere more primitive be the original source (i.e. so rsconnect does not have a quasi-circular dependency).

This is definitely a bigger task / epic, so may be something we need to track / plan for internally.

colearendt avatar May 15 '23 19:05 colearendt

Happy for you to decide where it goes 👍 Will leave architecture and planning decisions to the posit process 👍

slodge avatar May 17 '23 06:05 slodge