Skip to content

Instantly share code, notes, and snippets.

@githubutilities
Last active August 29, 2015 14:17
Show Gist options
  • Select an option

  • Save githubutilities/41c918f10b529729339f to your computer and use it in GitHub Desktop.

Select an option

Save githubutilities/41c918f10b529729339f to your computer and use it in GitHub Desktop.
Dev Setup Java EE logs

Dev Env Setup for J2EE

  • install glassfish and tomcat by homebrew
  • install glassfish eclipse plugin by Help > Eclipse Marketplace

Installation

It seems that Oracle use glassfish for Java EE distribution on Mac. And there are modules directory under glassfish directory which contains javax.servlet and so on, refer to here.

Running Glassfish

# start `glassfish` default domain
asadmin start-domain

# download `hello.war` from [here]()

# deploy an app
asadmin deploy hello.war

# list running app
asadmin list-applications

# undeploy an app
asadmin undeploy hello

# stop `glassfish` default domain
asadmin stop-domain

Help Eclipse Find Glassfish

  1. Install Glassfish Plugin right from Eclipse Marketplace.
  2. Under File > New > Other > Server, config glassfish path to /usr/local/Cellar/glassfish/4.1/libexec/glassfish if you install glassfish using homebrew.

you may like to change elipse default web browser in eclipse preference panel.

Troubleshooting

If you got database connection refuse error while deploying an app, try to run asadmin start-database.

Reference

Display the source blob
Display the rendered blob
Raw
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment