There is a lot of information about Java around, but I don't understand how to setup everything.
I have a Mac. I heard the JDK comes with Macs. But is it the latest? How do I check that? Is it the J2SE or J2EE?
I want to create a web app. I installed NetBeans. When I choose create project there is a list of Java options. There is Java/Java EE/Java FX/Java Web. Which one should i choose? and afterwards, what is what? What is War?
I want to find a good tutorial/ebook explaining all these Java terms and how to setup Java/Java Server(Glassfish/Tomcat) on a Mac and with NetBeans to code a web app? A good one!
The netbeans tutorials can be found here: http://netbeans.org/kb/trails/java-se.html
To start off, just make a plain Java project. The other types all probably include different plugins or libraries that you won't need right away. A WAR is an archive of Java classes and other files that constitutes a web application.
The default version of the JDK that you have on your Mac should be fine, but if you want to upgrade or mess around with any other Java preferences, OS X offers all that for you. Apple has a good tutorial here: http://developer.apple.com/java/faq/
Edit: Ok, if you want to make a web app then the first step is to learn how a Java web app is organized. That will make your life much easier. Java EE is mostly a buzzword (IMO) and it refers to a specific set of libraries. It's not important to know what's officially considered Java EE and what isn't. To learn about what a Java web app looks like, the best place is the Tomcat manual. Read this section, then make a WAR project in Netbeans and you should have a good start. Don't try to bite off too much at first, just make a Hello, World! app.
An excellent resource for learning Java development is Java Passion.
There you can learn basic Java development, and the Java EE tutorials will also get you started developing web applications.
Here are some links on how to setup Tomcat / Glassfish for Mac OS X.
Tomcat on OS X
Glassfish on OS X
Trying to go straight into Java Enterprise Development is going to be too steep a learning curve unless you already know Java. Take a step back, and start going through some Java Tutorials.
It will likely be a while before you can tackle Java EE (it can be a monster).
Related
I recently received a macbook pro.
I wanted to to learn java,jsp and develop some sample web applications in my local machine.
Can anyone provide me a specific link where I can perform the following on my Mac Os to get started:
Install Java
Install an IDE.
set up tomcat
Tutorial for creating learning sample program that contains java,jsp
connect to a local db and test it out in my local web browser.
I know there are lot of different instructions in the web, i would appreciate if some of the experts here point me to the best way to get started .
Will already be installed on a mac
I would suggest either IntelliJ or Eclipse as two examples of good Java IDEs. Both have very good support for developing web applications in Java. The IDE question is probably never ending, so it's really a case of what works for you.
For Tomcat you can't beat these instructions.
Each framework has its own instructions. Perhaps start with Spring or Play! for java
This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
Java: A good introduction to J2EE platform for noobs
I'm not new to programming at all - I've programmed in .net for over a decade. I have dabbled now and then in java, but never at an enterprise level. Now I'd like to learn to use Java EE.
What are some good online resources, or books that I can buy? I'll need a step-by-step on what to download to set up my environment (I already have the Glassfish tools bundle for eclipse, but I'm not sure if this is what I need or where to go with it...).
I think coding a simple website to perform basic crud operations would give me a good start.
To begin with, I'd stay away from anything that says J2EE as it's an outdated uglier version. Look for Java EE 6 or at least Java EE 5.
Apart from that my recommendation would be to download the Java EE version of Netbeans
since it has everything you need. In the same site there several starting tutorials and a longer e-commerce tutorial
If you want to start with Servlets and JSPs in Tomcat, just make sure it is selected during the install procedure.
Glassfish is fine. You might consider JBOSS as well; it's another Java EE app server that's open source and won't cost you a thing to try out.
I'm not sure if WebLogic from BEA/Oracle is still available to download for developers to learn, but it's my favorite Java EE app server. Version 9/10 from BEA, before Oracle bought them, was simply the best.
You can start with a servlet/JSP engine like Tomcat or Jetty. You would begin with servlets (HTTP listeners that respond to GET/POST requests); JSPs (a templating language using tags that are compiled into servlets and executed on the server - think of them as servlet/HTML factories); and JDBC (relational database connectivity). You can go a long way with just those.
Once you've mastered those you can decide between a Java EE solution (EJBs) or Spring. Spring is not part of the Java EE spec, but it's a fine alternative. It's a combination of dependency injection, aspect oriented programming, and solid modules for persistence, remoting, messaging, web services, web MVC, LDAP, etc.
The NetBeans IDE is not so ubiquitous as eclipse (so eclipse is a very good choice), but makes Java EE 6 with Java 7 and GlassFish very easy. And netbeans.org has several tutorials.
I love eclipse and java. And i want to code my entire web application using eclipse .. right from designing html files to servlets.. I have zero experience in developing web apps .. So How to to setup eclipse for web apps and How do i get started ???
Google even autocompletes this question so you know it's a popular query!
There is very little information that you are providing, and there are actually tutorials for creating web applications with Eclipse and Java. You will want the JavaEE version of Eclipse as a starting point.
If you want to try using a web framework that works with Java I recommend Struts, although this may be too big if you're wanting to develop small web applications (and it's not exactly the easiest thing to start with).
I also recommend installing Apache Tomcat as your server because it's free and easy to use. Here's a good starting tutorial:
http://www.xwt.org/tutorial/eclipse/
Firstly, make sure you've got the Java EE eclipse binary : http://www.eclipse.org/downloads/
As has been mentioned, there are various google-able tutorials on how to set up, deploy and manage web applications under eclipse.
Hello good fellas i'm sure everybody is cool.I'm about to start a tutorial about jsp and jsf and the required tool is eclipse for j2ee and web tool platform.I'm a bit confused about where to find it bundled with wtp? and in which distribution is it Europa , Galileo or Ganymede ?.i know that it's here in
entreprise java because it's clearly written there but then i don't know whether it's good for me, the main idea being to add jboss-tools to in order to use jboss seam.Please correct me right away if i'm making some foolish assumptions.thanks for reading
Go for Galileo, its the latest. To me they chose names, instead of or along with versions, to make it easy to choose and remember, but apparently made it much difficult to choose.
See this, wikipedia entry, for clarification on releases.
The Eclipse downloads you mentioned are all good candidates. I use the Ganymede (3.4) version but plan to try Galileo (3.5) soon as it is finished now (thanks #Vinegar).
I have also good experience with the non-free MyEclipse and I'm sure, Netbeans and Intellij have similarly good support for J2EE along with potential JBoss/Seam support.
You could test your installment by creating a JSP and check if you get syntax highlight for HTML and java snipplets.
I am fairly comfortable with standalone Java app development, but will soon be working on a project using a Java EE application server.
Does anyone know of a straightforward how-to tutorial to getting a hello-world type application working in an application server? I'm (perhaps naievly) assuming that the overall approach is similar between different frameworks, so I'm more interested in finding out the approach rather than getting bogged down in differences between the different frameworks.
If you are not aware of a good guide, then could you post bullet-point type steps to getting a hello-world running?, i.e.
Download XX
Write some code to do YY
Change file ZZ
Other steps...
Note: Just because I have a windows machine at home, I would prefer to run if this could be run on windows, but in the interest of a better answer, linux/mac based implementations are welcome.
I would choose JBoss AS or GlassFish for a start. However I'm not sure what you mean by Java EE "Hello World". If you just want to deploy some JSP you could use this tutorial (for JBoss):
http://www.centerkey.com/jboss/
If you want to get further and do the EJB stack and/or deploy an ear-file, you could read the very good JBoss documentation:
Installation Guide
Getting started
Configuration Guide
In general you could also just do the basic installation and change or try the pre-installed example applications.
I currently have JBoss installed (on windows). I develop with Eclipse and use the Java EE server integration to hot deploy or debug my code. After you get your first code running you realy should have a look at the ide integration since it makes development/deploy roundtrips so much faster.
The JavaEE (they dropped the 2) space is pretty big. A good tutorial to start is the one from Sun. For a simple hello world application, the web container only would suffice. A well known servlet jsp container is tomcat. See here for installation instructions. Try installing it with eclipse and create a web project. This will generate some files for you that you can look at and edit. Also starting and stopping the application server is simpler.
Another option is to get Oracle JDeveloper (free to download and use - it's a full featured IDE that includes some neat extras like the SQL workbench and BPEL designer).
As a learning tool, it is quite good, not only for the tutorials available from Oracle, but it includes a range of "cue-card" lessons in the tool itself to teach many common techniques.
cue card view http://tardate.heroku.com/images/jdev-cuecards.jpg
If you haven't gone near NetBeans in a while its catching up with Eclipse very fast and worth a look, especially when starting Java EE.
Version 6.x installs Tomcat and/or Glassfish for you and then provides wizards to create/deploy/redeploy applications.
The initial tutorial on Web Applications is here and a more complex example here.
As JeroenWyseur puts it, Java EE is a fairly big space. In addition to what he said, you should try to get more details of what exactly you'll be doing: servelts & co, EJB (entity, session, message beans?) and try to get familiar with that.
It should be clear for you that your code runs in a managed environment, which imposes a lot of constraints. in order to make sure you understand what happens you should get familiar with the concept of deployment. Then, if you do EJBs, transaction management is important too. If you don't understand exactly what happens when a bean or a servlet is deployed, how transactions are managed, how beans are invoked, you're going to have a hard time.
A book that helped me a lot back in the time is Mastering EJB, by Ed Roman.
Also, getting familiar with RMI will help you understand EJBs.