Help coderanch get a
new server
by contributing to the fundraiser
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

Create groups via database

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I need to create many groups and setting the permission on them and using the graphic interface is a boring operation.

I didn't understand the database structure for this.
Do you know how to create groups and the most important thing how to set the permission using database script?

TIA
MDT
[originally posted on jforum.net by radar]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It is possible to directly set permission in the database, but the whole thing is very complex and tricky. I always end up wandering thru the code myself to remember all the ins and outs (plus it's somewhat version specific, e.g. 2.1.6 does not behave like 2.1.8, etc).

In addition, security information is cached in memory so changes done directly to the DB might not take effect until the web application is restarted.

That said, the easiest way to do this is probably to use the Apache Commons HTTPClient package to automatically create a POST request that matches the group permission s form you manually fill out. Then have that submit it.

Or if you want to dig around some more, you could start with the GroupAction.permissionsSave() method and drill down from there.
[originally posted on jforum.net by monroe]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks,
I'm working with the POST request.

MDT
[originally posted on jforum.net by radar]
 
reply
    Bookmark Topic Watch Topic
  • New Topic