JBoss Tools 4.1 with Eclipse JavaEE bundle, but why? - eclipse

On the JBoss Tools website they recommend explicitly to use Eclipse JavaEE bundle for the Tools. But when I install 4.1.1 (with all checkboxes) on a Standard Eclipse bundle, I have everything what JavaEE bundle has, with the ONLY execption of Mylyn (but therefore additionally Source for JDT and PDE). Or do I have a "missing link" here?

We state that Eclipse JavaEE is recommended since then you:
A) have 90% or so of all the required dependencies anyway (faster install)
B) get all the functionalities of Eclipse JavaEE/WTP available to you instead of "just" the ones JBoss Tools explicitly rely on. (more consistent functionallity)

Related

Does Eclipse Java EE IDE come with Tomcat?

I am wondering if I need to download and install Tomcat separately or if it comes with the latest version of Eclipse EE?
You will need to download Apache Tomcat separately, but you are not required to install it. In fact, it's simpler if you don't. The best layout supported for getting the required Java EE runtime libraries from Tomcat as well as launching it from Eclipse is the one from the unpacked tar/zip files.
Apache Tomcat and Eclipse has different types of license, and AFAIK Eclipse is "more free".

JSF and Richfaces on JBoss AS 4

I need to develop a presentation layer for an existing Java EE application running on JBoss AS 4.2.1.GA. I have been reading on JSF, Facelets and RichFaces and tried a few examples - some things worked but others didn't because of the limitations of library versions I used, considering the outdated JBoss.
Can someone recommend the direction I need to be heading to get this done as quickly as possible by using the mentioned server? By this I mean the Eclipse tool (WTP, JBoss Tools, ...), type of project, dependencies, ... Also, to shorten development time, maybe also use JRebel?
I know I would be better off using the latest server, but unfortunately it is not an option.
Also, I have installed JBoss Tools for Eclipse Indigo, but for creating RichFaces Project, it requires JBoss EAP 6 or AS 7.1.
I had created applications using JSF 1.2, RichFaces 3.3.3, JBoss Seam 2.0.2 (not required) for JBoss AS 4.2.2.GA. For development was used Eclipse (3.4/3.5) IDE for Java EE Developers. Version of Eclipse is not important. Yes, you need WTP. In my projects seam-gen was used for generating project skeleton. If you don't use Seam you can create Web project.

Compiling and running an OSGI application in Eclipse

The base of our enterprise application is OSGI and we have several Java projects that are logically OSGI bundles. We use Maven to compile the application using the Maven Bundle plugin. But this process is time consuming and makes it impossible to debug the application. We also use the Runner and Pax(:provison) plugins to run the application. If we could rely on the Auto build function of Eclipse and also debug the application it would make our lives so much easier. Is there a way to configure Eclipse to be able to compile (and may be run) an OSGI-based application?
I'm not entirely sure if I understand you, but here goes.
Well, running/debugging OSGi applications in Eclipse is really easy, as long as your bundles reside in PDE aware projects or at least are on your target platform.
Do you have the source of all your bundles? Debugging without source isn't all that useful. If you do, can you just import all the source of your bundles into your Eclipse workspace?
Otherwise you can create a target platform, add all your bundles to that. (as a first attempt, I'd say dump all your bundles in a directory and point the target platform there)
Either way, then you should be able to Run (or debug)-> OSGi framework -> New -> Pick your bundles -> Start
You can both pick bundles from or target platform and from your workspace.
For building, you can use Eclipse Plugin Development Environment (PDE). Despite its name, it isn't specific to building Eclipse plugins and can be used for working on pure OSGi bundles. Eclipse plugins are OSGi bundles with some extras.
Cannot help you with the running or debugging part, although I do know that some enterprise-oriented OSGi platforms provide extensions to PDE.
If you're already using the maven bundle plugin, you may find that PDE's manifest-first approach isn't a good fit with your existing code-first build (I assume at the end you want both an IDE build for development and debugging, and a command-line build for continuous integration and automated testing).
You have two choices. As others have suggested, you can use Eclipse's integrated PDE, and use Tycho for your maven build. Tycho uses the same data used by PDE, so you don't have to write things down more than once. Alternatively, you can stick with the maven bundle plugin and use bndtools within Eclipse. Like the bundle plugin, bndtools is code-first, so you won't need to worry about maintaining manifests. However, you may find there isn't quite as big a set of features in bndtools as in PDE, and I'd suggest still checking your manifests by hand to make sure you understand what's being generated. Whether you prefer manifest-first or code-first is a bit of a heated philosophical debate.
Look at bndtools. bndtools is using the same bnd that is underlying the maven bundle plugin. You can even use bndtools together with m2e. bndtools is available from the Eclipse market place.

Eclipse plugin for Facelets files

I have checked this question but it seems outdated now. Are there any plugins for Eclipse that supports Facelets/XHTML files and eases the development?
Both the Glassfish Eclipse Plugin and the JBoss Tools Plugin supports Facelets files and autocompletion of JSF tags. The JBoss Tools Plugin also adds EL autocompletion support to this.
The Glassfish Eclipse Plugin only works when your target runtime is set to Glassfish and the JBoss Tools Plugin only works when your target runtime is set to JBoss AS. JBoss AS is deep under the covers the same as Tomcat (which is just a simple Servlet container), but then enriched with a lot of additional Java EE aspects such as JSF, EJB, JAX-WS/RS, JMS, etc.

Eclipse Indigo (EE) + Java EE 6. Where are the classes in "javax.*"?

I've just installed Eclipse Indigo for EE and Java EE 6 SDK/JRE from Sun. I need all those to compile a 3rd party Java project using the "javax.*" classes. What I cannot understand how to reach those classes?
How can I import or otherwise connect to "javax.*" classes inside Eclipse?
They're in the Java EE implementation. In other words, they're in the application server. For example, Glassfish, JBoss AS, Tomcat, etc.
In Eclipse, just integrate the target server in Servers view and associate the dynamic web project with it. You can select it during dynamic web project creation wizard:
or afterwards via Targeted Runtimes in project's properties:
Once associated the project with the application server, Eclipse will do all the necessary magic to make those classes available during compiletime. To verify it, the associated server should be listed as Library in project's Build Path property:
Note once again, you don't need to change/fiddle anything in there! If you did some attempts beforehand while shooting in the dark in order to "fix" this problem, then you should make sure that you've undone it all, or things may still go wrong.
See also:
How do I import the javax.servlet API in my Eclipse project?
Make sure you have all the settings in preferences set. Go to 'Window' -> 'Preferences' and then check the 'Installed JREs', point it to your newest and greatest jre within downloaded jdk. If that doesn't work, download jdk and eclipse Java EE again and start from scratch. Also make sure you have a java and javac added to your PATH (either on Linux or Windows)