Recently I encountered a strange bug in eclipse after a colleague includes selenium in a pom file of a meven project. The eclipse complained " Error: archive required for library cannot be read". Detailed error like this:
"Description Resource Path Location Type Archive for required library: [root]/.m2/repository/org/seleniumhq/selenium/selenium-support/2.46.0/selenium-support-2.46.0.jar' in project '[*]' cannot be read or is not a valid ZIP file umom Build path Build Path Problem"
However, it was found that the selenium-support-2.46.0.jar is valid jar which can be open as zip.
After some searching, the following work around seems to work in my case (link: https://bugs.eclipse.org/bugs/show_bug.cgi?id=364653#c3):
Workaround: For each affected project set 'Incomplete build path' to 'Warning' on the Compiler > Building property page. After that, shut down and restart the eclipse. followed by update the maven projects. And the problem is gone
Showing posts with label Eclipse. Show all posts
Showing posts with label Eclipse. Show all posts
Friday, November 13, 2015
Tuesday, November 3, 2015
Create and Run Apache Spark Scala project using Eclipse and SBT
This post shows a simple way to create and run a apache spark scala project using eclipse and SBT. Following this post at link (http://czcodezone.blogspot.sg/2015/11/create-scala-project-using-scala-ide.html) to create a SBT-compatiable scala project in Scala IDE, open the build.sbt in the project and add the following line towards the end of the file.
Further more, since Spark needs to run a spark cluster in a jar, a sbt plugin must be added for the packaging. Create a file named "assembly.sbt" in the "project" folder under the root directory and put the following content:
Now in the command line, navigate to the project root directory and run "sbt compile", "sbt package" command after you put in your spark scala code, then "sbt run" or "spark-submit" depending on whether you want to run it locally or submit to spark cluster
libraryDependencies += "org.apache.spark" %% "spark-core" % "1.5.1"
Further more, since Spark needs to run a spark cluster in a jar, a sbt plugin must be added for the packaging. Create a file named "assembly.sbt" in the "project" folder under the root directory and put the following content:
addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.11.2")
Now in the command line, navigate to the project root directory and run "sbt compile", "sbt package" command after you put in your spark scala code, then "sbt run" or "spark-submit" depending on whether you want to run it locally or submit to spark cluster
Wednesday, October 28, 2015
Unit Testing of AngularJS in Spring MVC maven project using Jasmine, PhantomJS, and Jenkins CI
This post is about some links on how to perform unit testing of angularjs in spring MVC project. One typical setup is with Jasmine and phantomjs.
Some general descriptions of these tools: jasmine is a behavior-driven development framework for testing javascript, phantomjs is a headless browser, which can be invoked on Jenkins CI to run unit testing of angularjs (Jenkins CI is a continuous integration server that supports building and testing of software projects)
Firstly includes the following in your maven POM file
In the <plugins> section two plugins, namely jasmine and phantomjs maven plugins are added. The jasmine plugin is for jasmine to be used for unit testing and the phantomjs will download the phantomjs executable into a tmp folder so that it can be invoked to run the unit testing by Jenkins. The phantomjs maven plugin is very useful in that when the project is fetched by Jenkins CI to perform testing, the machine running Jenkins CI may not have phantomjs pre-installed. With the phantomjs maven plugin and the "install" goal specified in it, the Jenkins will search locally whether a copy of phantomjs is available in the specified phantomjs.outputDir folder, if not, it will download from the internet and put it in the phantomjs.outputDir folder, and after that the plugin set the phantomjs.binary parameter automatically, so that Jenkins CI knows where to find the phantomjs executable.
The org.eclipse.m2e lifecycle-mapping specified in the <pluginManagement> is used to stop Eclipse from complaining m2e cannot under the "install" goal specified in the phantomjs maven plugin. It does not have any effect on maven when it builds and run the project.
For this, there is already a nice article on how to do it here at:
https://spring.io/blog/2015/05/19/testing-an-angular-application-angular-js-and-spring-security-part-viii
Therefore I won't repeat it.
Some general descriptions of these tools: jasmine is a behavior-driven development framework for testing javascript, phantomjs is a headless browser, which can be invoked on Jenkins CI to run unit testing of angularjs (Jenkins CI is a continuous integration server that supports building and testing of software projects)
POM setup
Firstly includes the following in your maven POM file
<properties>
<angularjs.version>1.4.3-1</angularjs.version>
<phantomjs.outputDir>${java.io.tmpdir}/phantomjs</phantomjs.outputDir>
</properties>
<build>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings
only. It has no influence on the Maven build itself. -->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>com.github.klieber</groupId>
<artifactId>phantomjs-maven-plugin</artifactId>
<versionRange>
[0.7,)
</versionRange>
<goals>
<goal>install</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore></ignore>
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>com.github.klieber</groupId>
<artifactId>phantomjs-maven-plugin</artifactId>
<version>0.7</version>
<executions>
<execution>
<goals>
<goal>install</goal>
</goals>
</execution>
</executions>
<configuration>
<version>1.9.7</version>
</configuration>
</plugin>
<plugin>
<groupId>com.github.searls</groupId>
<artifactId>jasmine-maven-plugin</artifactId>
<version>2.0-alpha-01</version>
<executions>
<execution>
<goals>
<goal>test</goal>
</goals>
</execution>
</executions>
<configuration>
<additionalContexts>
<context>
<contextRoot>/lib</contextRoot>
<directory>${project.build.directory}/generated-resources/unit/ml/js</directory>
</context>
</additionalContexts>
<skipTests>true</skipTests>
<preloadSources>
<source>/webjars/jquery/2.1.3/jquery.min.js</source>
<source>/webjars/bootstrap/3.3.5/js/bootstrap.min.js</source>
<source>/webjars/angularjs/${angularjs.version}/angular.min.js</source>
<source>/webjars/angularjs/${angularjs.version}/angular-route.min.js</source>
<source>/webjars/angularjs/${angularjs.version}/angular-animate.min.js</source>
<source>/webjars/angularjs/${angularjs.version}/angular-mocks.js</source>
</preloadSources>
<jsSrcDir>${project.basedir}/src/main/resources/js</jsSrcDir>
<jsTestSrcDir>${project.basedir}/src/test/resources/js</jsTestSrcDir>
<webDriverClassName>org.openqa.selenium.phantomjs.PhantomJSDriver</webDriverClassName>
<webDriverCapabilities>
<capability>
<name>phantomjs.binary.path</name>
<value>${phantomjs.binary}</value>
</capability>
</webDriverCapabilities>
</configuration>
</plugin>
</plugins>
<build>
In the <plugins> section two plugins, namely jasmine and phantomjs maven plugins are added. The jasmine plugin is for jasmine to be used for unit testing and the phantomjs will download the phantomjs executable into a tmp folder so that it can be invoked to run the unit testing by Jenkins. The phantomjs maven plugin is very useful in that when the project is fetched by Jenkins CI to perform testing, the machine running Jenkins CI may not have phantomjs pre-installed. With the phantomjs maven plugin and the "install" goal specified in it, the Jenkins will search locally whether a copy of phantomjs is available in the specified phantomjs.outputDir folder, if not, it will download from the internet and put it in the phantomjs.outputDir folder, and after that the plugin set the phantomjs.binary parameter automatically, so that Jenkins CI knows where to find the phantomjs executable.
The org.eclipse.m2e lifecycle-mapping specified in the <pluginManagement> is used to stop Eclipse from complaining m2e cannot under the "install" goal specified in the phantomjs maven plugin. It does not have any effect on maven when it builds and run the project.
Implement Jasmine and spring unit testing codes
For this, there is already a nice article on how to do it here at:
https://spring.io/blog/2015/05/19/testing-an-angular-application-angular-js-and-spring-security-part-viii
Therefore I won't repeat it.
Labels:
AngularJS,
Eclipse,
Jasmine,
Jenkins,
Maven,
PhantomJS,
Spring,
Spring MVC,
Unit Testing
Saturday, October 17, 2015
Eclipse Tomcat: class path resource [properties/server-${spring.profiles.active}.properties] cannot be opened because it does not exist
Today I encounter this error when working on a spring project in eclipse when trying to start the tomcat server on the spring mvc project:
"class path resource [properties/server-${spring.profiles.active}.properties] cannot be opened because it does not exist"
The issues turned out to be that the spring project has two properties files: namely server-dev.properties and server-production.properties. The project define a property "spring.profiles.active" which need to be supplied to the tomcat server when launching the spring mvc project so that the proper properties file can be loaded. The problem occurred because i was did not specify the argument when launching the project. To resolve this, double click the tomcat server instance in the "Servers" window in Eclipse and click the "Overview" tab. In the "Overview" tab, click "Open launch configuration" link. In the "Edit Configuration" dialog opened, click the "Arguments" tab, and append the following to the "VM arguments" textbox:
-Dspring.profiles.active=dev
"class path resource [properties/server-${spring.profiles.active}.properties] cannot be opened because it does not exist"
The issues turned out to be that the spring project has two properties files: namely server-dev.properties and server-production.properties. The project define a property "spring.profiles.active" which need to be supplied to the tomcat server when launching the spring mvc project so that the proper properties file can be loaded. The problem occurred because i was did not specify the argument when launching the project. To resolve this, double click the tomcat server instance in the "Servers" window in Eclipse and click the "Overview" tab. In the "Overview" tab, click "Open launch configuration" link. In the "Edit Configuration" dialog opened, click the "Arguments" tab, and append the following to the "VM arguments" textbox:
-Dspring.profiles.active=dev
Thursday, October 15, 2015
Eclipse: Black tooltip background when running eclipse on centos and scentific linux
I have been use eclipse for java development but recently i migrated the eclipse over from centos and scentific linux, now the eclipse running on centos and scentific linux have a black tooltip when user hover over the codes. The problem seems to be related to GTK which eclipse use.
Solution:
Create a "start.sh" in the eclipse root folder, make it executable. then put the following two lines in the files:
Now launch the "start.sh" instead of "eclipse" executable.
While the above solution seems to temporarily solve the black tooltip problem for me, eclipse will occasionally crash due to issues button size cannot be determined. Today, my colleague comes up with a better solution which is to replace the default desktop environment in centos with the xfce http://www.xfce.org/. This completely remove the issue with black tooltip background in eclipse.
Solution:
Create a "start.sh" in the eclipse root folder, make it executable. then put the following two lines in the files:
export SWT_GTK3=0 ./eclipse
Now launch the "start.sh" instead of "eclipse" executable.
While the above solution seems to temporarily solve the black tooltip problem for me, eclipse will occasionally crash due to issues button size cannot be determined. Today, my colleague comes up with a better solution which is to replace the default desktop environment in centos with the xfce http://www.xfce.org/. This completely remove the issue with black tooltip background in eclipse.
Saturday, December 20, 2014
Maven: missing artifact org.eclipse.equinox.app.jar
Sometimes if one sees the errors such as "missing artifact org.eclipse.equinox.app.jar..." in Eclipse or Maven, it is probably they did not set the repository right in their pom file. Below is the repositories which can be added to the pom file that might resolve the error:
<repositories>
<repository>
<id>clojars</id>
<url>http://clojars.org/repo</url>
</repository>
<repository>
<id>mvnCentral</id>
<url>http://repo1.maven.org/maven2</url>
</repository>
</repositories>
<repositories>
<repository>
<id>clojars</id>
<url>http://clojars.org/repo</url>
</repository>
<repository>
<id>mvnCentral</id>
<url>http://repo1.maven.org/maven2</url>
</repository>
</repositories>
Tuesday, December 16, 2014
Tomcat: modules/classes auto-reload and published in Tomcat Server when changes made to the web project
When using the spring tool suite, you will have the ability to auto-reload modules and auto-publish the updated project in tomcat server whenever you made changes to the codes in your web project. To enable this feature, double-click your Tomcat server instance in the "Servers" tab in the IDE, and do the following steps:
1. Check the option "Modules auto-reload by default" under the "Server Options" section (or check the "Enable Java-agent reload behavior" option under the "Application reload behavior section", depending on your IDE)
2. Select the radio option "Automatically publish when resources change" under the "Publish" section
Now restart your Tomcat server, and whenever you made changes to your code, your changes will be immediately reflected on the changes in the web pages.
Note that if you do not have the options as stated in step 1 because of the IDE you are using does not package with this feature. The alternative step will be to
1.1 Download the spring-loaded from
https://github.com/spring-projects/spring-loaded
and store the downloaded jar file in your file system somewhere (said, /home/chen/Documents/Works/spring-reloaded/springloaded-1.2.1.RELEASE.jar)
1.2 Double-click the Tomcat server instance in your IDE's "Servers" tab and click the link "Open Launch Configuration" in the "Server Configuration" page.
1.3 In the "Edit Configuration" dialog popup, select the "Arguments" tab, and add the following to the end of the "VM arguments" field text:
-javaagent:/home/chen/Documents/Works/spring-reloaded/springloaded-1.2.1.RELEASE.jar -noverify
After the above step, following the step 2 as mentioned above and restart the server after that.
1. Check the option "Modules auto-reload by default" under the "Server Options" section (or check the "Enable Java-agent reload behavior" option under the "Application reload behavior section", depending on your IDE)
2. Select the radio option "Automatically publish when resources change" under the "Publish" section
Now restart your Tomcat server, and whenever you made changes to your code, your changes will be immediately reflected on the changes in the web pages.
Note that if you do not have the options as stated in step 1 because of the IDE you are using does not package with this feature. The alternative step will be to
1.1 Download the spring-loaded from
https://github.com/spring-projects/spring-loaded
and store the downloaded jar file in your file system somewhere (said, /home/chen/Documents/Works/spring-reloaded/springloaded-1.2.1.RELEASE.jar)
1.2 Double-click the Tomcat server instance in your IDE's "Servers" tab and click the link "Open Launch Configuration" in the "Server Configuration" page.
1.3 In the "Edit Configuration" dialog popup, select the "Arguments" tab, and add the following to the end of the "VM arguments" field text:
-javaagent:/home/chen/Documents/Works/spring-reloaded/springloaded-1.2.1.RELEASE.jar -noverify
After the above step, following the step 2 as mentioned above and restart the server after that.
Sunday, December 14, 2014
Eclipse: Java was started but returned exit code=13
Recently I have an update from Oracle on my Windows 7's Java jre. After i suddenly was no longer able to launch my Eclipse or Spring Tool Suit application. It always throw the following error when i try to launch the Eclipse application.
Java was started but returned exit code=13
C:\ProgramData\Oracle\Java\javapath\javaw.exe
-Dosgi.requiredJavaVersion=1.6
-Xms40m
-Xms768m
-XX:MaxPermSize=256m
-Dorg.eclipse.swt.browser.IEVersion=10001
-jar
D:\STS\sts-3.6.3.RELEASE\\plugins/org.eclipse.equinox.launcher_1.3.0.v20140415-2008.jar
-os win32
-ws win32
-arch x86_64
-showsplash
-launcher D:\STS\sts-3.6.3.RELEASE\STS.exe
-name STS
--launcher.library
...
I was in a bit of shock initially, but realized that somehow, the update may have messed up my default java jre path, as the error indicating it is using javaw.exe from "C:\ProgramData\Oracle\Java\javapath;" and i don't remember that i set include java's bin path as this directory. Therefore, I run the following commands:
> java -version
> javac -version
True enough they refers to very different version, next I want to find out which version of java.exe i am currently using and from which directory, and i run the following command:
The print out indicates the current java.exe being used is from "C:\ProgramData\Oracle\Java\javapath;", I then remove the "C:\ProgramData\Oracle\Java\javapath;" from the $PATH system environment variable.
Further mess up was noticed when i rerun the command "for %i in (java.exe) do @echo. %~PATH:i" and some other app's java.exe shows up. This is finally fixed when I move my JAVA_HOME/bin directory to be the first entry in the PATH system environment variable. This finally fix my problem.
Java was started but returned exit code=13
C:\ProgramData\Oracle\Java\javapath\javaw.exe
-Dosgi.requiredJavaVersion=1.6
-Xms40m
-Xms768m
-XX:MaxPermSize=256m
-Dorg.eclipse.swt.browser.IEVersion=10001
-jar
D:\STS\sts-3.6.3.RELEASE\\plugins/org.eclipse.equinox.launcher_1.3.0.v20140415-2008.jar
-os win32
-ws win32
-arch x86_64
-showsplash
-launcher D:\STS\sts-3.6.3.RELEASE\STS.exe
-name STS
--launcher.library
...
I was in a bit of shock initially, but realized that somehow, the update may have messed up my default java jre path, as the error indicating it is using javaw.exe from "C:\ProgramData\Oracle\Java\javapath;" and i don't remember that i set include java's bin path as this directory. Therefore, I run the following commands:
> java -version
> javac -version
True enough they refers to very different version, next I want to find out which version of java.exe i am currently using and from which directory, and i run the following command:
> for %i in (java.exe) do @echo. %~$PATH:i
The print out indicates the current java.exe being used is from "C:\ProgramData\Oracle\Java\javapath;", I then remove the "C:\ProgramData\Oracle\Java\javapath;" from the $PATH system environment variable.
Further mess up was noticed when i rerun the command "for %i in (java.exe) do @echo. %~PATH:i" and some other app's java.exe shows up. This is finally fixed when I move my JAVA_HOME/bin directory to be the first entry in the PATH system environment variable. This finally fix my problem.
Saturday, December 13, 2014
Eclipse: The method ? of type ? must override a superclass method
Recent I import and git project into Spring Tool Suit and Eclipse, it comes up with the following annoying errors such as :
"The method prepare(Map, TopologyContext, OutputCollector) of type AnalyticBolt must override a superclass method"
My imported project is littered with all these errors. After some search online, it turns out that these are caused by the compliance of eclipse to Java 1.5, which does not recognize @Overrride attribute.
I was able to correct this by:
1. Right-click the project and select "Properties"
2. "Java Compiler" in the "Properties" page and uncheck "Use compliance from execution environment 'J2SE-1.5' on the 'Java Build Path'
3. Set the 'Compiler compliance level:" to 1.7
4. Click "OK".
"The method prepare(Map, TopologyContext, OutputCollector) of type AnalyticBolt must override a superclass method"
My imported project is littered with all these errors. After some search online, it turns out that these are caused by the compliance of eclipse to Java 1.5, which does not recognize @Overrride attribute.
I was able to correct this by:
1. Right-click the project and select "Properties"
2. "Java Compiler" in the "Properties" page and uncheck "Use compliance from execution environment 'J2SE-1.5' on the 'Java Build Path'
3. Set the 'Compiler compliance level:" to 1.7
4. Click "OK".
Thursday, November 20, 2014
Maven: add plugin to pom configuration for Maven to build a jar package in Eclipse and STS
To use maven to compile and build a jar package, create a maven project in Eclipse or STS. After the project is created add the following xml sections to the end of the pom.xml file in the project.
<build>
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.2.1</version>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<archive>
<manifest>
<mainClass />
</manifest>
</archive>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
After the implementation of java coding. To build and run using maven, navigate to the project folder in the terminal and run the following command:
> mvn compile exec:java -Dexec.classpathScope=compile -Dexec.mainClass=[mainClassFullPath]
where [mainClassFullPath] refers to the full name of the class containing the main() method.
Or
> mvn clean install
<build>
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.2.1</version>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<archive>
<manifest>
<mainClass />
</manifest>
</archive>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
After the implementation of java coding. To build and run using maven, navigate to the project folder in the terminal and run the following command:
> mvn compile exec:java -Dexec.classpathScope=compile -Dexec.mainClass=[mainClassFullPath]
where [mainClassFullPath] refers to the full name of the class containing the main() method.
Or
> mvn clean install
Tuesday, September 2, 2014
Upload App Engine Endpoint project
Step 1: create the project at Google Developer Console and copy the project id for later usage.
Step 2: import the app engine project into Eclipse (follow this link on how to do this: http://czcodezone.blogspot.sg/2014/09/import-and-run-app-engine-endpoint.html). Expand the project directory in the "project explorer" of Eclipse to the folder "[project_folder]->main->webapp->WEB-INF" and double-click to open "appengine-web.xml". Change the text element in the xml element "<application>"
to the project id copied earlier in step 1.
Step 3: Right-click the project in the "project explorer" of Eclipse and select "Run As->Run Configuration". In the run configuration dialog, right-click "Maven Build" and select "New". enter the configuration name (e.g. "training-upload") and select the base directory using the "Browse Workspace" button. Next enter "appengine:update" into the "Goals" and click "Apply". Now click "Run" button.
Step 4: To reupload, simply right-click the project in the "project explorer" and select "Run As->Maven Build" and select the earlier created configuration (e.g. the "training-upload" specified earlier in Step 3).
Step 2: import the app engine project into Eclipse (follow this link on how to do this: http://czcodezone.blogspot.sg/2014/09/import-and-run-app-engine-endpoint.html). Expand the project directory in the "project explorer" of Eclipse to the folder "[project_folder]->main->webapp->WEB-INF" and double-click to open "appengine-web.xml". Change the text element in the xml element "<application>"
to the project id copied earlier in step 1.
Step 3: Right-click the project in the "project explorer" of Eclipse and select "Run As->Run Configuration". In the run configuration dialog, right-click "Maven Build" and select "New". enter the configuration name (e.g. "training-upload") and select the base directory using the "Browse Workspace" button. Next enter "appengine:update" into the "Goals" and click "Apply". Now click "Run" button.
Step 4: To reupload, simply right-click the project in the "project explorer" and select "Run As->Maven Build" and select the earlier created configuration (e.g. the "training-upload" specified earlier in Step 3).
Import and Run App Engine Endpoint project in Eclipse J2EE
Step 1: Download J2EE Eclipse if you have not done so, the link is http://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/keplersr2
Now unzip and launch the eclipse IDE
Step 2: Import the App Engine Endpoint project (which can be created using maven, e.g., following this link: http://czcodezone.blogspot.sg/2014/09/using-maven-to-create-app-engine.html) into Eclipse. To do so, right-click "project explorer" in Eclipse and select "Import->Import". Next, in the import dialog, select "Maven->Existing Maven Projects", and follow the steps to import the maven app engine endpoint project.
Step 3: To run the imported project, right-click the project in the "project explorer" and select "Run As->Run Configurations". In the run configuration dialog, right-click "Maven Build" and select "New", now enter the configuration name on top of the page and enter "appengine:devserver" in the "Goals" textfield. In click "Browse Workspace" below the "Base Directory" and select the imported project. Finally click on "Apply" button, and then "Run", the maven will then go and compile and download related libraries and start running the project".
When the project is running, the output command line in Eclipse will read "[INFO] INFO: Dev App Server is now running". Now you can open the url http://localhost:8080/ in your browser and see the app engine endpoint web app running.
Step 4: To see the available endpoint api, after the app is running go to the link http://localhost:8080/_ah/api/explorer
Now unzip and launch the eclipse IDE
Step 2: Import the App Engine Endpoint project (which can be created using maven, e.g., following this link: http://czcodezone.blogspot.sg/2014/09/using-maven-to-create-app-engine.html) into Eclipse. To do so, right-click "project explorer" in Eclipse and select "Import->Import". Next, in the import dialog, select "Maven->Existing Maven Projects", and follow the steps to import the maven app engine endpoint project.
Step 3: To run the imported project, right-click the project in the "project explorer" and select "Run As->Run Configurations". In the run configuration dialog, right-click "Maven Build" and select "New", now enter the configuration name on top of the page and enter "appengine:devserver" in the "Goals" textfield. In click "Browse Workspace" below the "Base Directory" and select the imported project. Finally click on "Apply" button, and then "Run", the maven will then go and compile and download related libraries and start running the project".
When the project is running, the output command line in Eclipse will read "[INFO] INFO: Dev App Server is now running". Now you can open the url http://localhost:8080/ in your browser and see the app engine endpoint web app running.
Step 4: To see the available endpoint api, after the app is running go to the link http://localhost:8080/_ah/api/explorer
Subscribe to:
Posts (Atom)