Bug 793458 (JBEPP-541) - Docs: Add documentation on how to change IDM configuration to point to a custom DB schema
Summary: Docs: Add documentation on how to change IDM configuration to point to a cust...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: JBEPP-541
Product: JBoss Enterprise Portal Platform 5
Classification: JBoss
Component: Documentation
Version: 5.1.0.Docs.GA
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 5.2.1.Docs.GA
Assignee: Scott Mumford
QA Contact: Michal Vanco
URL: http://jira.jboss.org/jira/browse/JBE...
Whiteboard: bdaw
Depends On:
Blocks: JBEPP-801
TreeView+ depends on / blocked
 
Reported: 2010-10-11 21:20 UTC by Martin Weiler
Modified: 2014-06-17 13:58 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-03-12 04:05:48 UTC
Type: Task


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 793463 0 high CLOSED Docs: Productize the PicketLink IDM documentation 2021-02-22 00:41:40 UTC
Red Hat Issue Tracker JBEPP-541 0 Minor Closed Docs: Add documentation on how to change IDM configuration to point to a custom DB schema 2013-03-12 04:03:52 UTC

Internal Links: 793463

Description Martin Weiler 2010-10-11 21:20:10 UTC
Affects: Documentation (Ref Guide, User Guide, etc.)
project_key: JBEPP

The docs should show the initial config steps or a sample configuration on how to change the IDM configuration to point to a custom, existing DB schema.

Comment 1 Scott Mumford 2010-10-11 22:15:11 UTC
Affects: Added: [Documentation (Ref Guide, User Guide, etc.)]


Comment 2 Scott Mumford 2010-10-11 22:16:36 UTC
Is there info on how to change the IDM configuration anywhere?

Comment 3 Scott Mumford 2010-10-11 22:17:43 UTC
Link: Added: This issue is a dependency of JBEPP-517


Comment 4 boleslaw.dawidowicz 2010-10-25 08:30:30 UTC
Could you describe a usecase?

Comment 5 Scott Mumford 2010-11-03 00:28:05 UTC
Release Notes Docs Status: Added: Not Required


Comment 6 Scott Mumford 2010-11-11 03:28:06 UTC
Boleslaw: No, sorry I can't provide a usecase.
I'll contact Martin Putz to see if he can provide something.

Comment 7 Scott Mumford 2011-02-10 07:31:24 UTC
Link: Removed: This issue is a dependency of JBEPP-517 


Comment 8 Scott Mumford 2011-02-10 07:32:32 UTC
Link: Added: This issue related JBEPP-545


Comment 9 Scott Mumford 2011-04-15 04:12:43 UTC
Subject Matter Expert: Added: smumford
NEEDINFO: Added: Nobody


Comment 10 Scott Mumford 2011-04-15 04:13:31 UTC
Subject Matter Expert: Removed: smumford 
NEEDINFO: Removed: Nobody 


Comment 11 Scott Mumford 2011-04-19 04:49:01 UTC
Link: Added: This issue is a dependency of JBEPP-801


Comment 12 Scott Mumford 2011-07-26 06:09:03 UTC
Secondary SME: Added: bdaw
NEEDINFO: Added: Reporter


Comment 13 Scott Mumford 2011-09-13 04:17:10 UTC
From Boleslaw Dawidowicz:
This is not really well documented or supported. I think the easiest and fastest way at this point is to reimplement OrganizationService. So just replace the one that is defined in gatein.ear/02portal.war/WEB-INF/conf/organization/idm-configuration.xml.

There is also no documentation available but this is just a couple of interfaces to cover and it will replace usage of PicketLinkIDM with some custom solution.  

Comment 14 Jared MORGAN 2012-05-14 04:06:44 UTC
Hi Martin

We now describe how to set up IDM and JCR databases in the Installation Guide here:

http://docs.redhat.com/docs/en-US/JBoss_Enterprise_Portal_Platform/5.2/html/Installation_Guide/sect-Reference_Guide-Database_Configuration.html

Would the information in this section be sufficient for customers, or is more information required?

Cheers

Jared

Comment 15 Martin Weiler 2012-05-14 08:12:45 UTC
Jared,

the chapter on how to configure the databases contains useful information. However, it does not cover the use case for which this bugzilla had been raised. What customers were asking for was how to create a custom implementation of OrganizationService, in order to store the IDM data in some custom tables.

We now have a KBase article which contains some pointers on how to get started with this task:
https://access.redhat.com/knowledge/solutions/74953

If it is too much effort to create similar content for the Reference / Developer Guide, then we can close this bugzilla, refine the KBase article, and point interested customers to this information.

-Martin

Comment 16 Jared MORGAN 2012-05-14 23:40:03 UTC
(In reply to comment #15)
> Jared,
> 
> the chapter on how to configure the databases contains useful information.
> However, it does not cover the use case for which this bugzilla had been
> raised. What customers were asking for was how to create a custom
> implementation of OrganizationService, in order to store the IDM data in some
> custom tables.
> 
> We now have a KBase article which contains some pointers on how to get started
> with this task:
> https://access.redhat.com/knowledge/solutions/74953
> 
> If it is too much effort to create similar content for the Reference /
> Developer Guide, then we can close this bugzilla, refine the KBase article, and
> point interested customers to this information.
> 
> -Martin

Thanks very much for the info Martin.

There's enough info in the KBase to convert to enterprise docs (nicely written procedural info).

Because the KBase is not yet viewable by Customers, and has not been verified (base on the statuses in the KBase), I think it should be converted instead of linked.

Cheers

J

Comment 17 Jared MORGAN 2012-10-11 01:15:43 UTC
TRIAGE INFORMATION

Relevance: EPP 5.2 and EPP 6

==Task==

Make the changes as prescribed in Comment16 in both versions. If you have problems accessing that KBase let me know and I can attach it to the ticket.

==Requirements== 

Ensure you have access to:

http://svn.jboss.org/repos/gatein/epp/docs/branches/5.2/ and http://svn.jboss.org/repos/gatein/epp/docs/branches/6.0/

to make changes to these guides.

==Resolving==

Add Revision History to each guide, and stage the books. 

Commit changes to SVN trunks.

Update the BZ with tracking info.

Comment 18 Scott Mumford 2012-11-28 04:04:15 UTC
Martin,

I'm not sure I see the connection between the request for instructions on how to implement a custom DB schema and the Kbase article you linked which is about LastLoginTime.

Can you confirm that the URL [1] is correct, and if so, please explain how the two topics are related.

Thanks

1: https://access.redhat.com/knowledge/solutions/74953

Comment 19 Martin Weiler 2012-11-28 14:48:30 UTC
Hi Scott,

the KBase article is indeed the best information we have on how to create custom classes to replace PicketLink IDM, although it has been written for a very specific use case.

I think the part between "In order to implement such a custom UserDAOImpl..." and "And finally, change..." is quite generic.

HTH,
Martin

Comment 20 Scott Mumford 2012-11-29 01:28:17 UTC
Thanks Martin,

I've drafted some simple content based on the KBase article, trying to be generic while using the kbase usecase as an example.

Can you please review it and recommend any changes in a comment. I won't commit it to the document until it's verified by an SME.

Thanks

######### Draft Content ######################

Overview:

In order to implement a custom class, the following steps must be taken:

* Edit the 02portal.war/WEB-INF/conf/organization/idm-configuration.xml file to use the custom class.

* Create the custom implementation class. The easiest way to do this is to copy and edit one of the java files found at:
http://anonsvn.jboss.org/repos/gatein/epp/portal/tags/EPP_5_1_1_GA/component/identity/src/main/java/org/exoplatform/services/organization/idm/
DOCS NOTE: Is there any way for a user to get these from their local EPP instance? Or are these downloads the only way?

* Edit or remove any methods in the class that may interfere with the customized behavior you are implementing.
DOCS NOTE; A 'for further information about possible changes please refer to ...' would be good here.

Example:

The following is a step-by-step example of the changes outlined above.

This example disables writing a user's last login time to the database. 

1: Change the value for org.exoplatform.services.organization.OrganizationService in idm-configuration.xml:

<component>
    <key>org.exoplatform.services.organization.OrganizationService</key>
    <!--type>original.ExampleServiceImpl</type-->
    <type>custom.ExampleServiceImpl</type>
    <init-params>

Obtain a copy of http://anonsvn.jboss.org/repos/gatein/epp/portal/tags/EPP_5_1_1_GA/component/identity/src/main/java/org/exoplatform/services/organization/idm/PicketLinkIDMOrganizationServiceImpl.java
 

2: Change the constructor of the custom PicketLinkIDMOrganizationServiceImpl to use custom DAO implementations:

public PicketLinkIDMOrganizationServiceImpl(InitParams params, PicketLinkIDMService idmService) throws Exception {
    groupDAO_ = new GroupDAOImpl(this, idmService);
    userDAO_ = new UserDAOImpl(this, idmService);
    userProfileDAO_ = new UserProfileDAOImpl(this, idmService);
    membershipDAO_ = new MembershipDAOImpl(this, idmService);
    membershipTypeDAO_ = new MembershipTypeDAOImpl(this, idmService);


3: Remove the following code from the authenticate(..) method in the custom UserDAOImpl (as it sets the last login time):

if (authenticated)
{
    UserImpl userImpl = (UserImpl)user;
    userImpl.setLastLoginTime(Calendar.getInstance().getTime());
    saveUser(userImpl, false);
}


Note You need to log in before you can comment on or make changes to this bug.