These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]

Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Chapter 2:Page 80 Java Persistence with Hibernate Nov2007ver
PostPosted: Sat May 17, 2008 11:55 am 

Joined: Fri May 16, 2008 1:42 pm
Posts: 10
This may be a chicken or egg thing. But it would be good if folder structure here on Page 80 provided a table to reconcile where resources exist. It's hard to see what's going on when you first hit this page!

(I hate unexplained forward references in books! They just cause tons of confusion)

I feel rather disgruntled that you didn't just list the jars!
I already had JBoss 4.2.2GA installed!
I downloaded jboss-EJB3.0_RC9_Patch1 just to try and find out what jars I need. And I still feel none the wiser.

1) Can someone give me a definitive list of what's required, so I can extract them out of JBoss AS 4.2.2GA (or RC9)?

BTW i) : url given for download is now http://www.jboss.org/jbossejb3
BTW ii) For any other readers in same situation. Listing 2.16 HelloWorld class uses org.jboss.ejb3.embedded.EJB3StandaloneBootstrap
I've been able to track this puppy down in a couple of places:
a) jboss-embedded-all.jar which is part of hibernate-search-3.0.1.GA in folder \lib\test
b) In jar jboss-ejb3-all.jar in two of the Caveat Emptor downloads (
caveatemptor-jpa-061211\lib & jpwh-gettingstarted-070401\helloworld-ejb3\lib)
Once again this is not in the jboss-EJB3.0_RC9_Patch1 download.
Why is nothing is where you'd expect it to be from reading the book?

It would be nice to know what the dependencies are for
Can someone let me know?

Actually it would be good if you folks (JBoss/Hibernate etc) did some sort of diagram showing jar dependencies or something similar to the way http://www.mvnrepository.com/ works.
If there is something like this already do you have url or is it buried in readmes you have to download?

2) default.persistence.properties..
Where is this sucker? It's not in download!
I've seen a persistence.properties file in ejb3.deployer folder of EJB3 download. The Caveat Emptor which exists for chapter 3 in download caveatemptor-jpa-061211 has a subset of these properties. Is this sufficient for chapter 2? (ANSWER YES.. Same in download jpwh-gettingstarted-070401)


3) ejb3-interceptors-aop.xml
Can I take this from jboss-4.2.2.GA\server\all\deploy?
(ANSWER NO.. The one in RC9 or is the one you want. It's also in jpwh-gettingstarted-070401 or caveatemptor-jpa-061211\src\etc\conf
They are all the same. Checked with Windiff...

AS 4.2.2GA uses DOCTYPE from labs.jboss.com and has <interceptor class="org.jboss.ejb3.remoting.ClusteredIsLocalInterceptor" scope="PER_VM"/> amongst other differences)

Started having to do Windiff on xml files to see which is best to use!
This is like pulling teeth! Not in keeping with rest of book to date.

4) embedded-jboss-beans.xml
Managed to locate one in Caveat Emptor-jpa-061211\src\etc\conf folder.
I can't think this relates to this chapter as it relates to quartz schedulers etc. Have been dealing with messages to this point!
(IT IS THE ONE YOU WANT. Compared this one to jpwh-gettingstarted-070401. Latter has extra bit of text saying not needed without JMS. Which helps. Didn't realize all the stuff I'd seen was commented out anyway. Create tables and quartz scheduler... )

Does a listing later talk of this? (No)

5) jndi.properties. Same as 2..
java.naming.factory.initial org.jnp.interfaces.LocalOnlyContextFactory
java.naming.factory.url.pkgs org.jboss.naming:org.jnp.interfaces

Is this sufficient?
Right can cross this one off. It's on middle of P85. Would be ideal to give listing # to two lines. And yep. It's the same...

6) log4j.properties
Is this the one from Listing 2.7 still?
NO. Source from jpwh-gettingstarted-070401\helloworld-ejb3\src\etc folder of download.
# Direct log messages to stdout
log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n

# Root logger option
log4j.rootLogger=INFO, stdout

# Hibernate logging options (INFO only shows startup messages)

# Log JDBC bind parameter runtime arguments

# JBoss EJB 3.0 container logging

# Disable warnings of noisy classes

Clarification, and general overhaul of this bit of book would be greatly appreciated.
Regards, Jeremy


Also noted:
A) Directory structure on P80 is missing items from src/hello

B) updated persistence.xml is on P82

Have also seen these posts in another thread

fast deploy to the slow deploy:
The new release finds out the system path separator automatically.
This "new" version is this talking about.. Is this in one of these three files:
caveatemptor-jpa-061211, caveatemptor-native-061211 or caveatemptor-0.9.5.zip downloadable from here:

Groan... I've just spotted the url which probably has the answers...
I'll shut up now crawl under the table in shame and have a dig around...
I could probably have been doing a lot less typing (Forum & source)! :)

Last edited by jgf on Sat May 17, 2008 6:18 pm, edited 6 times in total.

 Post subject: I've done some digging...
PostPosted: Sat May 17, 2008 4:30 pm 

Joined: Fri May 16, 2008 1:42 pm
Posts: 10
1) What are all these iml files?
Is it some sort of packaging thing, like Maven's POM?

2) I notice classes have been repackaged for ejb3 version into just 3 jars
Do you have some sort of Venn Diagram showing an overlap between original jars and these. I'm expecting you've amalgamated things. Care to share what's going on?

Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.