Bluemix application debugging not working in Eclipse - ibm-cloud

When I select "Enable Application Debug" in Eclipse, it is showing "Establishing debug session" in progress window but ends up enabling development mode.
When "Incremental Publish" is selected, it gives error:
Failed to create JMX connection.
The connection failed. Ensure that the remote Liberty profile server is started and that the user name, password, and port number are correct.
Also, /IBMJMXConnectorREST URL is giving 404 error.
Few things on the configuration done:
Using JDK 8
Debug perspective
App memory is 1 GB
Should we configure any other thing ?
NOTE: Java Cloudant Starter pack offered by bluemix is the app's codebase in eclipse

Activating debugging is performed in Eclipse by right-click on the application name under the correct Bluemix server, and selecting Enable Application Debug

Enabling development mode (and thus incremental publish) is one of the steps for turning on debug mode. The tools ended up staying in development mode probably indicates that there are some problem on switching on debug mode after the development mode step is completed.
Can you provide the following information so that I can try to reproduce the problem?
1. What is the version of IBM Eclipse Tools for Bluemix that you are using?
2. What platform are you running on?
3. Do you see any error in the .log file in your workspace?
4. What is the exact version of JDK that you are using? Also, is it a IBM JDK or Oracle JDK?

Related

Unable to Finish connecting to SonarQube server

This is going to sound like a ridiculous question, but using the SonarLint Eclipse plugin (v3.2.0) on the latest Eclipse (Oxygen), I am unable to add a new SonarQube server connection.
I am working behind a company firewall, but that doesnt appear to be an issue. I am following the steps here and am able to successfully connect to our internal SonarQube instance, provide my credentials, but it is just on the final step, that the 'Finish' button does not seem to do anything, see screen below:
I appreciate there is probably some background processes need to run in order for this Finish to actually finish :) But this doesnt appear to be doing anything...Anyone else experience this issue?
Any before people ask, I've restarted Eclipse/laptop, uninstalled and reinstalled SonarLint plugin etc.
Thanks in advance!
SonarLint in Eclipse are storing credentials in Eclipse secure storage that itself is protected by a master password. So you must reset it or delete it to add a new SonarQube server connection. You can try this step :
In your Eclipse Go to Window > Preferences, filter and find Secure Storage.
In the Tab Contents find and highlight org.sonarlint.eclipse.core, click Delete > Apply > OK. After deletion process is finished, Eclipse will ask if you want to restart the IDE. It is strongly recommended that you restart the IDE and try again to adding SonarQube server in Eclipse.
Thanks.
On my linux machine I had the same issue, because the used master password provider doesn't work properly.
This answer worked for me:
Open Window > Preferences
Go to General > Security > Secure Storage
At Master password providers uncheck the used provider. The enabled provider with the highest priority is the used one [for me it was "Linux Integration (64 bit)"].
Click apply
I also encountered this problem, but was able to work around it.
This is environment in which I was running:
Eclipse Oxygen.1
Linux VM (VirtualBox) on Windows host
Solution that worked for me based on this post:
Uninstall SonarLint.
Reinstall using Help -> Install new software...
On the Install dialog, un-check the option "Show only the latest versions of available software"
Select the older version of SonarLint.
Select Next and continue with the install.
After installing, configure your SonarQube server like normal.
Upgrade to the latest version of SonarLint via Help -> Check for Updates
In my case the problem also concerned the credentials storage but was caused by the Avecto Defendpoint Client. The company restricted the permissions to create subfolders in user home (c:\users<username>). I had to create manually missing subfolders (.sonarlint and .eclipse) after access level elevation and after filling the reason in a text field. Then I had to give the permissions to those folders for myself. Having created them I could proceed with adding server to sonarlint plugin.

How to create openshift application for OPENSHIFT ONLINE 3 STARTER (NEW!) server in Eclipse IDE?

