I don't think you are providing enough informations to get an answer about your current problem (e.g. The EAR structure).
I don't think you are providing enough informations to get an answer about your current problem (e.g. The EAR structure). Anyway, if you don't have strong modularity needs, my suggestion would be to use the WAR packaging (with Java EE 6, using an EAR is not mandatory and you can package EJBs under WEB-INF/classes or under WEB-INF/lib if you bundle them as EJB-JAR). Oh, by the way, I'm deploying a Java EE 6 EAR on GlassFish and it just works.
Thanks for your reply. I've tried other ear files, with ejbs, and I successfully deployed them to glassfish. I'm just having problems with one project.
If I put all EJBs in a EJB Module, everything works fine, but as soon as I annotate a class from the WEB module with the @Stateless annotation, I start getting the error. – Carlos Ferreira Nov 5 '10 at 16:10 @Carlos I'm not sure I'm following everything. Are you using a WAR only or an EAR?
In the former case, double check the version of the deployment descriptor of the webapp. In the later case, why are you adding EJB annotations in the web module? – Pascal Thivent Nov 6 '10 at 9:39 @Pascal, I'm using an EAR.
I don't think it's a question of why am I using an EJB annotation in the WEB module, the real question is: why can't I? I've cheched an example from the netbeans website (The NewsAppEE6 application) and they use EJB annotations on the web module (@Singleton and @LocalBean). If I use the same annotations in one of my classes I can no longer deploy the application.
I don't have to use an EAR, I can easily use a WAR, but I just wanted to understand what is causing this error. (BTW, the deployment descriptor is using version 3.0) – Carlos Ferreira Nov 8 '10 at 8:57 @Carlos It definitely is! The examples on the NetBeans website are very likely using a WAR packaging.
However when using an EAR packaging, I don't think you can package EJBs in your WAR. Why? Because that's not how things are specified.So while you can waste your time trying to understand why a container doesn't implement something that is not part of the spec, my suggestion would be to follow the rules.
Either package your EJBs in a WAR and use a WAR packaging or put them in EJB-JARs if you use an EAR packaging. – Pascal Thivent Nov 8 '10 at 9:13 @Pascal The example I'm talking about is using an EAR packaging (In fact, I looked for examples that were using Enterprise Application Projects instead of Web Application). I had no trouble deploying it, and it has EJB annotations in the Web module.
I'm just wondering why that project works normally and mine doesn't, but, like you've mentioned, I'm just wasting my time. Thanks for your help though. – Carlos Ferreira Nov 8 '10 at 9:25.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.