nexus restlet not downloading index - restlet

When I add http://maven.restlet.org as proxy repository to my nexus repository (version 1.9.2.4), nexus is not able to download the remote indexes.
I see the following error in the nexus log:
org.sonatype.nexus.proxy.ItemNotFoundException: The remoteURL we
requested does not exists on remote server
(remoteUrl="http://maven.restlet.org/.index/nexus-maven-repository-index.gz
Is this a restlet or a nexus problem? How can I use Restlet with Nexus?
The whole stack-trace is:
Cannot fetch remote index for repository "restlet" [id=restlet]
java.io.FileNotFoundException: nexus-maven-repository-index.gz (item
not found)
at org.sonatype.nexus.index.DefaultIndexerManager$2.retrieve(DefaultIndexerManager.java:1114)
at org.apache.maven.index.updater.DefaultIndexUpdater.loadIndexDirectory(DefaultIndexUpdater.java:191)
at org.apache.maven.index.updater.DefaultIndexUpdater.access$300(DefaultIndexUpdater.java:76)
at org.apache.maven.index.updater.DefaultIndexUpdater$LuceneIndexAdaptor.setIndexFile(DefaultIndexUpdater.java:642)
at org.apache.maven.index.updater.DefaultIndexUpdater.fetchAndUpdateIndex(DefaultIndexUpdater.java:861)
at org.apache.maven.index.updater.DefaultIndexUpdater.fetchAndUpdateIndex(DefaultIndexUpdater.java:157)
at org.sonatype.nexus.index.DefaultIndexerManager.updateRemoteIndex(DefaultIndexerManager.java:1132)
at org.sonatype.nexus.index.DefaultIndexerManager.downloadRepositoryIndex(DefaultIndexerManager.java:1017)
at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:892)
at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:841)
at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:815)
at org.sonatype.nexus.tasks.ReindexTaskHandlerLegacy.reindexRepository(ReindexTaskHandlerLegacy.java:60)
at org.sonatype.nexus.tasks.AbstractIndexerTask.doRun(AbstractIndexerTask.java:72)
at org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:159)
at org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:437)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown
Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown
Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source) Caused by: org.sonatype.nexus.proxy.ItemNotFoundException: The remoteURL we
requested does not exists on remote server
(remoteUrl="http://maven.restlet.org/.index/nexus-maven-repository-index.gz")
at org.sonatype.nexus.proxy.storage.remote.commonshttpclient.CommonsHttpClientRemoteStorage.retrieveItem(CommonsHttpClientRemoteStorage.java:240)
at org.sonatype.nexus.index.DefaultIndexerManager$2.retrieve(DefaultIndexerManager.java:1097)
... 21 more

You do not need the remote index to use that repository. You won't be able to use the UI to search for artifacts contained in that repository, but Nexus will be able to access artifacts there when directly asked for them (as in "defined as a dependency in a POM").
EDIT: This question is a duplicate of Nexus - proxy repositories with no indexes?.

Related

Deployment fails when uploading s3 connector to WSO2ESB