I am trying to create an openshift3 application in Eclipse IDE after installing JBoss Developer tool plugin in IDE, But getting below error at the time Sign into OpenShift.
Error: The server type, credentials, or auth scheme might be incorrect:
I have also tried other server hostname like https://console.starter-us-east-1.openshift.com/console/ and much more, but still not working.
While, when I tried to log in using OC tool (OpenShift CLI) with the same credential (as seen in picture), I haven't got any error.
I also tried to run RHC (OpenShift Client Tool) but at the time of RHC setup it is saying "You are not authorized to perform this operation."
Please help me to solve it out.
First of all, it looks like you're using an outdated version of the JBoss Tools Openshift plugin, because the "New Openshift Application" wizard looks a little bit different at the moment. So try to update it:
Help -> About Eclipse -> Installation Details -> Update... - and choose at least all the JBoss Tools plugins that it'll report to you (the best will be to choose everything reported) and update them.
Secondly, what is the URL which you use to access the Openshift web console in your browser? It seems to me that it is https://console.starter-us-east-1.openshift.com. Are you able to login there with your credentials? If yes, the same must work in JBoss Tools Openshift plugin. Check this and this articles for more info about using it.

Eclipse IDE remote rebug and remote edit a legacy webapp

I am in a bind here, what's happening is I have a legacy webapp which uses an in-memory database. The app requires 64GB of RAM just to launch and it takes at least 30 minutes to start.
I have to make updates/fixes to this application. Obviously it is impossible to launch it on my PC so everything has to be done on the server. I have considered setting up an Eclipse IDE on the Linux server where this app runs, but that introduces a set of new issues. I really would like to continue using my PC's Eclipse IDE and make edits to the app.
I am able to use the remote debugging capabilities of Eclipse IDE and launch this app from the linux server no problem. However this is not enough. After I make an edit, I need to be able to save/compile the file, and load this change into the server relatively quickly. I can't wait 30 minutes every time I make some updates to the app.
Can anyone recommend ideas on what to do in this scenario? Ideally I would love to be able to launch the app in DEBUG mode inside the Linux Eclipse IDE on the server and connect to this instance using remote debugging from my local/Windows IDE. I would like to make changes in my Windows Eclipse IDE and then quickly copy the files over to the linux server, pick them up in the Linux Eclipse IDE, compile them in the Eclipse IDE instance running in debug mode, and effectively "hot swapping" the changes, thereby avoiding the need to wait 30 minutes for the app to start back up... However when I try to do this, there is a caveat... I can't seem to be able to launch the webapp in Linux Eclipse IDE in both DEBUG mode and also remote-debug-connect to it, the error I am getting in Eclipse is:
"Cannot load this JVM TI agent twice"
I get what is going on: the local debugger is launching tomcat with the -agentlib:jdwp parameter and on top of it, I am trying to force it to also start up with the same arguments and so it complains, but is there some way to trick it into allowing me to remote connect into this debug session from my Windows server?
I managed to solve this issue by updating Tomcat's context.xml to support reloadable mode:
<Context reloadable="true">
And in the app to set it to reloadable in WEB-INF/web.xml:
<web-app reloadable="true">
Now I am able to make edits in my local windows Eclipse IDE, Save them, and they automatically get updated on the server side.

Worklight application builder hang

I am using worklight 6.1.0.1 on Eclipse Kepler. As per the screen shot below, it hangs when I open the eclipse, with message saying "Worklight application builder". It takes forever to complete.
How do I resolve this issue ?
try to start eclipse with the -clean option on command line
The issue could be network related. If using a proxy server in eclipse make sure that is not enabled. This will try to route traffic through your proxy server. The other issue could be a firewall issue either locally or elsewhere. The application deployer routes out through the network to your workstation and does not use localhost. I have yet to find a way to change this setting.

Start Websphere Liberty in Debug mode and connect via Eclipse

I am searching for a way to start the Websphere Liberty profile in debug mode from the command line? I want to be able to start Liberty, so that it is listening for debug connections on a specific port. Then I would like to connect to Liberty from Eclipse, so that I can step through and debug the server code running in Liberty.
I've tried integrating Liberty into Eclipse and using the Eclipse 'Servers' view. This works great and I can start and stop Liberty using debug mode. Unfortunately, this method does not satisfy my use case because the build process uses tools external to Eclipse.
Essentially, I need a way to do this via the command line.
I tried creating a jvm.options file for Liberty and starting it, but I still can't connect to the port I specified. I'm sure I'm doing something wrong, but thus far I haven't figured it out.
This page has some info on jvm.options
The Administering the Liberty profile from the command prompt page describes how to do this:
[bin]$ export WLP_DEBUG_ADDRESS=7778
[bin]$ ./server debug
Listening for transport dt_socket at address: 7778
You can then connect from Eclipse using Remote Debugging.