deepy / sonar-crowd

GNU Lesser General Public License v3.0
32 stars 37 forks source link

Groups Aren't Being Synced #19

Open korkutkose opened 6 years ago

korkutkose commented 6 years ago

Hi,

We have installed SonarQube 6.7.x from scratch. There were no configuration or installation files before. After installing the plugin version 2.1 and making the necessary configurations, people were able to login Sonar over Crowd. However, groups aren't being synced to Sonar. Groups are important for us for defining the Administrator users and Application permissions. Is there any idea what is wrong? I couldn't test the version 2.1.1 since it was saying support for 7.x. Not sure if it's gonna break Sonar or not.

Thanks in advance.

deepy commented 6 years ago

Hello @thelastjirabender, sorry for the late response, I didn't get my default watch settings when the repository was transferred to me.

But 2.1.1 should be fine since the APIs used were introduced in an earlier sonar version, as for the groups being synced: are they using the same case in sonar and crowd? (e.g. foo-admins vs foo-Admins) and do the groups currently exist in sonar?

flopma commented 6 years ago

I guess this question relates to issue #20

korkutkose commented 5 years ago

Hi @deepy and @flopma, Sorry for the uber late response :) I was assigned to another project and couldn't deep dive into this issue. As @flopma suggested, I also believe that this is because of Sonar doesn't know about the Crowd groups. Although USERS table in Sonar DB is showing every user that's loggin in Sonar over Crowd or Local User DB, GROUP table in Sonar DB only contains sonar-administrators and sonar-users groups which is explaining the issue that we are still having. Is @flopma 's pull request for issue #20 gonna be merged with master and release as a new version or should we create that version by ourselves?

korkutkose commented 5 years ago

Ok my bad. We were talking about completely different things :) Pull request was sent to SonarQube project not the crowd plugin, I just noticed. So this is the other way of saying, the only possible way to achive this is to wait until we have this feature SonarQube's itself not the plugin. Am I right?

korkutkose commented 5 years ago

A quick update and workaround for this problem is to create the group(s) in Sonar's internal directory manually. After that, when the user logins again, related group thus DB table is populated properly. It's an acceptable workaround for me since I am only trying to get Sonar Admin group from Crowd. This is not sustainable or robust solution if you are trying to get more than a few groups from Crowd.