Recent activity
Subscribe to this feed
monkeyfeet replied on November 07, 2009 14:33 to the question "How do I tell appClient what class to run?" in javaee6:
monkeyfeet replied on October 29, 2009 09:35 to the question "How to create the sequence table?" in javaee6:
monkeyfeet replied on October 29, 2009 09:34 to the question "How do I tell appClient what class to run?" in javaee6:
HI, yes I've tried that but chapter 13 has both a sender and receiver class.
The main class defined in the manifest runs when I use appclient but I'd like to be able to run any class from the jar without having to change the class in the manifest, i.e. start one jvm running the sender and start another running the receiver but both using the same jar
monkeyfeet replied on October 15, 2009 11:24 to the question "How to create the sequence table?" in javaee6:
I obiviously don't know enough about Derby to fix this problem by using my brain and instead I've succeeded on luck.
The database now seems OK but I couldn't repeat what I did wrong and/or right.
Chapter 10 was missing a class called EuroConverter but its in chapter 12, if you copy it into chapter 10's code, rebuild and redeploy, the web application is now working.
btw, I do realise that this question has turned into a conversation I'm having with myself but if it helps somebody out, great.
monkeyfeet replied on October 14, 2009 07:39 to the question "How to create the sequence table?" in javaee6:
Well I tried creating the table and then changing the ddl property from "create and drop" to "update" but it still giving me errors.
I'm wondering if its because the app isn't re-deploying or un-deploying properly. I've use the admin console and then hacked the domain.xml file when necessary as well as clearing out the war from any folder I can find.
But now Glassfish tells me the app already exists when I try to deploy the amended version.
I'll keep trying but I don't have a lot of free time at the moment so if anybody's got any ideas, I'd love to hear them.
monkeyfeet asked a question in javaee6 on October 12, 2009 20:26:
How to create the sequence table?More Chapter 10 issues...
the derby database server is running but it fails with the following:
Caused by: org.apache.derby.client.am.SqlException: Table/View 'SEQUENCE' does not exist.
If the persistence.xml uses the create-drop property, how does the sequence table get created?
monkeyfeet asked a question in javaee6 on October 11, 2009 10:57:
How do I tell appClient what class to run?Does anybody know how to use appClient in Glassfish to run a class when you want to run a class different to the one specified in the manifest? I've been trying using the mainClass parameter but it ignores it and just uses the one in the manifest. It would be useful in Chapter 13 where you have several classes, and you want to run the JMS sender and JMS receiver without changing the manifest in the pom.
I'm probably just using the wrong options but I've specified the jar and mainClass but not having any luck?
monkeyfeet replied on September 30, 2009 07:45 to the question "can't use ant with linux(ubuntu)" in javaee6:
monkeyfeet marked one of medi's replies in javaee6 as useful. medi replied to the question "Problem with the test in "org.javaee6.chapter02.BookTest"".
monkeyfeet replied on August 25, 2009 16:21 to the question "Blocking problem or not ?" in javaee6:
monkeyfeet replied on August 21, 2009 11:40 to the question "Problem with the test in "org.javaee6.chapter02.BookTest"" in javaee6:
Not sure about this one. I only things I can think of are:
does your pom.xml file in the root folder (the pom.xml with the name of "chapters") have a repository entry for Apache?
I think (and I'm really not sure) that the embedded driver using a url to specify using a meory based db) is a recent addition to Derby so you may need to get a newer version of Derby from Maven repositories.
As I say, I'm really not too sure on this but its the only thing that pops into my head.
Mike
monkeyfeet shared an idea in javaee6 on August 21, 2009 11:31:
XML Mapping and Annotations MappingThis isn't a problem as such but the book and the code don't make something explicit.
In chapter 3, the section on mapping with XML shows the Book Entity class without a table annotation but the code that can be downloaded does have such an annotation. The XML mapping also has a table definition but for a different table name than that defined in the annotation.
The important thing to note here is that this does not cause any error but running the test case for the code will show the XML mapping takes place over annotations, which is mentioned in this section of the book although the example given is for a Column annotation against a column xml mapping.
I've posted this just in case anybody else is a bit confused when they look at it.
The good thing is that it does prove that XML takes precendence over annotations, for table names and columns.
monkeyfeet replied on August 21, 2009 10:07 to the question "Blocking problem or not ?" in javaee6:
monkeyfeet replied on August 20, 2009 20:50 to the question "Blocking problem or not ?" in javaee6:
Medi,
sorry to say but the chapter 2 test code works fine for me.
So, the only things I can think of are:
Are you using the latest code from Antonios site?
Are there any Maven warnings when building and/or testing? I had some warnings about the version of Derby but nothing that stopped the tests from running?
I'm was having a probem with the Main class in src/main/java/com/apress/javaee6/chapter02 though, it was giving:
Exception in thread "main" java.lang.NoClassDefFoundError: javax/persistence/Persistence
which is strange.
But then I tried running the file from the command line instead of from Netbeans (which is becoming my favourite IDE).
I typed:
mvn exec:java -Dexec.mainClass="com.apress.javaee6.chapter02.Main"
and it worked!
Good bug hunting.
Mike
monkeyfeet replied on August 20, 2009 14:13 to the question "Blocking problem or not ?" in javaee6:
-
monkeyfeet started following the idea "Test Super classes still get run and fail" in javaee6.
-
monkeyfeet started following the idea "Test Super classes still get run and fail" in javaee6.
monkeyfeet replied on August 19, 2009 11:21 to the question "Blocking problem or not ?" in javaee6:
JEE6 as a specification is now quite stable but the Glassfish implementation is still going through work. JEE6 is still bleeding edge really but I've been very impressed with the book so far.
However, I see no reason not to buy the book and get started with the source code.
It can be frustrating to have to handle the inevitable code issues and maven repository issues but this site is proving useful for solving the problems.
I've been very impressed with the content of the book and the updates Antonio has made here.
I think there's plenty in the book to learn even if some of the downloaded code and/or Glassfish implementation is not 100% yet.
Mike
monkeyfeet replied on August 18, 2009 15:53 to the problem "Eclipse Maven URL Wrong?" in javaee6:
Struggled with this for a while then realised after I'd tried to use Eclipse's maven repository again, it was failing because I had a typo.
http://www.eclipse.org/downloads/down...
does seem to be working.
monkeyfeet replied on August 17, 2009 18:06 to the problem "Eclipse Maven URL Wrong?" in javaee6:
Those JPA jars don't like to stay in the same place for long.
The temporary URL doesn't work anymore and I think there was a slight problem with the repositories listed in the parent pom (chapters) because they're both the same.
Two repository definitions point to the same URL:
<repository>
<id>EclipseLink Repo</id>
<name>Eclipse maven repository http://eclipse.ialto.org/rt/eclipseli...</name>
<url>http://mirror.csclub.uwaterloo.ca/ecl...</url>
</repository>
<repository>
<id>Temporary EclipseLink Repo (should be replaced by the previous one)</id>
<name>Eclipse maven repository http://eclipse.ialto.org/rt/eclipseli...</name>
<url>http://mirror.csclub.uwaterloo.ca/ecl...</url>
</repository>
Antonio, could you tell us the right one to use?
Cheers
Mike
| next » « previous |
Loading Profile...

