openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craig L Russell <Craig.Russ...@Sun.COM>
Subject Re: svn commit: r513183 - in /incubator/openjpa/trunk: openjpa-kernel/src/main/java/org/apache/openjpa/conf/ openjpa-lib/src/main/java/org/apache/openjpa/lib/conf/ openjpa-persistence/src/main/java/org/apache/openjpa/persistence/
Date Thu, 01 Mar 2007 06:41:51 GMT
Hi Patrick,

I don't quite understand the code that follows. What is the  
difference between this code and simply defaulting the value to non- 
finalizing impl?

Craig

On Feb 28, 2007, at 10:31 PM, pcl@apache.org wrote:

>          PersistenceUnitInfo pui, Map m) {
>          PersistenceProductDerivation pd = new  
> PersistenceProductDerivation();
>          try {
> +            // if the BrokerImpl hasn't been specified, switch to the
> +            // non-finalizing one, since anything claiming to be a  
> container
> +            // should be doing proper resource management.
> +            if (!Configurations.containsProperty(BrokerValue.KEY,
> +                pui.getProperties())
> +                && !Configurations.containsProperty 
> (BrokerValue.KEY, m)) {
> +                m.put(BrokerValue.KEY,  
> BrokerValue.NON_FINALIZING_ALIAS);
> +            }
> +
>              ConfigurationProvider cp = pd.load(pui, m);
>              if (cp == null)
>                  return null;

Craig Russell
Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
408 276-5638 mailto:Craig.Russell@sun.com
P.S. A good JDO? O, Gasp!


Mime
View raw message