Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 9 Next »

An element of the uP101 pre-conference seminar

This page is not intended to be a general documentation of uPortal configuration. It is the specific ramblings that will be presented at the JA-SIG Vancouver uPortal 101 pre-conference seminar.

(info) Best documentation is on uPortal wiki: PersonDirectory

uPortal comes with legacy personDirs.xml enabled. To see how the Spring configured version works, we'll switch to that and add a silly attribute.

Step 1.

In the OtherProperties directory of the uportal 101 Eclipse project find

IsDemo.personDirectory.xml

It has commented out the section pointing to the legacy implementation and uncommented the beans:

org.jasig.portal.services.persondir.support.CachingPersonAttributeDaoImpl
org.jasig.portal.services.persondir.support.MergingPersonAttributeDaoImpl

and defined two source beans:

uPortalJdbcAttributeSource

which is the functional equivalent of the legacy implementation and a new source:

PortalDbJndiTestDemoSource

The new source uses the jndi source PersonDb instead of the default portal database.  In our setup PersonDb also points to the default database but in production it wouls be pointed to an authoritative source for attributes.
The new source creates an attribute with a value of either "yup" or "nope" depending on whether the user is demo.

Step 2.

  • Copy IsDemo.personDirectory.xml to the properties directory and rename it to personDirectory.xml.
  • ant deploy
  • restart Tomcat and browse to http://localhost:8080/uPortal
  • login as admin and look at the Person Attribute channel under the Development tab. This user should now have an attribute

    IsDemo = nope

  • logout and login as demo. Check the Person attribute channel again - demo should have an attribute

    IsDemo = yup

  • No labels