aspose file tools*
The moose likes JForum and the fly likes SSO for multiple deployment? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JForum
Bookmark "SSO for multiple deployment?" Watch "SSO for multiple deployment?" New topic
Author

SSO for multiple deployment?

Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Is it possible to have multiple deployments using the same user database but everything will use it own table prefix?

This way I would have a network of forums on different subdomains and members will able to log on one and have access to all.
[originally posted on jforum.net by le12484]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
le12484 wrote:Is it possible to have multiple deployments using the same user database but everything will use it own table prefix?


The "approved" (and proved) way of having multiple JForum instances is to have a different database (or catalog or schema depending on your server's vernacular ) for each instance. Then configure each instance's JDBC URL to point to the different databases. (Note, most DB Servers support multiple "databases" within a single server instance.)

If you can't do that, then it *MIGHT* be possible to edit the <server type>.sql queries to use different table names. But the DAO's may do some special query construction outside these. So, you may need to search and modify this part of the code too.

You'll also want to edit the *struct.sql files which create the tables for each instance as well.

Once you have your multiple instances set up, there is no reason an SSO implementation couldn't be done to tie all them to one authentication agent.
[originally posted on jforum.net by monroe]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I do not mind having multiple database but I was wondering what kind of authentication agent I would use to allow members to use all forums by only have to register once.
[originally posted on jforum.net by le12484]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
That depends on what your overall needs are. Basically, it could be an LDAP server with the LDAP SSO code used as a starting point, or some sort of a cookie system, or use the web/application server's security mechanisms with the remote user code.

You're going to have to decide how "membership" registration occurs and if you want people to register with single forum instances or not.

If you want to get real fancy, you could modify the DAO classes (mostly the DAOUser one) to have a single jforum_users table that is shared across all instances. This would let any instance's "register user" process automatically register the person for all instances.

The main issue I can see is how to handle the need for a separate JDBC connection pool for the global DAOUser class. Not a hard thing, just need to figure out what needs to be changed, etc. There might also be some issues with foreign key constraints in the DB Schema. E.g., user id is a FK in many tables but the id is defined in a different DB. But those would be fairly apparent if they matter (e.g., posts fail because of invalid FK problems) and can be fixed by "loosing up" the constraints if needed.

Also, if you needed it, the same DAO sort of modification could be done to the group DAO objects so there was a common set of groups shared across your jforum instances.
[originally posted on jforum.net by monroe]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: SSO for multiple deployment?