When uploading the Amazon s3 connector zip(https://store.wso2.com/store/assets/esbconnector/8d95de41-91ee-44b4-a428-81f71d523643) to the esb I get the quoted stack trace and the connector does not get added. I have tried this with both a clean v4.8.1 and a v4.9.0, both giving the same error.
Anyone has any idea what the problem is/how to solve it?
[2016-04-26 17:20:51,424] ERROR - LibraryArtifactDeployer Deployment of synapse
artifact failed for synapse libray at : -ESB LOCATION-\repository\deployment\server\synapse-libs\amazons3-connec
tor-1.0.0.zip : Error when resolving Dependencies for lib : {org.wso2.carbon.con
nector}amazons3
org.apache.synapse.deployers.SynapseArtifactDeploymentException: Error when reso
lving Dependencies for lib : {org.wso2.carbon.connector}amazons3
at org.apache.synapse.libraries.util.LibDeployerUtils.searchAndResolveDe
pendencies(LibDeployerUtils.java:244)
at org.apache.synapse.libraries.util.LibDeployerUtils.createSynapseLibra
ry(LibDeployerUtils.java:80)
at org.apache.synapse.deployers.LibraryArtifactDeployer.deploy(LibraryAr
tifactDeployer.java:60)
at org.apache.axis2.deployment.repository.util.DeploymentFileData.deploy
(DeploymentFileData.java:136)
at org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngin
e.java:807)
at org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoL
ist.java:144)
at org.apache.axis2.deployment.RepositoryListener.update(RepositoryListe
ner.java:377)
at org.apache.axis2.deployment.RepositoryListener.checkServices(Reposito
ryListener.java:254)
at org.apache.axis2.deployment.RepositoryListener.startListener(Reposito
ryListener.java:371)
at org.apache.axis2.deployment.scheduler.SchedulerTask.checkRepository(S
chedulerTask.java:59)
at org.apache.axis2.deployment.scheduler.SchedulerTask.run(SchedulerTask
.java:67)
at org.wso2.carbon.core.deployment.CarbonDeploymentSchedulerTask.runAxis
Deployment(CarbonDeploymentSchedulerTask.java:93)
at org.wso2.carbon.core.deployment.CarbonDeploymentSchedulerTask.run(Car
bonDeploymentSchedulerTask.java:138)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
I think this is a small bug from store site you can get connector zip through build code from here. it's works fine to me.
[2016-04-27 22:43:17,557] INFO - LibraryArtifactDeployer Synapse Library named '{org.wso2.carbon.connector}amazons3' has been deployed from file : /home/rajjaz/Documents/wso2esb-4.9.0/repository/deployment/server/synapse-libs/amazons3-connector-1.0.1-SNAPSHOT.zip
[2016-04-27 22:43:20,621] INFO - SynapseImportFactory Successfully created Synapse Import: amazons3

Getting Exception: java.lang.SecurityException: attempted to open sandboxed jar as Trusted-Only

We need to sign all 5 .class java files. That we have done by creating a .jar file and signed it too. But while executing my web application it is showing below error message in Java Console
java.lang.SecurityException: attempted to open sandboxed jar https://xxxxxxxxxxx.com/xxxx/JavaApplet.jar as Trusted-Only
at com.sun.deploy.security.CPCallbackHandler$ParentElement.checkResource(Unknown Source)
at com.sun.deploy.security.DeployURLClassPath$JarLoader.checkResource(Unknown Source)
at com.sun.deploy.security.DeployURLClassPath$JarLoader.getResource(Unknown Source)
at com.sun.deploy.security.DeployURLClassPath.getResource(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.plugin2.applet.Plugin2ClassLoader.findClassHelper(Unknown Source)
at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Exception: java.lang.SecurityException: attempted to open sandboxed jar https://xxxxxxxxxxx.com/xxxx/JavaApplet.jar as Trusted-Only*
I am not sure about this error. I have signed Jar 3-4 times after getting this error but I am getting same error again again.
Please can anybody help me if I am doing something wrong?
Check your Manifest.mf file of jar. This should contain the Trusted-Library: true if you are using MixedCode(Applet called from the javascript) and your files are self signed. oracle has released latest security updates in Java 7 update 21. According to the release notes you must sign your code with CA certificates only, else JRE will treat your code as malicious. oracle is totally deprecating the Mixedcode. Please check the release notes of latest updates. But before adding the attribute Trusted-Library: true in manifest.mf make sure you are aware of the effects of the attribute.

Cannot start Glassfish via Eclipse Plugin (ConnectException)

On a Windows7 64 bit system, I have Eclipse Juno Service Release 1 and have installed the Glassfish plugin directly from http://dlc.sun.com.edgesuite.net/glassfish/eclipse/juno/.
I have also installed the open source version of Glassfish 3.1.2.2 (via the zip file) to my machine.
I have created server runtime environments for my installed version of Glassfish and also the embedded version of Glassfish 3.1.2.2. I have created a server in Eclipse for each of the runtime environments.
When I try to start either of them from Eclispe, I get this error (which is not that helpful):
!ENTRY oracle.eclipse.tools.glassfish 4 1 2012-12-11 16:20:16.182
!MESSAGE GlassFish: error
!STACK 0
java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.<init>(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
at com.sun.enterprise.jst.server.sunappsrv.commands.CommandRunner.call(CommandRunner.java:607)
at com.sun.enterprise.jst.server.sunappsrv.commands.CommandRunner.call(CommandRunner.java:1)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
!ENTRY oracle.eclipse.tools.glassfish 4 150 2012-12-11 16:20:16.189
!MESSAGE The Eclipse plugin cannot communicate with the GlassFish server....
!STACK 0
java.lang.RuntimeException: The Eclipse plugin cannot communicate with the GlassFish server.Please, check for other software blocking or using this port, or firewall configuration, or VPN setup which might block some ports...
at com.sun.enterprise.jst.server.sunappsrv.SunAppServerLaunch.launch(SunAppServerLaunch.java:155)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:855)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:704)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:697)
at org.eclipse.wst.server.core.internal.Server.startImpl2(Server.java:3484)
at org.eclipse.wst.server.core.internal.Server.startImpl(Server.java:3420)
at org.eclipse.wst.server.core.internal.Server$StartJob.run(Server.java:367)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
I can start my locally installed Glassfish (i.e. not the embedded one) via the command line scripts. I have triple checked that there are no port conflicts with 4848, 8080 and 8181. My firewall is currently off (when I am on my corporate domain).
Can anybody suggest why I cannot start Glassfish via the Eclipse plugin?
I did two things, so I don't know which of the two fixed the situation for me.
Change Ports in domain.xml
remove the osgi-cache folder in the domain folder.
After going to "asadmin" you should be able to start any of the domain on the Glassfish server using below command and SAME WILL REFLECT IN THE ECLIPSE as soon as you start or stop any domain of Glassfish server (domain1 is default)
"Bypass proxy servers for local address" should be checked in the Internet Option>Connection>lan setting tab..
This will work

