Discussion:
[jboss-user] [Beginner's Corner] - implicit modules in development
jsm3031
2013-06-08 04:03:56 UTC
Permalink
jsm3031 [https://community.jboss.org/people/jsm3031] created the discussion

"implicit modules in development"

To view the discussion, visit: https://community.jboss.org/message/822098#822098

--------------------------------------------------------------
Hi,

I am used to eclipse doing a lot for me, so I'm trying to learn more about app servers, deployment, etc. I also switched to Intellij for a trial.

So, I have read up as much as I can, don't have enough time these days and appreciate help. I read the stuff on implicit dependencies in jboss, so for example if I use the @PersistenceUnit the dependencies will be added, but this doesn't work in development in the IDE, and in Intellij I have to use Maven dependency in the pom file or get intellij to download the jars into the projects lib folder or else the IDE can't resolve anything and it won't compile. These are easy enough solutions, but what i don't get is, it seems like the inclusion of these implicit modules by jboss is a deploy time thing (I also read you specify them in the manifest file) but if you have to use maven or download and add them to your lib directory to be able to develop then what's the difference between using tomcat and doing that then deploying them together or using jboss or other java ee compliant server (which i read that the benifit of using them is they come with all that stuff included)? Either way you have to get the dependencies into your project manually to develop. The only thing using the full featured ee compliant server seems to get you is not having to actually include them in the lib folder of the deployment artifact.

At least that's what I have observed. I like figuring out these details but I just don't have the time these days and I'm quite curious about this.

Thanks

jon
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/822098#822098]

Start a new discussion in Beginner's Corner at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2075]
Wolf-Dieter Fink
2013-06-08 10:09:54 UTC
Permalink
Wolf-Dieter Fink [https://community.jboss.org/people/wdfink] created the discussion

"Re: implicit modules in development"

To view the discussion, visit: https://community.jboss.org/message/822110#822110

--------------------------------------------------------------
Hi,
welcome to the forum.

There are several projects to help developers in JBoss, see the developer http://www.jboss.org/developer jboss way.
In each project/ide you have to declare dependencies, sometimes you will have a special EE distribution where such things are included or you have wizards for this, you might try the JBoss IDE based on eclipse or JBoss tools.

To create a maven project you can use http://forge.jboss.org/ forge it will simple create different types of projects.
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/822110#822110]

Start a new discussion in Beginner's Corner at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2075]
jsm3031
2013-06-08 16:42:01 UTC
Permalink
jsm3031 [https://community.jboss.org/people/jsm3031] created the discussion

"Re: implicit modules in development"

To view the discussion, visit: https://community.jboss.org/message/822130#822130

--------------------------------------------------------------
Thanks for replying.

I know it's not jboss specific and just something I don't understand about java EE in general I guess. I appreciate peoples' time for explaining it.

What I am failing to understand is, for example, JBoss AS 7 provides something like hibernate. It's found in /jboss-home/modules/org/hibernate/main/ and includes hibernate-core and JPA specific entitymanager, etc. But while developing in the IDE I still have add the libraries to the lib folder, use an IDE feature which fetches them some other way, or something like maven which puts them ~/.m2. I don't understand why these jars have to be in two places.

thanks again
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/822130#822130]

Start a new discussion in Beginner's Corner at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2075]
Wolf-Dieter Fink
2013-06-08 19:39:13 UTC
Permalink
Wolf-Dieter Fink [https://community.jboss.org/people/wdfink] created the discussion

"Re: implicit modules in development"

To view the discussion, visit: https://community.jboss.org/message/822134#822134

--------------------------------------------------------------
If you use a JEE application server you can code against the JEE API, which mean JPA, EJB, JSF... In this case you only need to include the JavaEE API's downloaded from Oracle site or by maven dependencies.

The reason for have that in different places is that the IDE need the reference to compile, Eclipse i.e. can use the pom.xml files (with maven plugin) to collect the references.
With an IDE you are able to use a GUI for programming, with Eclipse (EE bundle) you are able to produce the JAR/EAR directly.
Most developers use maven to be able to build from a shell and use automatic testing, the IDE will be only used as comfortable editor.

The EE spec delegate the runtime implementation to the server, if you use JBoss the JPA persistence is implemented by Hibernate. If you code against the EE spec you will not need to use Hibernate for developing - this is the idea off JavaEE as you have no direct dependency to a specific AS provider.
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/822134#822134]

Start a new discussion in Beginner's Corner at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2075]
jsm3031
2013-06-10 23:29:16 UTC
Permalink
jsm3031 [https://community.jboss.org/people/jsm3031] created the discussion

"Re: implicit modules in development"

To view the discussion, visit: https://community.jboss.org/message/822402#822402

--------------------------------------------------------------
Thanks for your help. You words have helped guide me in the right direction.
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/822402#822402]

Start a new discussion in Beginner's Corner at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2075]
Loading...