Re: Error Building OpenEJB Source File

2008-10-29 Thread David Blevins

Hi Suhaas,

I did try to build the 3.0 sources.  I didn't get the error that you  
got but I did find an issue with a missing dependency caused by the  
maven-shade-plugin.


As 3.1 was just released, I tried again with that source to make sure  
it could build from the src zip.  Everything built cleanly.  Here's  
the command I used:


 mvn clean install

Give that a try and feel free to post any issues.

-David

On Oct 21, 2008, at 10:20 AM, suhaas wrote:



Hi,

I wanted to build a jar out of Open EJB source code with Eclipse. So I
downloaded openejb-3.0-src.zip from the website and unzipped it. At  
the root

of the unzipped directory, there is a pom.xml. When I run
mvn package or mvn clean package install I get the following  
build error

[INFO] Error building POM (may not be this project's POM).

This is the Maven 2 Log

[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO]   OpenEJB
[INFO]   OpenEJB :: Dependencies
[INFO]   OpenEJB :: Dependencies :: XBean Finder
[INFO]   OpenEJB :: Dependencies :: XBean Reflect
[INFO]   OpenEJB :: iTests
[INFO]   OpenEJB :: iTests Beans
[INFO]   OpenEJB :: iTests Servlets
[INFO]   OpenEJB :: iTests Client
[INFO]   OpenEJB :: iTests Interceptor Beans
[INFO]   OpenEJB :: iTests App
[INFO]   OpenEJB :: iTests Web
[INFO]   OpenEJB :: Container
[INFO]   OpenEJB :: Container :: Loader
[INFO]   OpenEJB :: Container :: Java Agent
[INFO]   OpenEJB :: Container :: Java EE
[INFO]   OpenEJB :: Container :: Core
[INFO]   OpenEJB :: Server
[INFO]   OpenEJB :: Server :: Client
[INFO]   OpenEJB :: Server :: Core
[INFO]   OpenEJB :: Server :: EJBd
[INFO]   OpenEJB :: Server :: Admin
[INFO]   OpenEJB :: Server :: Http
[INFO]   OpenEJB :: Server :: WebAdmin
[INFO]   OpenEJB :: Server :: Telnet
[INFO]   OpenEJB :: Server :: ActiveMQ
[INFO]   OpenEJB :: Server :: CORBA
[INFO]   OpenEJB :: Server :: Derby Network Service
[INFO]   OpenEJB :: Server :: Hsql
[INFO]   OpenEJB :: Server :: Webservices
[INFO]   OpenEJB :: Server :: Axis
[INFO]   OpenEJB :: Server :: Axis2
[INFO]   OpenEJB :: Server :: CXF
[INFO]   OpenEJB :: Examples :: Simple Stateful Pojo
[INFO]   OpenEJB :: Examples :: Simple Stateless Pojo
[INFO]   OpenEJB :: Examples :: Simple Webservice
[INFO]   OpenEJB :: Examples :: EJB 2.1 Component Interfaces
[INFO]   OpenEJB :: Examples :: @EJB Injection
[INFO]   OpenEJB :: Examples :: @Resource env-entry Injection
[INFO]   OpenEJB :: Examples :: @Resource DataSource Injection
[INFO]   OpenEJB :: Examples :: @PersistenceContext EntityManager  
Injection

[INFO]   OpenEJB :: Examples :: Testing Transactions
[INFO]   OpenEJB :: Examples :: Testing Security
[INFO]   OpenEJB :: Examples :: Interceptors
[INFO]   OpenEJB :: Examples :: Expanded support for Env Entries
[INFO]   OpenEJB :: Examples :: Hello World - Weblogic
[INFO]   OpenEJB :: Examples :: JPA with Hibernate
[INFO]   OpenEJB :: Examples :: Telephone Stateful Pojo
[INFO]   OpenEJB :: Web Examples :: EJB Examples War
[INFO]   OpenEJB :: Web Examples
[INFO]   OpenEJB :: Examples
[INFO]

[INFO] Building OpenEJB
[INFO]task-segment: [package]
[INFO]

[INFO] Setting property: classpath.resource.loader.class =
'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
[INFO] Setting property: velocimacro.messages.on = 'false'.
[INFO] Setting property: resource.loader = 'classpath'.
[INFO] Setting property: resource.manager.logwhenfound = 'false'.
[INFO] [remote-resources:process {execution: default}]
[INFO] [dependency-report:report {execution: default}]
[INFO] No dependencies to report
[INFO] [bundle:manifest {execution: bundle-manifest}]
[INFO] [site:attach-descriptor]
[INFO]

[INFO] Building OpenEJB :: Dependencies
[INFO]task-segment: [package]
[INFO]

[INFO] [remote-resources:process {execution: default}]
[INFO] [dependency-report:report {execution: default}]
[INFO] No dependencies to report
[INFO] [bundle:manifest {execution: bundle-manifest}]
[INFO] [site:attach-descriptor]
[INFO]

[INFO] Building OpenEJB :: Dependencies :: XBean Finder
[INFO]task-segment: [package]
[INFO]

[INFO]

[ERROR] BUILD ERROR
[INFO]

[INFO] Error building POM (may not be this project's POM).


Project ID: org.apache.maven.plugins:maven-surefire-plugin
POM Location: C:\Documents and
Settings\Suhas.Valanjoo\.m2\repository\org\apache\maven\plugins 
\maven-surefire-plugin\2.4\maven-surefire-plugin-2.4.pom


Reason: Not a v4.0.0 POM. for project

Re: persistence.xml in a Jar in Tomcat Common classloader (ERROR : PersistenceUnit already deployed)

2008-10-29 Thread Henri Gomez
 In the 3.1 release changelog I could see :

 EAR-style classpath application discovery groups individual modules as
 an EAR allowing sharing of persistence units and improved connector
 and custom MDB deployment.

 Did it what we discussed in this thread ?

 That's actually a different feature.  This was another long release cycle
 (binaries were rolled on the 9th).

 The global persistence unit feature might be a little tricky to turn around,
 but I'm sure we can get it in.  Filed a jira for it here:

  https://issues.apache.org/jira/browse/OPENEJB-932
  (get notifications -
 https://issues.apache.org/jira/secure/ViewIssue.jspa?id=12407377watch=true)

Great, I hope you could do that, it will be a very very valuable in
our configuration (tomcat with many webapps)

Regards and thanks


Re: Inspect database when using embedded OpenEJB

2008-10-29 Thread Bernhard Humm



David Blevins wrote:
 
 
 ...
 
 Wanted to respond to this earlier, but was swamped with finalizing the  
 release.  Anyway, it's up now.  Give it a try and hopefully things work.
 
 If not post some config details and maybe we can spot something.
 
 -David
 
 

Dear David,

thanks a lot for your response. I have installed the new release. However, I
still can't find database values on disk. All JUnit test cases that create
and retrieve entity beans run fine (OpenEJB is really a great product :-)). 
In my NetBeans project there is a path with HSQL database files:
C:\temp\NetBeans\LibraryX\tmp\testing\data\hsqldb\hsqldb.*
However, after running the test cases, the files don't seem to be touched
(old file date). I can connet to this database from the NetBeans database
viewer:
Database URL:
jdbc:hsqldb:file:/temp/NetBeans/LibraryX/tmp/testing/data/hsqldb/hsqldb
Driver  : org.hsqldb.jdbcDriver
Schema: PUBLIC
Product:HSQL Database Engine
User:   sa
Password: 
Database product name:  HSQL Database Engine
Database product version:   1.8.0

However, there are no current values.
To my surpise, the database contained tables and values from earlier tests.
But the values were not updated by current tests. After deleting the tables,
they were not re-created.

This is the content of my persistence.xml file:

?xml version=1.0 encoding=UTF-8?
persistence xmlns=http://java.sun.com/xml/ns/persistence; version=1.0
  persistence-unit name=libraryX-unit
   
jta-data-sourcejava:openejb/Resource/libraryXDatabase/jta-data-source
properties
  property name=openjpa.jdbc.SynchronizeMappings
value=buildSchema(ForeignKeys=true)/
/properties
  /persistence-unit
/persistence

Regards
   Bernhard
-- 
View this message in context: 
http://www.nabble.com/Inspect-database-when-using-embedded-OpenEJB-tp20071160p20224695.html
Sent from the OpenEJB User mailing list archive at Nabble.com.



Re: [ANN] OpenEJB 3.1 Released

2008-10-29 Thread David Blevins

All,

Just wanted to add that any mention of the 3.1 release in your blog  
(if you have one) is greatly appreciated and a very fine way to  
express thanks.


Every little bit helps.  And in many ways the voices of several  
individuals says much more than the one or two theserverside.com/ 
infoq.com posts we get a year.


All the best,
David


On Oct 27, 2008, at 7:55 PM, David Blevins wrote:


Download binaries here:

http://openejb.apache.org/download.html

Highlights
-

Major new features:

- EJB 3.1 Singleton Support
- EJB Constructor Injection
- Spring Integration
- Multicast Client-Server Discovery

Significant Improvements:

- EAR-style classpath application discovery groups individual  
modules as an EAR allowing sharing of persistence units and improved  
connector and custom MDB deployment.


- Detection of EclipseLink, TopLink, and Hibernate as JPA providers  
to automatically adds the right persistence unit property to for  
wiring in the OpenEJB TransactionManager.


- System Property and InitialContext property overriding now applies  
to persistence-unit properties and logging levels.


- Login/logout now possible in an embedded scenario via  
InitialContext params and initialContext.close() respectively.


- Complete overhaul of all client/server connection management  
dramatically increases performance.


- Several new checks added to Application Validation ruleset, some  
reworked to give even more details.



Full changelog
-

New Features:

 * [OPENEJB-836] Singleton Session Beans
 * [OPENEJB-839] Singleton Read and Write method locking
 * [OPENEJB-841] Singleton @DependsOn load ordering
 * [OPENEJB-840] Singleton @Startup load-on-startup
 * [OPENEJB-837] Singleton Bean-Managed Concurrency
 * [OPENEJB-838] Singleton Container-Managed Concurrency
 * [OPENEJB-821] EAR-style aggregation of modules discovered in the  
classpath

 * [OPENEJB-920] JDBC/DataSource based login module
 * [OPENEJB-913] Client Connection Failover and Request Retry
 * [OPENEJB-912] Client-side Connection Pool
 * [OPENEJB-857] Client connection KeepAlive
 * [OPENEJB-911] Graceful shutdown of client/server connections
 * [OPENEJB-903] Multicast discovery and grouping
 * [OPENEJB-905] PersistenceUnit property overriding
 * [OPENEJB-898] Property overriding for logging configuration
 * [OPENEJB-897] LocalInitialContext.close() to logout of embedded  
container
 * [OPENEJB-894] LocalInitialContext.close() to shutdown embedded  
container

 * [OPENEJB-896] VM-scoped Security for embedded scenarios
 * [OPENEJB-805] JMS runs port-free in embedded mode
 * [OPENEJB-785] EJBd protocol over SSL
 * [OPENEJB-881] Automatically set eclipselink.target-server for  
EclipseLink

 * [OPENEJB-880] Automatically set toplink.target-server for TopLink
 * [OPENEJB-801] Automatically set  
hibernate.transaction.manager_lookup_class for Hibernate


Improvements:

 * [OPENEJB-893] Improved JavaAgent/JPA enhancement for Unit Tests
 * [OPENEJB-826] Improved detection of testing and embedded scenarios
 * [OPENEJB-899] Improved classpath configuration searching
 * [OPENEJB-831] PersistenceModule discoverable via the classpath
 * [OPENEJB-892] Remove ASM dependency
 * [OPENEJB-813] Example: CMP2 EntityBean
 * [OPENEJB-348] Example: Minimal MessageDriven Bean via  
@MessageDriven
 * [OPENEJB-850] Example: Singleton bean with bean vs container  
concurrency

 * [OPENEJB-359] Example: Using JMS
 * [OPENEJB-848] Validation: @TransactionAttribute mistakenly used  
on beans with Bean-Managed Transactions
 * [OPENEJB-855] Validation: Init/Remove annotations not used on  
MessageDriven, Stateless, or Singleton beans
 * [OPENEJB-677] Validation: PrePassivate/PostActivate not used on  
MessageDriven or Stateless
 * [OPENEJB-844] Validation: Singleton @Lock annotation not used  
with Bean-Managed Concurrency
 * [OPENEJB-846] Validation: Singleton mistakenly using  
@PrePassivate and @PostActivate

 * [OPENEJB-808] Validation: Unused ejbCreate methods
 * [OPENEJB-809] Validation: Unused ejbPostCreate methods
 * [OPENEJB-859] Improved validation for home, remote, local- 
home, local, business-local and business-remote elements
 * [OPENEJB-817] ID portion of property overriding no longer case  
sensitive

 * [OPENEJB-856] Upgrade to OpenJPA 1.1.0
 * [OPENEJB-904] Pluggable Client/Server connection strategies and  
factories
 * [OPENEJB-799] Support META-INF/env-entry.properites as an  
alternative to META-INF/env-entries.properies

 * [OPENEJB-800] Default env-entry-type to java.lang.String
 * [OPENEJB-823] Print Service properties on debug
 * [OPENEJB-825] Eliminate possible mismatch of TxRecovery flag  
between TransactionManager and Resources
 * [OPENEJB-829] Automatically add an @DeclareRole ref for any role  
listed in @RolesAllowed

 * [OPENEJB-828] @EJB(name) value used to resolve ambiguous refs
 * [OPENEJB-818] CMP1.1 and CMP2.x beans not required to implement  
javax.ejb.EntityBean

 * [OPENEJB-807] CMP2 

Additional OpenEJB 3.1 Release notes

2008-10-29 Thread David Blevins
We had a few items that didn't make it into the auto-generated release  
notes.  We've gone through and manually added in some missing  
entries.  The RELEASE-NOTES.txt for the 3.1 release has been updated,  
but for your convenience here are the items that have been added:


New Features:

  * [OPENEJB-126] Constructor Injection
  * [OPENEJB-935] Spring Integration
  * [OPENEJB-933] Injection Support for JSF 1.2 ManagedBeans
  * [OPENEJB-941] ConnectorModule discoverable via the classpath (rar  
files)


Improvements:

  * [OPENEJB-900] Example: Testing Security via InitialContext login/ 
logout

  * [OPENEJB-936] Log Tomcat resources imported into OpenEJB
  * [OPENEJB-943] Improved support for non-JMS Connectors
  * [OPENEJB-940] Severely improved client performance over ejbd
  * [OPENEJB-946] Optimized annotation scanner to determine if a jar  
is an ejb jar more quickly
  * [OPENEJB-939] Write the cmp mappings when  
openejb.descriptors.output is set to true
  * [OPENEJB-944] Allow value of server service only_from property  
to use comma, tab and newline as a separator
  * [OPENEJB-938] Improved the validation check on methods to look  
for mismatched arguments or conflicting case
  * [OPENEJB-934] Better support for external activemq.xml  
configuration

  * [OPENEJB-937] Improved StatefulContainer instance caching
  * [OPENEJB-948] Container AccessTimeout and TimeOut values  
expressible as text 200ms, 1 hour, 5 min, etc.

  * [OPENEJB-947] Command line tool for monitoring multicast heartbeat

Bugs:

  * [OPENEJB-797] Unable to load servlet class:  
javax.faces.webapp.FacesServlet
  * [OPENEJB-874] SystemInstance is not updated with the properties  
defined in conf/system.properties
  * [OPENEJB-945] Should call stop() on the remaining  
ResourceAdapters during destroy()
  * [OPENEJB-873] Deploying the same ejb in two different webapps  
causes a DuplicateDeploymentIdException
  * [OPENEJB-901] Fixed broken isCallerInRole when using Tomcat  
JAASRealm with the TomcatSecurityService
  * [OPENEJB-942] Fixed potential NullPointerException scanning  
servlets that have no servlet class (i.e. are JSPs)



-David