mattermost-plugin-gitlab icon indicating copy to clipboard operation
mattermost-plugin-gitlab copied to clipboard

Help user to link multiple gitlab instances

Open manland opened this issue 6 years ago • 6 comments

Problem

If a user want to link to gitlab.com and gitlab.perso.com

Today solution

clone repo, change manifest id, recompile, add to mattermost, configure

Ideal solution

have list in plugin settings

Proposed solution

In CI we can :

  • build normal bin
  • change manifest id to add _2 at end and build
  • change manifest id to add _3 at end and build
  • change manifest id to add _4 at end and build
  • upload all this version in realease tag

User can add enough instance of this plugin and configure them.

As mattermost do the job of isolation in KVStore and reducers all should work.

manland avatar May 07 '19 13:05 manland

I definitely see the benefit of supporting multiple GitLab instances. I'm a little worried about how they'll work together when installing multiple versions of the GitLab plugin (multiple daily update messages, multiple slash commands e.g. /gitlab todo, /gitlab2 todo).

It might be more work but what about building support for multiple GitLab instances into the plugin? I don't think it would be too hard and we could make the user experience a lot better.

jwilander avatar May 07 '19 13:05 jwilander

@jwilander Good catch for slash command :sweat_smile:

Yes definitively the plugin should manage this, but settings are not ready to do that. We can multiply all fields by 3 or 4 but it will be really big for user who just want to connect to gitlab.com. And all fields from instance 2 will be optional but if user miss one required field it will be hard to debug this cases.

If I found time I will draft an array of struct in MM settings. I know @hanzei and @cpoile have start something!

manland avatar May 07 '19 13:05 manland

This is a very hard ticket to implement but well worth the hassle! My suggestion would be to take a look at how multi instance is implemented in https://github.com/mattermost/mattermost-plugin-jira.

hanzei avatar Feb 08 '21 19:02 hanzei