History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: UP-1572
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Nick Bolton
Reporter: Andrew Petro
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
uPortal

make JNDI base context configurable

Created: 25/Sep/06 09:36 PM   Updated: 03/Jul/07 04:13 PM
Component/s: None
Affects Version/s: None
Fix Version/s: 2.6.0 M1

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown


 Description  « Hide
Made JNDI base context configurable in org.jasig.portal.RDBMServices. This was needed for passing a data source from other than the read-only java:/env/comp for testing purposes.

 All   Comments   Work Log   Change History      Sort Order:
Nick Bolton [12/Feb/07 04:40 PM]
Added a property to allow configuration of the base jndi name.

Andrew Petro [12/Feb/07 06:11 PM]
Nick,

could you add a default to this PropertiesManager invocation so that in the case where the property is not specified, it defaults to the value that was previously hardcoded? In the case where foks don't need to customize this value, not having to set it at all would be nice.

[
public class RDBMServices {
public static final String BASE_JNDI_CONTEXT = PropertiesManager.getProperty("org.jasig.portal.RDBMServices.baseJndiContext");
]

becomes

[
public class RDBMServices {
public static final String BASE_JNDI_CONTEXT = PropertiesManager.getProperty("org.jasig.portal.RDBMServices.baseJndiContext", "java:comp/env");
]

This also nicely documents an example of a valid value for the property.

Thanks,

Andrew


Andrew Petro [13/Feb/07 11:53 AM]
Nick,

I don't understand the diff for this change

http://developer.ja-sig.org/source/viewrep/jasig/portal/source/org/jasig/portal/RDBMServices.java?r1=1.53&r2=1.54

specifically, with the introduction of the property,
this:

ds = (DataSource)envCtx.lookup("jdbc/" + name);

became:

ds = (DataSource)envCtx.lookup(name);

Where did the "jdbc/" go and why is it no longer necessary or desirable?

Andrew


Nick Bolton [13/Feb/07 12:04 PM]
The jdbc context is now in the jndiBaseContext property.