Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-8075

Assign role interface does not scale to large number of users and roles

    Details

    • Type: Improvement
    • Status: Open (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Component/s: role-strategy-plugin
    • Labels:
      None
    • Environment:
      Hudson 1.381, Role based strategy 1.0
    • Similar Issues:

      Description

      Hello,

      Our Hudson deployment has a lot of independent projects which need to have several roles assigned inside the team, some team members having more rights than others. The end result: lots of users, lots of projects x several roles per project = a huge bunch of roles.
      The number of users and roles will only increase - right now we are at about 50% of the final capacity.

      Trying to use the Role Based Strategy plugin, we noticed some scaling issues with the "Assign roles" page. See roleassignment-original.png attachment for the problems.

      Notice the scroll bars when having lots of users and roles. Having lots of users is ok, vertical scrolling is something common on webpages. However, having both vertical scrolling and horizontal scrolling is confusing. The Hudson row/column highlight is helpful, however the interface is still cumbersome.

      I would propose the following interface change for the assign roles page:

      • add a text box to each table row; preferably with role autocompletion, if possible
      • add a label with the list or roles for each user

      See the roleassignement-mockup.png attachment.

      Thank you for your help.

      I propose a different design for the page, to allow it to scale when having lots of users and roles

        Attachments

          Activity

          Hide
          ccaraivan Costin Caraivan added a comment -

          Hopefully this will override the original image

          Show
          ccaraivan Costin Caraivan added a comment - Hopefully this will override the original image
          Hide
          rseguy Romain Seguy added a comment -

          I understand your need since I will have the same very soon.

          The bad point with the Hudson UI toolkit, IMO, is that it's Jelly-based and that the UI components are very low level, even with YUI. It's hard to get a state-of-the-art UI, particularly when it comes about datatables.

          ==> Implementing what you suggest will give a hard time to the guy who will do that (I won't, I'm not a YUI/HTML/CSS/JS guru + I don't have enough time for that). What I will do instead is implementing an Excel import/export feature which will allow to define roles & co in Excel in a friendly way before applying them in Hudson.

          NB: I've removed the not "obfuscated" screenshots.

          Show
          rseguy Romain Seguy added a comment - I understand your need since I will have the same very soon. The bad point with the Hudson UI toolkit, IMO, is that it's Jelly-based and that the UI components are very low level, even with YUI. It's hard to get a state-of-the-art UI, particularly when it comes about datatables. ==> Implementing what you suggest will give a hard time to the guy who will do that (I won't, I'm not a YUI/HTML/CSS/JS guru + I don't have enough time for that). What I will do instead is implementing an Excel import/export feature which will allow to define roles & co in Excel in a friendly way before applying them in Hudson. NB: I've removed the not "obfuscated" screenshots.
          Hide
          ccaraivan Costin Caraivan added a comment -

          Thanks for the removal of the old attachments.

          The Excel idea is nice, if you use CSV we can even modify the roles automatically (this is not as easy or cross platform to do with XLS).

          Show
          ccaraivan Costin Caraivan added a comment - Thanks for the removal of the old attachments. The Excel idea is nice, if you use CSV we can even modify the roles automatically (this is not as easy or cross platform to do with XLS).
          Hide
          heini Dirk Heinrichs added a comment -

          Hudson/Jenkins works on any platform, but Excel does not. Would be better to use a standard format, like OpenDocument. Can also be used on any platform, via Open/LibreOffice.

          Show
          heini Dirk Heinrichs added a comment - Hudson/Jenkins works on any platform, but Excel does not. Would be better to use a standard format, like OpenDocument. Can also be used on any platform, via Open/LibreOffice.
          Hide
          rseguy Romain Seguy added a comment -

          I understand your point, but frankly said I will use Apache POI to generate the spreadsheet, so it will necessarily generate a .xlsx file. Excel can read that, OpenOffice too, so it will be fine for everybody.

          Show
          rseguy Romain Seguy added a comment - I understand your point, but frankly said I will use Apache POI to generate the spreadsheet, so it will necessarily generate a .xlsx file. Excel can read that, OpenOffice too, so it will be fine for everybody.
          Hide
          ccaraivan Costin Caraivan added a comment -

          It might be a good idea, and also easy to implement to also allow CSV. After all parsing CSVs is easy and this kind of configuration does not really contain advanced Excel features.

          Of course, the implementer has the final say

          Show
          ccaraivan Costin Caraivan added a comment - It might be a good idea, and also easy to implement to also allow CSV. After all parsing CSVs is easy and this kind of configuration does not really contain advanced Excel features. Of course, the implementer has the final say
          Hide
          rseguy Romain Seguy added a comment - - edited

          I've worked a little on this issue and I've reached the following using YUI's datatable: See JENKINS-8075.png.

          Now I need to work on form submission, since it's 100% not compatible with the standard in Jenkins.

          Show
          rseguy Romain Seguy added a comment - - edited I've worked a little on this issue and I've reached the following using YUI's datatable: See JENKINS-8075.png . Now I need to work on form submission, since it's 100% not compatible with the standard in Jenkins.
          Hide
          rseguy Romain Seguy added a comment -

          The datatable is clickable, scrollable and sortable, with highlight.

          Show
          rseguy Romain Seguy added a comment - The datatable is clickable, scrollable and sortable, with highlight.
          Hide
          ccaraivan Costin Caraivan added a comment - - edited

          Awesome! Is there any release of the plugin planned?

          Show
          ccaraivan Costin Caraivan added a comment - - edited Awesome! Is there any release of the plugin planned?
          Hide
          jamiei Jamie I added a comment -

          @Romain: Was your update ever released?

          Show
          jamiei Jamie I added a comment - @Romain: Was your update ever released?
          Hide
          danielpetisme Daniel Petisme added a comment -

          @Jamie, I'm in charge now of Romain's work.
          As you, I'm not confortable when I use this tool. But to be franck, I haven't much time to improve it now.
          I've a groovy script to export 2 CSVs (one for the roles definition and the other one for role assignation aka. the matrix).
          I can share with you these scripts if you want.
          But I haven't a CSV import feature.
          Of course any contribution will be welcomed

          Show
          danielpetisme Daniel Petisme added a comment - @Jamie, I'm in charge now of Romain's work. As you, I'm not confortable when I use this tool. But to be franck, I haven't much time to improve it now. I've a groovy script to export 2 CSVs (one for the roles definition and the other one for role assignation aka. the matrix). I can share with you these scripts if you want. But I haven't a CSV import feature. Of course any contribution will be welcomed
          Hide
          venkatannangi venkat Annangi added a comment -

          @Daniel

          if possible can please you share the grovvy script which will export to CSV?

          Show
          venkatannangi venkat Annangi added a comment - @Daniel if possible can please you share the grovvy script which will export to CSV?
          Hide
          danielpetisme Daniel Petisme added a comment -

          Sure, it's possible.
          Export to CSV

          I've opened a pull request to add it into the official scriptler catalog.

          Tutorial:
          1 - Assign your roles
          2 - Go to Manage Jenkins > Script Console
          3 - Copy'n'Paste the export-role-strategy-permissions-to-csv.groovy script
          4 - Execute it, the script will display the CSV output
          5 - You're done!! You just have to copy the output to use it in a Excel-like tool

          To be franck, I don't know when I could work on the plugin to improve it

          Show
          danielpetisme Daniel Petisme added a comment - Sure, it's possible. Export to CSV I've opened a pull request to add it into the official scriptler catalog. Tutorial: 1 - Assign your roles 2 - Go to Manage Jenkins > Script Console 3 - Copy'n'Paste the export-role-strategy-permissions-to-csv.groovy script 4 - Execute it, the script will display the CSV output 5 - You're done!! You just have to copy the output to use it in a Excel-like tool To be franck, I don't know when I could work on the plugin to improve it
          Show
          domi Dominik Bartholdi added a comment - script is now merged into catalog: https://github.com/jenkinsci/jenkins-scripts/blob/master/scriptler/export-role-strategy-permissions-to-csv.groovy
          Hide
          danielpetisme Daniel Petisme added a comment -

          Update.
          As shown in the screenshot jenkins-role-strategy-ui-enhancer_screenshot_00.png I developped a Greasemonkey script to ease the user/role assignation in our context. the details + the Install can be found on github jenkins-role-strategy-ui-enhancer.

          Show
          danielpetisme Daniel Petisme added a comment - Update. As shown in the screenshot jenkins-role-strategy-ui-enhancer_screenshot_00.png I developped a Greasemonkey script to ease the user/role assignation in our context. the details + the Install can be found on github jenkins-role-strategy-ui-enhancer .
          Hide
          dennys Dennys Hsieh added a comment -

          Is it possible to move the "User/group to add" text box from the center location to left location?
          Because when there are lots of jobs, it's not easy to scroll to the center location.

          Show
          dennys Dennys Hsieh added a comment - Is it possible to move the "User/group to add" text box from the center location to left location? Because when there are lots of jobs, it's not easy to scroll to the center location.
          Hide
          dennys Dennys Hsieh added a comment -

          I just installed the Jenkins Role Strategy UI enhancer, it's very good, could you consider to put it on the plugin wiki page?
          I think not everybody can find it here.

          Show
          dennys Dennys Hsieh added a comment - I just installed the Jenkins Role Strategy UI enhancer, it's very good, could you consider to put it on the plugin wiki page? I think not everybody can find it here.
          Show
          danielpetisme Daniel Petisme added a comment - Done https://wiki.jenkins-ci.org/display/JENKINS/Role+Strategy+Plugin
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          Yeah, this extension is very useful in case of big number of entries. From the my side, I'd recommend to use ownership macro extensions, which allow to avoid such number of entries (I have only 10 roles and 8 assignment entries in a system with >100 users). But classic approach is useful as well.

          Do you want to integrate jenkins-role-strategy-ui-enhancer into the plugin?

          Show
          oleg_nenashev Oleg Nenashev added a comment - Yeah, this extension is very useful in case of big number of entries. From the my side, I'd recommend to use ownership macro extensions, which allow to avoid such number of entries (I have only 10 roles and 8 assignment entries in a system with >100 users). But classic approach is useful as well. Do you want to integrate jenkins-role-strategy-ui-enhancer into the plugin?
          Hide
          danielbeck Daniel Beck added a comment -

          Published my own userscripts at https://github.com/daniel-beck/jenkins-userscripts

          Added to wiki page for Role Strategy, rewrote the note a bit to make that work.

          Show
          danielbeck Daniel Beck added a comment - Published my own userscripts at https://github.com/daniel-beck/jenkins-userscripts Added to wiki page for Role Strategy, rewrote the note a bit to make that work.
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          Thanks a lot, Daniel
          I hope to implement a built-in support of such layout at some point.

          Show
          oleg_nenashev Oleg Nenashev added a comment - Thanks a lot, Daniel I hope to implement a built-in support of such layout at some point.
          Hide
          daniels0xff Daniel Anechitoaie added a comment -

          Is this issue still in progress? Any updates on this? Would really like to see this natively supported by the plugin instead of using userscripts.

          Show
          daniels0xff Daniel Anechitoaie added a comment - Is this issue still in progress? Any updates on this? Would really like to see this natively supported by the plugin instead of using userscripts.
          Hide
          silviump Silviu Marchis added a comment -

          We are also affected by this. With hundreds of groups and 10000+ users, a role assignation takes forever. Is this still investigated?

          Show
          silviump Silviu Marchis added a comment - We are also affected by this. With hundreds of groups and 10000+ users, a role assignation takes forever. Is this still investigated?
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          Hi. I've updated the status and assignee. Daniel Petisme is no longer active in the community

          Show
          oleg_nenashev Oleg Nenashev added a comment - Hi. I've updated the status and assignee. Daniel Petisme is no longer active in the community
          Hide
          oleg_nenashev Oleg Nenashev added a comment -
          Show
          oleg_nenashev Oleg Nenashev added a comment - BTW, https://wiki.jenkins-ci.org/display/JENKINS/Ownership-Based+security can be used as a workaround.
          Hide
          albernhagen Andy Bernhagen added a comment -

          This is also an issue at my company.

          Show
          albernhagen Andy Bernhagen added a comment - This is also an issue at my company.
          Hide
          totoroliu Rick Liu added a comment -

          Is there any update on this issue?
          It has been 6 years.

          Show
          totoroliu Rick Liu added a comment - Is there any update on this issue? It has been 6 years.
          Hide
          totoroliu Rick Liu added a comment -

          For temporarily workaround,
          is it possible to just re-display the row/col headings for every N entries?

          It's really hard to find the corresponding row/col headings
          when both row/col span over a single page.

          Show
          totoroliu Rick Liu added a comment - For temporarily workaround, is it possible to just re-display the row/col headings for every N entries? It's really hard to find the corresponding row/col headings when both row/col span over a single page.
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          There is no assignee in this issue. Anybody can pick it and propose a pull request.
          BTW, some bits are addressed in https://github.com/jenkinsci/role-strategy-plugin/pull/15. Some testing will be appreciated

          Show
          oleg_nenashev Oleg Nenashev added a comment - There is no assignee in this issue. Anybody can pick it and propose a pull request. BTW, some bits are addressed in https://github.com/jenkinsci/role-strategy-plugin/pull/15 . Some testing will be appreciated
          Hide
          totoroliu Rick Liu added a comment -

          I rebase https://github.com/jenkinsci/role-strategy-plugin/pull/15 to tag role-strategy-2.3.2 and install onto Jenkins ver. 2.39.

          On Ubuntu 16.04 x64,
          chromium-browser 55.0.2883.87 is working great.
          However,
          firefox 50.1.0+build2 leads to browser frozen when visiting "Assign Roles" page.

          The same firefox issue can be reproduced on Ubuntu 15.10 x64
          with firefox 47.0.

          Show
          totoroliu Rick Liu added a comment - I rebase https://github.com/jenkinsci/role-strategy-plugin/pull/15 to tag role-strategy-2.3.2 and install onto Jenkins ver. 2.39. On Ubuntu 16.04 x64, chromium-browser 55.0.2883.87 is working great. However, firefox 50.1.0+build2 leads to browser frozen when visiting "Assign Roles" page. The same firefox issue can be reproduced on Ubuntu 15.10 x64 with firefox 47.0.
          Hide
          totoroliu Rick Liu added a comment -

          I created another pull-request https://github.com/jenkinsci/role-strategy-plugin/pull/23,
          which implement the temporary workaround
          by repeating the header row (GROUPNAME) every 20 rows and header col (USERNAME) every 10 cols.

          Show
          totoroliu Rick Liu added a comment - I created another pull-request https://github.com/jenkinsci/role-strategy-plugin/pull/23 , which implement the temporary workaround by repeating the header row (GROUPNAME) every 20 rows and header col (USERNAME) every 10 cols.

            People

            • Assignee:
              Unassigned
              Reporter:
              ccaraivan Costin Caraivan
            • Votes:
              9 Vote for this issue
              Watchers:
              11 Start watching this issue

              Dates

              • Created:
                Updated: