I was just wondering where exactly i could get the javadocs for jboss libraries?
Whenever i mouse over some element from a certain framework(eg. servlets) pops up with
Note: This element neither has attached source nor attached Javadoc and hence no Javadoc could be found.
I am currently using Eclipse.
You need javadoc for the Java EE specifications as JBoss is an implementation of it.
So get the javadocs for Java EE specification that your JBoss is implementing.
You can download the javadoc for Java EE 6 from here :
Java EE 6 Update 2 Javadocs
You should actually be looking into getting the generic JavaEE API documentation into your Eclipse, and not the one specific to JBoss. After all (in a perfect world) your code should only depend on generic JavaEE features, not the JBoss implementation.
As for how to get JavaEE Javadoc, these two questions should explain it all:
Enabling full documentation for Java EE in eclipse
Integrating Javadoc for Java EE 6 API into Eclipse
Related
After added the great feature of Java Module that can run custom JRE for specific application developed and Jakarta for develop the web application or enterprise application which can run Jakarta 9 , I can't understanding method to create web application with java! the question is if I need java 11(or 8) to create web application and Jakarta 9 do I need the Custom JRE that create with module ?
No, it is no required. Actually, the spec is silent in the way or application is deployed.
Currently, there is no more concept of JRE, using newer JDKs, only JLinked images, where you can select only the modules you need.
For now, only Java 8 is supported officially, with support for Java 11 coming shortly.
The specification doesn't mention anything about the Java module system. However, if you want to use modules, you could that a look at the Piranha Cloud project.
https://piranha.cloud
[Disclaimer: Piranha Cloud developer here]
Is it possible to run resteasy or any jax-rs implementation in java se. Without the use of servlets container or javaee application container
Since Java SE 6, there's a builtin HTTP server in Sun Oracle JRE. The com.sun.net.httpserver package summary outlines the involved classes and contains examples. In theory that one could be used to run resteasy i guess.
Note: this is only available in the JVM as provided by Oracle!
The following answer simple-http-server-in-java-using-only-java-se-api provides more details regarding providing a servlet with plain java se.
I know a few official sources like the java Java EE 6 tutorial.
But I was wondering, which one are the official sources for properly learning the spec of every API and any other resource related to the Java EE environment? Which resources ppl use to keep track of future versions without being actively participating of any container or spec development?
I hope this question is specific enough by suggesting only official links.
EDIT:
About https://java.net/projects/javaee-spec/pages/Home. It has a lot of links for several document versions and optional content. I wanted just one single resource for each API, a complete version. Let's take for example the annotated ECMAScript 5 spec (http://es5.github.io/).
Assuming the links are permanent it would be very nice to point out the complete documents for the APIs from Java EE 6.
Java EE 6 APIs are available at:
http://docs.oracle.com/javaee/6/api/
These can be downloaded from:
http://www.oracle.com/technetwork/java/javasebusiness/downloads/java-archive-downloads-eedocs-419425.html#java_ee_6u1_docs-JPR
https://java.net/projects/javaee-spec/pages/Home
But not really sure why you couldn't google that.
I installed Java EE Eclipse and am trying to get at ServletContextListener but see that its not available when I try to search for it in my JDK. According to the API docs its located under javax.servlet package, but I can't seem to find the JAR anywhere.
Same for a lot of JMS classes. Guess I'm just confused where a Java EE developer is supposed to go for Java EE jars. Thanks in advance!
The Java EE jars are typically part of your web container or EJB implementation; e.g.
Tomcat,
Jetty,
Glassfish,
JBoss,
Websphere,
etcetera.
Note that some of these only support a subset of Java EE technology, and accordingly have a smaller footprint.
The other alternative is to look on the Oracle website (or elsewhere) for a stand-alone implementation. For instance, Oracle provides a stand-alone JAR file for "javax.mail", which is part of Java EE.
For a beginner Java EE developer I (and many others before me) recommend not using the IDE and configure everything you need manually (at least once).
If you choose Tomcat what you're looking for is servlet-api.jar.
In brief the steps you would take to develop and use a class that implements ServletContextListener:
Download Tomcat (or any of the other servlet containers listed in the other answer).
Include Tomcat's servlet-api.jar in the compile classpath.
(Optional) Package and deploy to tomcat.
We often say that the particular application server is a Java EE compliant server. But I am still not completely aware of what it means exactly. Need more information on this.
It means that it passes the Java EE Technology Compatibility Kit.
Sun (now Oracle) created the specification for Java EE (previously called J2EE) along with a large test suite checking that the application server behaves as the specification requires. This is a non-trivial test to pass, but means that if you write your application according to the Java EE specification it will be able to be deployed and executed on any Java EE application server (of that level).
Note that the configuration is outside the specification. This means that the configuration of the application server to provide the things your application needs, is non-standard and it may be a quite substantial effort for you to add support for a new application server.
What Thorbjørn Ravn Andersen said is perfect. Also, the Java EE 6 Technologies page lists the technologies included in Java EE 6 specification. You can consider any Application Server fully implementing these to be Java EE-Compliant.
Also the Compatible Implementations page lists the list of AS compatible to each Java EE version.