Export Play Project as Eclipse Project

Play Framework - Build Modern & Scalable Web Apps with Java and Scala

 

In this article we will see how to export Play project as Eclipse project. To do that follow the below steps.

Step 1: Add the SBT Eclipse plugin details to the plugins.sbt file resides under <Root_Project_Folder> –> project.

addSbtPlugin("com.typesafe.sbteclipse" % "sbteclipse-plugin" % "4.0.0")

Step 2: Move to the project root folder on the command prompt and run the below Activator command.

D:\My_Learnings>cd Learning_Play_App
D:\My_Learnings\Learning_Play_App>activator eclipse

Now, you are able to see the Eclipse project related files under root project folder.

Step 3: Export the project into Eclipse.

Play Eclipse Project

 

Now, you can use Eclipse as your IDE to work with Play project. You can modify/add the code by using Eclipse.

Step 4: Open the command prompt and move to the project root folder to start the Play application. Modify/add the code from Eclipse and refresh the page to see the update. No need to restart the Play application for changes which you are doing in Eclipse.

D:\My_Learnings>cd Learning_Play_App
D:\My_Learnings\Learning_Play_App>activator run

Step 5: As a developer, some times we require to debug the application in Eclipse. For that, we need to launch the Play project in debug mode and do the debug configurations in Eclipse. From the command prompt, move to the project’s root folder and launch the application in debug mode.

D:\My_Learnings>cd Learning_Play_App
D:\My_Learnings\Learning_Play_App>activator -jvm-debug 9999 run

I have used “9999” as the port to debug. You can use any available port over there.

Now, you can go ahead and do “Debug Configurations” by providing “9999” as the port.

You are done to use your favorite IDE for Play Java application development.

Advertisements

I am Siva Prasad Rao Janapati. Working as a software developer. Has hands on experience on ATG Commerce(DAS/DPS/DCS), Mozu commerce, Broadleaf Commerce, Java, JEE, Spring, Play, JPA, Hibernate, Velocity, JMS, Jboss, Weblogic,Tomcat, Jetty, Apache, Apache Solr, Spring Batch, JQuery, NodeJS, SOAP, REST, MySQL, Oracle, Mongo DB, Memcached, HazelCast, Git, SVN, CVS, Ant, Maven, Gradle, Amazon Web services, Rackspace, Quartz, JMeter, Junit, Open NLP, Facebook Graph,Twitter4J, YouTube Gdata, Bazzarvoice,Yotpo, 4-Tell, Alatest, Shopzilla, Linkshare. I have hands on experience on open sources and commercial technologies.

Tagged with: , ,
Posted in Frameworks, Play

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

DZone

DZone MVB

Java Code Geeks
Java Code Geeks
%d bloggers like this: