OpsHub Visual Studio Migration Utility MetadataException - opshub

When trying to create a new migration from TFS 2012 Update 2 to Visual Studio Teams Service, the utility fails on the user mapping screen with the following error:
com.opshub.eai.metadata.MetadataException: OpsHub-014371: Could not
instantiate metadata implementation for For User List | TFS Source
1456429486357 ALM TFS 1456429486367, due to OH-TFS-Connector-0068:
Following Fields are mandatory to map for
http://localhost:9090/TFSService integration : {1}
The service appears to be running fine. Any ideas?
More information form the OpsHub.log file:
02/25/2016 13:44:47,511 ERROR [http-8989-1] (com.opshub.eai.config.service.ConfigServiceImpl) - OpsHub-014371: Could not instantiate metadata implementation for For User List | TFS Source 1456429486357 ALM TFS 1456429486367, due to OH-TFS-Connector-0068: Following Fields are mandatory to map for http://localhost:9090/TFSService integration : {1}
com.opshub.eai.metadata.MetadataException: OpsHub-014371: Could not instantiate metadata implementation for For User List | TFS Source 1456429486357 ALM TFS 1456429486367, due to OH-TFS-Connector-0068: Following Fields are mandatory to map for http://localhost:9090/TFSService integration : {1}
at com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl.getProjectsMeta(TFSMetadataImpl.java:64)
at com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl$$EnhancerByCGLIB$$171aa598.CGLIB$getProjectsMeta$5(<generated>)
at com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl$$EnhancerByCGLIB$$171aa598$$FastClassByCGLIB$$b1d799e5.invoke(<generated>)
at net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:167)
at com.opshub.eai.core.adapters.caching.MetadataCacheHandler.intercept(MetadataCacheHandler.java:38)
at com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl$$EnhancerByCGLIB$$171aa598.getProjectsMeta(<generated>)
at com.opshub.eai.config.business.ConfigServiceBusiness.getUserList(ConfigServiceBusiness.java:1041)
at com.opshub.eai.config.service.ConfigServiceImpl.getUserList(ConfigServiceImpl.java:394)
at com.opshub.eai.config.service.ConfigServiceImpl$$EnhancerByCGLIB$$b0a3c7db.CGLIB$getUserList$18(<generated>)
at com.opshub.eai.config.service.ConfigServiceImpl$$EnhancerByCGLIB$$b0a3c7db$$FastClassByCGLIB$$d110172b.invoke(<generated>)
at net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:167)
at com.opshub.eai.config.service.ServiceInterception.intercept(ServiceInterception.java:48)
at com.opshub.eai.config.service.ConfigServiceImpl$$EnhancerByCGLIB$$b0a3c7db.getUserList(<generated>)
at com.opshub.eai.config.service.ConfigService.getUserList(ConfigService.java:99)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:745)
Edit 1:
Value of _JAVA_OPTIONS:
-Dhttp.proxyHost=ourserver.ourcompany.com -Dhttp.proxyPort=8080 -Dhttp.proxyUser=domain\user -Dhttp.proxyPassword=password -Dhttps=false

The proxy utility suggestion worked as described by #OpshubInc. in their last comment. I have put the suggestion below for future reference.
You will have to bypass localhost in your proxy settings. The TFS
Service is running locally but your machine will route the request
through proxy if local address is not bypassed. Refer C:\Program
Files\OpsHub Visual Studio Migration
Utility\Other_Resources\Resources\ProxyUtility.zip and use it to set
proxy configuration along with local bypass host set to default

Related

SonarQube cannot blame file

During a code check with SonarQube, I am getting this sort of error
java.lang.IllegalStateException: Error when executing blame for file some/file/in/project/file.hpp
at org.sonar.plugins.scm.svn.SvnBlameCommand.blame(SvnBlameCommand.java:85)
at org.sonar.plugins.scm.svn.SvnBlameCommand.blame(SvnBlameCommand.java:58)
at org.sonar.scanner.scm.ScmPublisher.publish(ScmPublisher.java:85)
at org.sonar.scanner.phases.PublishPhaseExecutor.afterSensors(PublishPhaseExecutor.java:60)
at org.sonar.scanner.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:90)
at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:180)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:135)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:121)
at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:288)
at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:283)
at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:261)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:135)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:121)
at org.sonar.scanner.task.ScanTask.execute(ScanTask.java:48)
at org.sonar.scanner.task.TaskContainer.doAfterStart(TaskContainer.java:84)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:135)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:121)
at org.sonar.scanner.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:121)
at org.sonar.batch.bootstrapper.Batch.doExecuteTask(Batch.java:116)
at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:111)
at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:63)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
at com.sun.proxy.$Proxy0.execute(Unknown Source)
at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:233)
at org.sonarsource.scanner.api.EmbeddedScanner.runAnalysis(EmbeddedScanner.java:151)
at org.sonarsource.scanner.cli.Main.runAnalysis(Main.java:123)
at org.sonarsource.scanner.cli.Main.execute(Main.java:77)
at org.sonarsource.scanner.cli.Main.main(Main.java:61)
Caused by: org.tmatesoft.svn.core.SVNException: svn: E204899: Cannot delete file 'C:\Path\to\project\.svn\tmp\annotate.3.tmp\annotate.tmp'
at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:70)
at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.deleteFile(SVNFileUtil.java:1342)
at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.deleteAll(SVNFileUtil.java:1314)
at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.deleteAll(SVNFileUtil.java:1305)
at org.tmatesoft.svn.core.internal.wc2.remote.SvnRemoteAnnotate.run(SvnRemoteAnnotate.java:143)
at org.tmatesoft.svn.core.internal.wc2.remote.SvnRemoteAnnotate.run(SvnRemoteAnnotate.java:30)
at org.tmatesoft.svn.core.internal.wc2.SvnOperationRunner.run(SvnOperationRunner.java:21)
at org.tmatesoft.svn.core.wc2.SvnOperationFactory.run(SvnOperationFactory.java:1235)
at org.tmatesoft.svn.core.wc2.SvnOperation.run(SvnOperation.java:294)
at org.tmatesoft.svn.core.wc.SVNLogClient.doAnnotate(SVNLogClient.java:295)
at org.sonar.plugins.scm.svn.SvnBlameCommand.blame(SvnBlameCommand.java:83)
... 31 more
Some additional information
This project is checked out in a Jenkins job.
No other project checked the same way have this sort of error.
This project is a big project, so code checking takes several hours.
I can blame this file in the error message (some/file/in/project/file.hpp) without problems with TortoiseSVN.
I am using SonarQube 6.7.1 LTS
SonarQube Plugin for SVN has this version 1.6.0.860
svn --version gives me this output, so it seems up to date:
svn, version 1.9.7 (r1800392)
compiled Aug 8 2017, 22:14:48 on x86-microsoft-windows
Copyright (C) 2017 The Apache Software Foundation.
This software consists of contributions made by many people;
see the NOTICE file for more information.
Subversion is open source software, see http://subversion.apache.org/
The following repository access (RA) modules are available:
* ra_svn : Module for accessing a repository using the svn network protocol.
- with Cyrus SASL authentication
- handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
- handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
- using serf 1.3.9 (compiled with 1.3.9)
- handles 'http' scheme
- handles 'https' scheme
The following authentication credential caches are available:
* Wincrypt cache in C:\Users\User\AppData\Roaming\Subversion
What I did
On the SonarQube Server, under Administration -> SCM, I added credentials.
Before doing a SonarQube check, I am now doing a svn upgrade. The same error came up when I was not doing a svn upgrade.
Does anyone have an idea, what I can do to solve this problem?
In jenkins, "Execute SonarQube scanner " plugin, can you give scm disabled parameter ?
-Dsonar.scm.disabled=True
if that does not work, in sonarqube you must disable the scm parameter.
From Project -> General Settings -> SCM -> Disable the SCM Sensor. You must disable soarqube to look for source code.

OpsHub-014371 Error (404)Not Found on User Mapping Page

I am trying to migrate source code from TFS 2010 SP1 (local on prem) to TFS Online. When I get to the User Mapping page, I get this error:
com.opshub.eai.metadata.MetadataException: OpsHub-014371: Could not
instantiate metadata implementation for For User List | TFS Source
1443539882111 ALM TFS 1443539882115, due to (404)Not Found
I am running this on the TFS App Tier itself with the database being local.
I have stopped the McAfee services.
I ran the utility as Admin.
I have only 2 users in the project and they are in both projects (I am the TFS Admin locally).
I have performed the steps in the Walkthrough, except for the process template. We shouldn't need that because we're migrating source code only.
I have cleared the cache folders.
The error entry in the log file:
09/29/2015 11:18:02,344 ERROR [http-8989-1]
(com.opshub.eai.config.service.ConfigServiceImpl) - OpsHub-014371:
Could not instantiate metadata implementation for For User List | TFS
Source 1443539882111 ALM TFS 1443539882115, due to (404)Not Found
com.opshub.eai.metadata.MetadataException: OpsHub-014371: Could not
instantiate metadata implementation for For User List | TFS Source
1443539882111 ALM TFS 1443539882115, due to (404)Not Found at
com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl.getProjectsMeta(TFSMetadataImpl.java:63)
at
com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl$$EnhancerByCGLIB$$5a4e716d.CGLIB$getProjectsMeta$0()
at
com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl$$EnhancerByCGLIB$$5a4e716d$$FastClassByCGLIB$$465c721.invoke()
at net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:167)
at
com.opshub.eai.core.adapters.caching.MetadataCacheHandler.intercept(MetadataCacheHandler.java:40)
at
com.opshub.eai.tfs.common.metadata.impl.TFSMetadataImpl$$EnhancerByCGLIB$$5a4e716d.getProjectsMeta()
at
com.opshub.eai.config.business.ConfigServiceBusiness.getUserList(ConfigServiceBusiness.java:926)
at
com.opshub.eai.config.service.ConfigServiceImpl.getUserList(ConfigServiceImpl.java:407)
at
com.opshub.eai.config.service.ConfigServiceImpl$$EnhancerByCGLIB$$f3d793b0.CGLIB$getUserList$6()
at
com.opshub.eai.config.service.ConfigServiceImpl$$EnhancerByCGLIB$$f3d793b0$$FastClassByCGLIB$$148b3d41.invoke()
at net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:167)
at
com.opshub.eai.config.service.ServiceInterception.intercept(ServiceInterception.java:44)
at
com.opshub.eai.config.service.ConfigServiceImpl$$EnhancerByCGLIB$$f3d793b0.getUserList()
at
com.opshub.eai.config.service.ConfigService.getUserList(ConfigService.java:97)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at
sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at
java.lang.reflect.Method.invoke(Unknown Source) at
org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118) at
org.apache.axis.SimpleChain.invoke(SimpleChain.java:83) at
org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281) at
org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:710) at
org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Unknown Source)
From OVSMU.log file:
2015-09-29 11:18:02,351 [1] ERROR
com.opshub.eai.metadata.MetadataException: OpsHub-014371: Could not
instantiate metadata implementation for For User List | TFS Source
1443539882111 ALM TFS 1443539882115, due to (404)Not Found
System.ServiceModel.FaultException:
com.opshub.eai.metadata.MetadataException: OpsHub-014371: Could not
instantiate metadata implementation for For User List | TFS Source
1443539882111 ALM TFS 1443539882115, due to (404)Not Found
Server stack trace:
at
System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime
operation, ProxyRpc& rpc) at
System.ServiceModel.Channels.ServiceChannel.Call(String action,
Boolean oneway, ProxyOperationRuntime operation, Object[] ins,
Object[] outs, TimeSpan timeout) at
System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage
methodCall, ProxyOperationRuntime operation) at
System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage
message)
Exception rethrown at [0]:
at
TFSMigrationUI.ViewModel.UserMappingViewModel.worker_RunWorkerCompleted(Object
sender, RunWorkerCompletedEventArgs e) in
e:\OVSMUBranch\TFSMigrationUI\ViewModel\UserMappingViewModel.cs:line
416 at
System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate
callback, Object args, Int32 numArgs) at
MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object
source, Delegate method, Object args, Int32 numArgs, Delegate
catchHandler)
Is it possible that this has something to do with the Java runtime? Perhaps I need to install a newer JRE?

Grails Reverse Engineer Database

I'm trying to evaluate Grails as a solution for an upcoming project. There is already a large database in use that won't be modified much if it all. I wan't to reverse engineer the database into GORM domain objects as a starting point.
I found one here http://www.grails.org/plugin/db-reverse-engineer. I got it installed and configured however when I run it I see the same error over and over. The stacktrace is below.
Can someone help me correct the error, or recommend another tool for reverse engineering to grails? I've used Netbeans in the past to reverse engineer databases to JPA entities that worked out pretty well. I'm hoping for something similar with Grails.
| Error Error executing script DbReverseEngineer: javax/transaction/Transaction (NOTE: Stack trace has been filtered. Us
e --verbose to see entire trace.)
java.lang.NoClassDefFoundError: javax/transaction/Transaction
at grails.plugin.reveng.GrailsJdbcBinder.readDatabaseSchema(GrailsJdbcBinder.groovy:51)
at org.hibernate.cfg.JDBCBinder.readFromDatabase(JDBCBinder.java:93)
at org.hibernate.cfg.JDBCBinder$readFromDatabase.call(Unknown Source)
at grails.plugin.reveng.GrailsJdbcMetaDataConfiguration.readFromJDBC(GrailsJdbcMetaDataConfiguration.groovy:32)
at grails.plugin.reveng.GrailsJdbcMetaDataConfiguration$readFromJDBC.call(Unknown Source)
at grails.plugin.reveng.Reenigne.buildConfiguration(Reenigne.groovy:114)
at grails.plugin.reveng.Reenigne.execute(Reenigne.groovy:60)
at grails.plugin.reveng.Reenigne$execute.call(Unknown Source)
at grails.plugin.reveng.RevengRunner.run(RevengRunner.groovy:81)
at grails.plugin.reveng.RevengRunner$run.call(Unknown Source)
at DbReverseEngineer$_run_closure1.doCall(DbReverseEngineer:36)
at org.codehaus.gant.GantMetaClass.invokeMethod(GantMetaClass.java:133)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy:1
85)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16_closure18.doCall(GantBinding.groovy)
at org.codehaus.gant.GantBinding.withTargetEvent(GantBinding.groovy:90)
at org.codehaus.gant.GantBinding.this$4$withTargetEvent(GantBinding.groovy)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy:185)
at org.codehaus.gant.GantBinding$_initializeGantBinding_closure5_closure16.doCall(GantBinding.groovy)
at gant.Gant$_dispatch_closure5.doCall(Gant.groovy:381)
at gant.Gant$_dispatch_closure7.doCall(Gant.groovy:415)
at gant.Gant$_dispatch_closure7.doCall(Gant.groovy)
at gant.Gant.withBuildListeners(Gant.groovy:427)
at gant.Gant.this$2$withBuildListeners(Gant.groovy)
at gant.Gant$this$2$withBuildListeners$0.callCurrent(Unknown Source)
at gant.Gant.dispatch(Gant.groovy:415)
at gant.Gant.this$2$dispatch(Gant.groovy)
at gant.Gant.invokeMethod(Gant.groovy)
at gant.Gant.executeTargets(Gant.groovy:591)
at gant.Gant.executeTargets(Gant.groovy:590)
Caused by: java.lang.ClassNotFoundException: javax.transaction.Transaction
... 29 more
| Error Error executing script DbReverseEngineer: javax/transaction/Transaction
Actually this plugin is not compatible with Hibernate 4... yet. But since the last push was like ages ago, it doesn't look like that you will get a new version soon enough to work with it :)
However, you can still keep using this version of Grails and the db-reverse-engineer:0.5 plugin, by switching your Hibernate version, back to 3. And it is quite easy to do so !
In BuildConfig.groovy, comment the line
runtime ":hibernate4:4.X.X.X"
And add instead:
runtime ":hibernate:3.6.10.17"
(And btw, do not forget to add the correct connector to your database, I use myself this dependency:
compile 'mysql:mysql-connector-java:5.1.22'
)
Well, the plugin uses Hibernate Tools to do the reverse-engineering, so you could try just using those directly.
There is a new version which fixs many bugs such this :It is 0.5.1 insead of 0.5
BuildConfig.groovy
runtime ':db-reverse-engineer:0.5.1'
I too faced the same problem but I didn't switch to hibernate 3.x version the main problem is connector, un comment the mysql connector in BuildConfig.groovy
and I have added the javax.transaction jar in lib folder of grails application this solved the problem

ANT SSHEXEC failing with Algorithm negotitation fail error

I am just trying to connect to a remote host using the ant sshexec task . I have the required jar in the ant lib directory and able to connect to the remote host using putty.
This is the way i am running the ssh
<sshexec host="host"
username="username"
password="password"
trust="yes"
command="ls"/>
There seems to be encryption algorith mismatch with the server. How can i specify the algorith as I don't see any attribute for this task [Ant doc][1]. This is the error log i am getting:
com.jcraft.jsch.JSchException: Algorithm negotiation fail
at com.jcraft.jsch.Session.receive_kexinit(Session.java:540)
at com.jcraft.jsch.Session.connect(Session.java:288)
at com.jcraft.jsch.Session.connect(Session.java:145)
at org.apache.tools.ant.taskdefs.optional.ssh.SSHBase.openSession(SSHBase.java:212)
at org.apache.tools.ant.taskdefs.optional.ssh.SSHExec.execute(SSHExec.java:158)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:357)
at org.apache.tools.ant.Target.performTasks(Target.java:385)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
at org.apache.tools.ant.Main.runBuild(Main.java:758)
at org.apache.tools.ant.Main.startAnt(Main.java:217)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
TL;DR edit your sshd_config and enable support for diffie-hellman-group-exchange-sha1 and diffie-hellman-group1-sha1 in KexAlgorithms:
KexAlgorithms curve25519-sha256#libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1
KexAlgorithms curve25519-sha256#libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1
I suspect that the problem appeared after the following change in OpenSSH 6.7: "The default set of ciphers and MACs has been altered to remove unsafe algorithms.". (see changelog). This version was released on Oct, 6, and made it on Oct, 21 to Debian testing (see Debian changelog).
OpenSSH enables only the following key exchange algorithms by default:
curve25519-sha256#libssh.org
ecdh-sha2-nistp256
ecdh-sha2-nistp384
ecdh-sha2-nistp521
diffie-hellman-group-exchange-sha256
diffie-hellman-group14-sha1
Whereas JSch claims to support these algorithms (see under "features") for key exchange:
diffie-hellman-group-exchange-sha1
diffie-hellman-group1-sha1
So indeed, they cannot agree on a common key exchange algorithm. Updating sshd_config (and restarting the SSH server) does the trick. Apparently JSch is supposed to support the "diffie-hellman-group-exchange-sha256" method since version 0.1.50 (see changelog).
I had the same error trying to connect to OS X 10.11.6 and could fix it by replacing ~/.ant/lib/jsch-0.1.51.jar with the latest ~/.ant/lib/jsch-0.1.54.jar.

Grails application is throwing NPE on Websphere 6.1

I have deployed my Grails 1.3.7 app to websphere 6.1.0.25. The app throws NPE
ERROR webapp.WebApp - [Servlet Error]-[Filter [DeclaredResourcesPluginFilter]: filter is unavailable.]: java.lang.NullPointerException
and it does not display the images. It seems they are related but not sure.
Things that might be related:
1- These are some of the related plugins I'm using
runtime ":resources:1.1.6"
runtime ":zipped-resources:1.0"
runtime ":cached-resources:1.0"
compile ":cache-headers:1.1.5"
compile ":lesscss-resources:1.3.0"
2- I have setup Websphere according to Grails deployment document
meaning I have set
"Generic JVM arguments" to "-Xverify:none" and
com.ibm.ws.classloader.getInputStream.enableIOException value: true and
com.ibm.ws.webcontainer.invokeFiltersCompatibility value: true
I appreciate any suggestion on how to debug this issue.
Here: is the full stacktrace:
[WebContainer : 0] ERROR webapp.WebApp - [Servlet Error]-[Filter [DeclaredResourcesPluginFilter]: filter is unavailable.]: java.lang.NullPointerException
at com.ibm.ws.webcontainer.srt.SRTServletResponse.setContentType(SRTServletResponse.java:1141)
at sun.reflect.GeneratedMethodAccessor635.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:2395)
at groovy.lang.ExpandoMetaClass.setProperty(ExpandoMetaClass.java:1129)
at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:3315)
at org.codehaus.groovy.runtime.InvokerHelper.setProperty(InvokerHelper.java:183)
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.setProperty(ScriptBytecodeAdapter.java:483)
at org.grails.plugin.resource.ResourceProcessor.processModernResource(ResourceProcessor.groovy:293)
at org.grails.plugin.resource.ResourceProcessor$processModernResource.call(Unknown Source)
at org.grails.plugin.resource.ProcessingFilter.doFilter(ProcessingFilter.groovy:39)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:237)
at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167)
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:87)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:837)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:747)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:700)
at com.ibm.ws.wswebcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:115)
at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.invokeFilters(DefaultExtensionProcessor.java:849)
at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:785)
at com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:113)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3507)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:269)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:815)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1466)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:122)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:458)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:387)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:267)
at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214)
at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture$1.run(AsyncChannelFuture.java:205)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1497)
I added this JIRA for the Resources Plugin
here
This is a problem with WAS environment for versions 7.x and below.
This exception is generally seen when MIME types of the static resources are not set in WAS (default_host), hence you do not see the images. If you are looking for the .jpg or .png images which missing in the view then the corresponding MIME types has to be added in the server. WAS Admin -> Environments -> Virtual Host -> default_host -> MIME Types.
This issue is persistent in Websphere 7.x as well.

Resources