How to use Heroku eclipse plugin ? An error encounter - java

I am using Heroku eclipse plugin to create a Heroku template. Sorry that I am quite a beginner in Heroku and Maven build. I totally don't know how to use Heroku belt tool to build and push the app to server, so I choose eclipse plugin. Now I encounter an error right after I create a Heroku template:
maven-dependency-plugin (goals "copy-dependencies", "unpack") is not supported by m2e. pom.xml /herokutesting123123 line 48 Maven Project Build Lifecycle Mapping Problem
What could be the problem?
One more problem is how am I going to run the program? Which one should I choose below to build? I thought it should work like how am I working with Tomcat, but I cannot find "run on server" function in the list below. How?
Last problem is how am I going to push the app to the server? I already got the API key after I key in account and password, but I cannot find any function in eclipse to push the app to the server. I thought it work as simple as Google App Engine, one click will do. So, how can I push the app?

As James mentioned, that is a bug with the Maven Eclipse plugin, but if you want to get rid of the error, you can add an exclusion similar to this in your pom.xml's pluginManagement section:
https://github.com/heroku/template-java-jaxrs/commit/1e68c44a4356216d7077738f87ee9b97545d4bb5
As far as your second question, you deploy the app to Heroku via git push. See this doc for details how to do that from Eclipse:
https://devcenter.heroku.com/articles/getting-started-with-heroku-eclipse#deploying-changes-to-heroku

You can ignore that error. It's a bug in the Maven Eclipse Plugin. To run the app from Eclipse, see the webapp-runner instructions:
https://github.com/jsimone/webapp-runner#running-your-application-in-eclipse

Related

How to install Cordova plugins in Netbeans IDE? 8.0

I'm just getting into javascript development so please bear with me.
I'm trying to install the SpeechRecognizer plugin into Cordova/a Cordova project (which is built into Netbeans IDE 8.0 )
and I really don't know where I have to begin. Could somebody help me out with this? How do install the plugin, how do I call the function? How do I get a string or array returned to me conntaining what the speech recognition picked up?
Thanks so much, I'm a total noob.
The plugin is SpeechRecognizer - https://github.com/poiuytrez/SpeechRecognizer
You can do following:
open [projectFolder]/nbproject/plugins.properties file
paste following at the end of file
SpeechRecognizer=https://github.com/poiuytrez/SpeechRecognizer.git
build project
The plugins.properties file contains list of used plugins. Some "core" plugins can be added/removed easily in project properties but for 3rd party/unknown plugins, you need to manually modify the file (it is also mentioned in project properties dialog ->Cordova->Plugins)
Edit: The pasted line could look like
com.phonegap.plugins.speech=https://github.com/poiuytrez/SpeechRecognizer.git
or
com.phonegap.plugins.speech.SpeechRecognizer=https://github.com/poiuytrez/SpeechRecognizer.git
in case of some issues (I was able to build the project with the 1st line with friendly name but in case there is some catch, try this name instead)

Eclipse plugin not working properly

I developed an Eclipse plugin that compiles and runs java code in German. The technique I am using is that I translate the code to English and pass it to Java Compiler and get the results back and print it in the console.
The problem is that the plugin works when I run the plugin from Inside Eclipse but when I install the plugin in Eclipse so that when I open Eclipse it already exists there and start to test if a real user uses my plugin and creates a new Java project and try to the compile button in my plugin it says [The chosen operation is not currently available] ![Here is the the way I run and it opens a new Eclipse application with the installed plugin ]
Any help please
the way you installed your plugin sounds a little weird to me. So at first please try to export your plugin via the Export Wizard.
(Select Export -> Deployable plugins and features from your projects context menu)
Export your project as jar file and copy it to the 'plugin' folder of your eclipse instance.
After that it might be helpful to debug your plugin on OSGI-Level as there might be a problem loading your plugin (at least the error description you have posted indicates that).
Run eclipse with -console -noExit -consoleLog flags to open an OSGI console for debugging. After that try running ss <your-plugin-name> to see what the state of your plugin is.
The output gives you the ID of your plugin and the state it currently has. If the state of your plugin is not ACTIVE try running start <your-plugin-id> to see whether it starts correctly. If there is a problem starting your plugin you should get a respective log message. Feel free to post it here in case you need further help.
Otherwise there are plenty of options what might cause your problems, so maybe its better to try the steps I have described above before getting into details.
If you want to run eclipse plug-in withput using Eclipse Application , then you need to make a Feature project.
Now if your algorithm has something to do with system Path , you must
check Unpack plug-in and you should read the resource accordingly.
Like PLatformUI.getWorkBC() etc..
No other eclipse plug-in (jar) should be inside plugins directory of eclipse of same name of your plug-in. Ensure for this.