Error configuring dynamic methods for plugin [resources:1.1.6]: Cannot get property 'pluginPath'

Using grails 1.3.7 i have no problem compiling and running my project from my STS.
The error listed below occurs after packaging the WAR and trying to deply it from apache tomcat. This problem has not occured before and i have had success deploying it to apache tomcat in the same fashion before. (Using apache-tomcat-7.0.26).
In regards to the error:
at BootstrapResources.run(BootstrapResources.groovy:23) row 23 points to:
def twitterbootstrapPlugin = applicationContext.pluginManager.getGrailsPlugin('twitter-bootstrap')
row 23 --> twitterbootstrapPluginDir = applicationContext.getResource(twitterbootstrapPlugin.pluginPath).file
ERROR [pool-2-thread-1] (DefaultGrailsPluginManager.java:818) - Error configuring dynamic methods for plugin [resources:1.1.6]: Cannot get property 'pluginPath' on null object java.lang.NullPointerException: Cannot get property 'pluginPath' on null object
at BootstrapResources.run(BootstrapResources.groovy:23)
at org.grails.plugin.resource.module.ModuleDeclarationsFactory$_getModuleDeclarations_closure2.doCall(ModuleDeclarationsFactory.groovy:43)
at org.grails.plugin.resource.module.ModuleDeclarationsFactory.getModuleDeclarations(ModuleDeclarationsFactory.groovy:38)
at org.grails.plugin.resource.module.ModuleDeclarationsFactory.getModuleDeclarations(ModuleDeclarationsFactory.groovy)
at org.grails.plugin.resource.module.ModuleDeclarationsFactory$getModuleDeclarations.call(Unknown Source)
at org.grails.plugin.resource.ResourceProcessor.loadModules(ResourceProcessor.groovy:720)
at org.grails.plugin.resource.ResourceProcessor.this$2$loadModules(ResourceProcessor.groovy)
at org.grails.plugin.resource.ResourceProcessor$this$2$loadModules.callCurrent(Unknown Source)
at org.grails.plugin.resource.ResourceProcessor.reloadAll(ResourceProcessor.groovy:1056)
at org.grails.plugin.resource.ResourceProcessor$reloadAll.call(Unknown Source)
at ResourcesGrailsPlugin$_closure3.doCall(ResourcesGrailsPlugin.groovy:172)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
The latest additions to the project has been spring-security-core, but i cant see how this could be an issue.
Anyone has any ideas?
This is probably not a generic solution for this problem, but for my project this was an issue of my maven packaging not including all the needed plugins for successful deployment.
For some reason having defined my plugins within my BuildConfig.groovy file as follows:
plugins{
build ':whateverplugin:0.1'
compile ':whateverplugin:0.1'
runtime ':whateverplugin:0.1'
test ':whateverplugin:0.1'
}
The plugins were not including in the war packaging when packaging my project issuing the command:
mvn package -Dmaven.skip.test=true

Jenkins slave throws "Classloading from system classloader disabled" exception

