Remote connection between Intelij and Tomcat running on unix machine - java

Am getting into java web development and currently web server (tomcat) is running on the same laptop I use for coding. Now, I want to install FreeBSD on other computer, then install stuff like tomcat, some db server to learn more about unix and have a more real world environment. Idea is to have my laptop for coding (it uses win7 and InteliJ as IDE) and this other computer (freeBSD on it) for server side stuff. So my question is, how do I make this happen? Is there a way to connect intelij to that computer and have intelij acces its file system where my web related stuf would be stored. That sounds like a good way to do it. Give me some advice and pointers, Thanks !

Not sure if this is what you want.
IntelliJ will allow you to remote debug an application in the tomcat server. However to have IntelliJ reload the application to tomcat requires the ultimate edition of IntelliJ.
That said you can write scripts or use Maven (Ant or Gradle) from within IntelliJ to deploy your application to Tomcat, its more clunky than the remote deploy option with ultimate.

Related

Connecting IntelliJ to weblogic server

I have a server that it has weblogic on its own. I develop my program with intelliJ. Can I connect intelliJ to the weblogic server and just run and deploy the project from intelliJ (just like when we use Tomcat application server on our local and start/stop that with intelliJ)?
You indeed can. You can create a Run/Debug configuration for WebLogic same way as for Tomcat, but you might see it as an option only after you click N items more (irrelevant), which is at the very bottom of the list.
Also, this is supported only in Ultimate edition. If you're using community edition, you can't do that from the IDE.
The process of configuration is also described in Intellij IDEA's guides

running spring mvc openshift application locally

I have created an Java app on openshift platform with JBoss Application Server 7 and MySQL 5.5 using eclipse and Jboss Openshift Tools. Now I wannt to run this application on localhost but I am unable to find any option to do so.
I googled and followed some links and was able to create jboss-as-7.1.1 server but cannot figure out how to run the application using this server as there is not option to select a server in Run As window of eclipse. Do i need to modify anything in project settings?
Did you create a server adapter for your jboss-as-7.1.1 in Eclipse? I assume you did so it looks like your project is missing the required Eclipse WTP nature. Maven project (like any OpenShift Java app) get those for free if you have m2e-wtp installed. To me it looks like you're missing that one (and eventually possibly Eclipse m2e) and need to install it.
Either use the Eclipse marketplace or point Eclipse to the following update site:
http://download.eclipse.org/m2e-wtp/releases/luna/

How to create an installation file server

I have a server java project, which runs on glassfish.
How does it put into the package and run on any machine and install it?
Glassfish is a heavy server. If you wants to deploy your application on several machines, you should use a lighter Java server.
You can look at theses project, which provide a package with an embedded Jetty web server (with startup scripts for all plarforms: Windows, Linux, Mac, Solaris, etc.).
http://jenkins-ci.org/
http://www.sonarsource.org/
http://nexus.sonatype.org/
Once your application can work on an embedded Jetty server, create an installer will be much easier (with InnoSetup, IzPack, etc.).
Making Multiplateform installer with Izpack is really easy and fun. You can package your application in installer and run on any machine. Just go through the tutorial here and you will have your own installer.

Set up Tomcat server on a Mac

I need to get a local setup of Java working so I can start coding locally and doing builds.
I know that Java is built into macs automatically. I am running version 1.6.0_22
I found an article on how to install tomcat:
Tomcat on a Mac
I got the Tomcat server running to where i can see the default Tomcat Page.
Started to dig deeper but hit a huge wall on getting to a point where i could use an IDE to get coding.
I downloaded Eclipse for the mac (because it was free and seemed to be the more popular one out there)
So where do i need to go from here to get a working environment to test code from our svn?
Any good articles that i can read. It was hard to find some (recent) documentation on how to get this working on a mac.
Which version of Eclipse did you download? I'm guessing you downloaded Eclipse IDE for Java Developers, which doesn't have the nice WTP stuff that you probably want.
You'll need a heavier flavor of Eclipse, like Eclipse IDE for Java EE Developers. I'm not sure if there's a lighter (in-between) flavor that has WTP, etc., without all the Java EE stuff.
Assuming you have some sort of SVN client and know how to create a trunk on your local machine, do that, and then all you have to do from there is open the java project in that trunk within Eclipse. Once you have that open, on the Eclipse toolbar just build your code, make sure that works, and then run it in the same fashion.

Having hard time to publish files to Tomcat from Eclipse

Sorry if my question seems dumb. I've started using Eclipse Ganymede 3.4 this week and having hard time publishing my projects to the web app server.
First of all you need to know this issue:
i installed my Tomcat 6.0.18 from Netbeans that i use for PHP and J2SE project. While i can start that server from either Netbeans or Eclipse, it can not start manually for some reason even though i setup my JAVA_HOME correctly pointing to jdk/bin it's saying it's a jre. it a bit weird but i can use the IDE to get going. i did some research on the net and find out that eclipse doesn't publish to tomcat.
In fact i always develop by having a local copy on other drive than C where XP is installed and publish to a server installed on C.
So where i need to find a way to publish to Tomcat under C.
It there any simple way to do that?
Please share your experience.
Thanks for reading
Ps : i know that i can use Netbeans but i'ld like to use Eclipse and use its wysiwyg
thanks!
WTP (Web Tools Platform) should get you what you need. It's a set of Eclipse plugins which includes a one to start/stop/debug Tomcat and publish to a local Tomcat installation.
http://www.eclipse.org/webtools/
You can download a version of Eclipse that already includes WTP: Eclipse IDE for Java EE Developers.
I admit this is not the best practice for a general case, but in my local development environment I created a separate Tomcat environment and I simply store the project itself in this Tomcat's webapps directory. This way the 'deployment' is implicit and instant.
Of course when I need to do changes in the code which cannot be incrementally added during a debug session, I have to restart the Tomcat.

Categories