oData4j sample eclipse project

I have downlaoded oData4J jar files from odata.org and I intend to do a sample producer, within a basic web service.
I assumed that InMemoryProducerExample.java from http://code.google.com/p/odata4j/ will do the job and most probably it is.
My problem is that I have no clue which type of project to create (Eclipse Java), how to deploy and test this example.
Does anyone have such a start up hellow world tutorial for odata step by step, or an eclipse project which use InMemoryProducerExample.java from oData. I really need a starting point and I can see one online.
Thanks.
The easiest way to run the odata4j example is to simply checkout their project, and open it in eclipse.
If you don't have mercurial installed, install it from here.
checkout the latest odata4j code using this mercurial command,
hg clone https://code.google.com/p/odata4j/
Open the project in eclipse using the maven eclipse plugin. If you are using the latest version of eclipse, this will be installed already, it not you can install it from here.
In eclipse, go import->maven->Existing maven projects
Then select the directory where mercurial checked out odata4j.
When eclipse finishes importing the projects, you can find InMemoryProducerExample, and right click on it to run it as a java program. You can run any of the other examples in the same way.
Meanwhile, forks of odata4j which continued their lives are also available on GitHub, see https://github.com/odata4j/odata4j and my own https://github.com/vorburger/odata4j/ (which I am about to transfer to https://github.com/lukinf), which included some minor fixes for opening it in Eclipse.

How to run maven project on google app engine

I follow this tutorial: http://software.danielwatrous.com/wordpress-plugin-licensing-wicket-on-google-app-engine/. I add google app engine library to this project and then I want to check google app engine on. But when I do this eclipse has this problem:
The App Engine SDK '/home/hudi/program/git/tournamenSystem/tournament-system/
tournament-system-web/src/main/webapp/WEB-INF/lib/appengine-api-1.0-sdk-1.7.1.jar'
on the project's build path is not valid (SDK location '/home/hudi/program/git/
tournamenSystem/tournament-system/tournament-system-web/src/main/webapp/WEB-INF/
lib/appengine-api-1.0-sdk-1.7.1.jar' is not a directory)
I dont understand it. Jar isnt directory so why it want to some directory ? When I want use quick fix then I can just use another SDK. I try to use older version 1.6... but still same problem. How I can fix it ? Please help
Possible solution is that, you should add appengine through app engine settings in eclipse and make sure that the sdk added by appengine setting appear before the one mentioned (i.e. /home/hudi/program/git/tournamenSystem/tournament-system/tournament-system-web/src/main/webapp/WEB-INF/lib/appengine-api-1.0-sdk-1.7.1.jar) in your build path. In this way your application would refer the appengine sdk from google plugin and not for the path which is giving error.
I had same issue where I was getting error for the sdk jar included from maven dependency.Hope it will help.
You may want to take a look at the Maven GAE Plugin
This plugin has goals to run, debug, deploy, etc. your GAE application.
On my computer with Ubuntu 12.04 and Eclipse Juno SR1
I just move all maven dependencies to the button of the list of Java build path.
For open Java build path window right click on the project
- preferences
- Java build path
- Order and Export
- select all row with M2_REPO(or some thing else) and press button "Bottom"
- Refresh project.
This need help.
Thank you!

How to install Android plugin into the Netbeans IDE?

How do you install NetBeans IDE the Android plugin? Is this link working or any alternative? http://kenai.com/projects/nbandroid/pages/Install
When i try i get failure:
Also this gives failure: http://kenai.com/projects/nbandroid/downloads/directory/archives or http://kenai.com/projects/nbandroid/downloads/download/archives/nbandroid-dev-2011-11-10_13-25-27.zip
SERVER ERROR
We're sorry, but something went wrong.
We've been notified about this issue and we'll take a look at it shortly.
I was using Netbeans for my JAVA project before, but when I started with Android I found it more useful to start with Eclipce. So if you not have to use NB, I recommend you to switch.
Kenai.com site no longer hosts these plugins. I recommend going to Install Plugins..|Settings | Add (Give it a name e.g. Android or NB)|Ok http://nbandroid.org/updates/updates.xml or if you're having a lazy connection download the plugins directly from http://nbandroid.org/downloads/ and add them from the Download tab and proceed as usual.
Android common library,
Android Core, Android Ddmlib,
AndroidPrefs, Android Project
SDK Library,
first only install these and then go for next it will work!!

Categories