When running a Maven2 job on a slave instance (Master on AIX 5.3; slave on Windows 2008(R2)), I get the following message (complete stack trace pasted in below): "java.lang.ClassNotFoundException: Classloading from system classloader disabled". This happens with the first job after the slave instance is started (it's running as a Windows service). After that, I get a "java.lang.NoClassDefFoundError: Could not initialize class hudson.maven.MavenModuleSetBuild" error.
If I create a freestyle job, and include the maven command as a batch command to run on the slave, it works fine. The Maven2 job appears to locate Maven on the slave machine, but it apparently can't find the maven-plugin (probably due to the classloading error).
I've searched and posted a ticket to the jenkins-ci site, but no luck as of yet. Has anyone run into this problem?
Stacktrace:
Found mavenVersion 2.2.1 from file jar:file:/C:/apache-maven-2.2.1/lib/maven-2.2.1-uber.jar!/META-INF/maven/org.apache.maven/maven-core/pom.properties
Parsing POMs
ERROR: Failed to parse POMs
hudson.util.IOException2: remote file operation failed: c:\jenkins-slave\workspace\AO_SISO_AT-smoketest-CIT1 at hudson.remoting.Channel#7b827b82:10.40.163.105
at hudson.FilePath.act(FilePath.java:752)
at hudson.FilePath.act(FilePath.java:738)
at hudson.maven.MavenModuleSetBuild$RunnerImpl.parsePoms(MavenModuleSetBuild.java:817)
at hudson.maven.MavenModuleSetBuild$RunnerImpl.doRun(MavenModuleSetBuild.java:617)
at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:429)
at hudson.model.Run.run(Run.java:1374)
at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:467)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:145)
Caused by: java.io.IOException: Remote call on 10.40.163.105 failed
at hudson.remoting.Channel.call(Channel.java:652)
at hudson.FilePath.act(FilePath.java:745)
... 8 more
Caused by: java.lang.ExceptionInInitializerError
at hudson.maven.MavenModuleSetBuild$PomParser.invoke(MavenModuleSetBuild.java:1236)
at hudson.maven.MavenModuleSetBuild$PomParser.invoke(MavenModuleSetBuild.java:1110)
at hudson.FilePath$FileCallableWrapper.call(FilePath.java:1956)
at hudson.remoting.UserRequest.perform(UserRequest.java:118)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:270)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at hudson.remoting.Engine$1$1.run(Engine.java:60)
at java.lang.Thread.run(Unknown Source)
Caused by: com.thoughtworks.xstream.XStream$InitializationException: Could not instantiate converter : com.thoughtworks.xstream.converters.extended.DurationConverter : null
at com.thoughtworks.xstream.XStream.dynamicallyRegisterConverter(XStream.java:735)
at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:699)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:445)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:385)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:323)
at hudson.util.XStream2.<init>(XStream2.java:62)
at hudson.model.Run.<clinit>(Run.java:1867)
... 13 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.thoughtworks.xstream.XStream.dynamicallyRegisterConverter(XStream.java:728)
... 19 more
Caused by: javax.xml.datatype.DatatypeConfigurationException: Provider org.apache.xerces.jaxp.datatype.DatatypeFactoryImpl not found
at javax.xml.datatype.DatatypeFactory.newInstance(Unknown Source)
at com.thoughtworks.xstream.converters.extended.DurationConverter.<init>(DurationConverter.java:33)
... 24 more
Caused by: java.lang.ClassNotFoundException: Classloading from system classloader disabled
at java.lang.Throwable.<init>(Throwable.java:56)
at java.lang.Throwable.<init>(Throwable.java:80)
at java.lang.ClassNotFoundException.<init>(ClassNotFoundException.java:80)
at hudson.remoting.RemoteClassLoader$ClassLoaderProxy.fetch2(RemoteClassLoader.java:399)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:615)
at hudson.remoting.RemoteInvocationHandler$RPCRequest.perform(RemoteInvocationHandler.java:274)
at hudson.remoting.Request$2.run(Request.java:270)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:432)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:284)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
at java.lang.Thread.run(Thread.java:799)
I had similar issue. Researched internet but did not get any solution. Finally debugged the jenkins/hudson and resolved this issue.
The root cause of this error is that recent versions of jenkin is shipped with xml parser within jenkins.war file. Looks like if your server already has this jar file, it won't let jenkin application to reload its own version of xml parsers. So to resolve this issue I have removed file xercesImpl-2.9.1.jar from WEB-INF/lib directory of jenkins.war file. After that replaced existing war file and restarted server. And it worked as without any problem.