#58 downstream: Add ability to use different jira instances
Merged by ralph. Opened by dustymabe.
dustymabe/sync-to-jira dusty  into  develop

Download 58.patch

There are a few changes in this patch set. First we'd like to
support different github/pagure repos being able to be synced
with different instances of JIRA. We currently have two within
Red Hat that we are using, but this strategy should alos support
more than two. Summary of changes in this patch:

  • add support for multiple jira instances to the config under the
    config['sync2jira']['jira'] config location. For example if I
    wanted to grab the auth info for the pnt-jira I would access
    config['sync2jira']['jira']['pnt-jira'].
  • add support for a 'default_jira_instance' config key that allows
    for a user to specify which jira in the jira dict to use as a default
    in case config entries don't specify a jira instance to use.
  • switch function names from functions that that are only called in
    this file to have a preceding underscore (func -> _func)
  • make the only functions that get called from outside this file to
    be the ones that crete a client connection to the jira instance
  • pass the jira client object around to the private functions

rebased onto cf7255ea50d2ed2c049fbd9f2a961eed131003ca

a few comments:

  • i'm still testing this out so some fixes may still come in
  • if we merge/release this we will need to coordinate config changes
  • could use some help making sure I did the tests right.. seems a little hacky right now

No major objections here. It looks good. I just want to try it out before merging. I can handle the config rollout when the time comes.

are there any docs that need updating?

are there any docs that need updating?

Nope, it's all self-contained here.

Pull-Request has been merged by ralph

Metadata