ate         2004/10/15 11:50:44

  Modified:    components/profiler/src/java/org/apache/jetspeed/profiler/impl
                        JetspeedProfiler.java
  Log:
  Fixed ClassCastException thrown from Oracle jdbc driver which doesn't do automatic 
object.toString()
  when it gets passed in a complex object as filter parameter related to a character 
field.
  In general, one shouldn't rely on this kind of support.
  Although several jdbc drivers can handle it,  the Oracle jdbc driver certainly 
doesn't.
  
  Revision  Changes    Path
  1.9       +2 -2      
jakarta-jetspeed-2/components/profiler/src/java/org/apache/jetspeed/profiler/impl/JetspeedProfiler.java
  
  Index: JetspeedProfiler.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-jetspeed-2/components/profiler/src/java/org/apache/jetspeed/profiler/impl/JetspeedProfiler.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- JetspeedProfiler.java     15 Oct 2004 06:59:21 -0000      1.8
  +++ JetspeedProfiler.java     15 Oct 2004 18:50:44 -0000      1.9
  @@ -358,7 +358,7 @@
       public String[] getLocatorNamesForPrincipal(Principal principal)
       {
           Filter filter = persistentStore.newFilter();        
  -        filter.addEqualTo("principalName", principal);
  +        filter.addEqualTo("principalName", principal.getName());
           Object query = persistentStore.newQuery(principalRuleClass, filter);
           Collection result = persistentStore.getCollectionByQuery(query);
           if (result.size() == 0)
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to