I work on web applications with eclipse which means each time I modify server side code I have to run maven clean install then start my server again. I have run configurations for these both steps in eclipse but need to wait for the first one to finish before starting the second one.
I have also other cases when I need to run maven clean install on 5 or 6 projects in a given order after having updated all of them.
So my question is: does anybody know how to define sequels of runs and run them in the right order on one click in Eclipse (i'm using Indigo). I didn't found any plugin nor help on my favorite search engine.
You can write an Ant-script which wraps the Maven commands (with using Maven Ant Tasks) in the correct order. Then you can create a launch configuration for that Ant script in Eclipse.
Or just write a shell script and create an launch configuration for that in Eclipse.
Related
We are instructed to do the following (while using Eclipse)
And if you make a left click on your project you get the option “Debug
as…”. Hit that and generate a profile that debugs the goal jetty:run.
https://www.ninjaframework.org/documentation/debugging.html
However, when we do the jetty:run, we simply build the project, and the project does not start.
Furthermore, when we run with ninja:run, the debug does not stop at breakpoints.
What I need is a debug-mode that stops at breakpoints.
How do we fix this ?
The answer is in the Ninja Framework source code, and the new versions of a Jetty... and therefore, there is (probably) no answer without recompiling the whole framework to fix the issue. I have tried diff-ing the projects, but could not see anything that would fix the higher versions. Up until the version 6.4.0 (inclusive) running the command mvn jetty:run starts the server. Any other version that is higher than 6.4.0 just builds the project and then stops.
So, one of the solutions is to simply start a new project using the old-version code executing:
mvn archetype:generate -DarchetypeGroupId=org.ninjaframework -DarchetypeArtifactId=ninja-servlet-archetype-simple -DarchetypeVersion=6.4.0
Another solution is to deploy (Jetty or Tomcat server) and try to debug the deployed jar/war file.
The first solution is simpler, however, the second one is more proper.
At the time of writing, the latest version is
<ninja.version>6.6.1</ninja.version>
<jetty.version>9.4.18.v20190429</jetty.version>
In Eclipse I am trying to automate the following sequence:
Select couple of projects and run Clean (it triggers build too).
Select Tomcat (in eclipse) and run Clean.
Select Tomcat (in eclipse) and run Debug.
1,2,3 alone can take from 1 to 5 minutes. I get distracted and sometimes I even forgot what command I am running and have to start all over again.
Some kind of notification upon completion would be nice, too.
How can I integrate qunit with eclipse? I could not find a plugin for the same in Eclipse marketplace.
Is there any other way by which I can integrate the two?
Should it be through JS Test Driver?
Here's one way to do this:
Download and install the headless browser "phantomJS". It has a plugin for launching qunit tasks.
In Eclipse, define a menu item Run/External Tools/Configuration with a command line like this
phantomjs-1.9.7-linux-x86_64/bin/phantomjs phantomjs/run-qunit.js nttp://mysite.com/myproject/tests/qunit-composite.html
If you have many test scripts and test cases, and if want to store your run results in a database, then additionally do this:
Install the Build Server TeamCity, it is free and has an Eclipse plugin.
Configure and start TeamCity from the command line.
In TeamCity, add a new project with a single Build Step with the phantomjs call mentioned above
All this brings more complexity of course.
Trying to build my application using using MVN Install cmd no build errors. Can one ahead and start the jboss server in eclipse ID? Will one be able to see all the changes getting affected with out ECLIPSE->Build ALL ?? Trying because my eclipse build takes lot of time and it validates the target folder as well as a result build is very slow. So to avoid this one can do MVN Install and run my server in debug will one be able to see my changes getting built?
If you are building project from Maven and starting server. It has no impact from eclipse changes.
If you are running server in debug mode and you are doing "Remote Debug" in eclipse then changes in eclipse will be effective as debug mode changes.
First time using Apache Ant (I'm excited and overwhelmed at the same time!) for automating a Java app.
I did not go to the ant website and download ant directly. Rather, I'm using the standard plugin that ships with Eclipse. From Eclipse, I can run test build.xml projects perfectly. But when I go to run ant directly off the command-line, Windows doesn't recognize it as a recognized command.
This leads me to believe that I either do not have ant installed, or I have not configured it properly (at all). If it's not installed, then why do these build.xml scripts work when I fire them inside of Eclipse? Does Eclipse ship with its own distrib of ant that isn't accessible from the cmd line?
And if it's just a config issue, what do I need to do in order to get ant to run a buildscript of my own flavor?
I want to start using Apache Ivy and in order to run the demos I first need ant up and running from the command line.
Thanks for any help or insight :-)
Does Eclipse ship with its own distrib of ant that isn't accessible from the cmd line?
Essentially, yes. Eclipse bundles the core Ant runtime plus its own extensions and integration, but it's private to the Eclipse installation.
If you want to run the builds from outside of Eclipse, you need to download and install the full distribution of Ant.