You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "John, Ansu" <An...@thomascookonline.com> on 2013/01/17 16:31:50 UTC
String index out of range: -12 in
ReleaseUtils.loadResolvedDependencies() when using Parent-Module-Layout
Hi
I have a Parent - mutimodule project layout.
I get the following error while running release:prepare -DdryRun=true
maven-release-plugin:2.4:prepare failed: String index out of range: -12
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:225)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.jvnet.hudson.maven3.launcher.Maven3Launcher.main(Maven3Launcher.java:79)
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:616)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:329)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:239)
at org.jvnet.hudson.maven3.agent.Maven3Main.launch(Maven3Main.java:158)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:100)
at hudson.maven.Maven3Builder.call(Maven3Builder.java:66)
at hudson.remoting.UserRequest.perform(UserRequest.java:118)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:326)
at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:679)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-cli of goal org.apache.maven.plugins:maven-release-plugin:2.4:prepare failed: String index out of range: -12
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:110)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 27 more
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -12
at java.lang.String.substring(String.java:1949)
at org.apache.maven.shared.release.config.ReleaseUtils.loadResolvedDependencies(ReleaseUtils.java:256)
at org.apache.maven.shared.release.config.ReleaseUtils.copyPropertiesToReleaseDescriptor(ReleaseUtils.java:172)
at org.apache.maven.plugins.release.PrepareReleaseMojo.prepareRelease(PrepareReleaseMojo.java:271)
at org.apache.maven.plugins.release.PrepareReleaseMojo.execute(PrepareReleaseMojo.java:232)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
... 28 more
channel stopped
Finished: FAILURE
Could anybody throw some light?
Thank you for the help!!
Regards
Ansu
Re: String index out of range: -12 in ReleaseUtils.loadResolvedDependencies()
when using Parent-Module-Layout
Posted by Mirko Friedenhagen <mf...@gmail.com>.
Hello Robert,
I created http://jira.codehaus.org/browse/MRELEASE-834
(release:prepare fails when a system property starting with dependency
is given).
Regards Mirko
--
http://illegalstateexception.blogspot.com/
https://github.com/mfriedenhagen/
https://bitbucket.org/mfriedenhagen/
On Fri, Apr 12, 2013 at 6:39 PM, Robert Scholte <rf...@apache.org> wrote:
> Hi Mirko,
>
> Hmmm, just noticed I answered the wrong message of this thread :S
> But this is interesting.
>
> I can't find a JIRA issue for it, so feel free to create one.
>
> Robert
>
> Op Fri, 12 Apr 2013 17:44:29 +0200 schreef Mirko Friedenhagen
> <mf...@gmail.com>:
>
>
>> Hello,
>>
>> I probably found the cause: in our Jenkins instance we had set
>> MAVEN_OPTS="....-Ddependency.locations.enabled=false". This caused no
>> problems during normal SNAPSHOT runs but we could not get the
>> release-plugin working. Nothing was seen even with "-X",
>> release.properties
>> is not even started. Removing the property above from MAVEN_OPTS solved
>> the
>> proplem. I am not sure whether and where to create an issue for this
>> (maybe
>> it just works as intended :-)).
>>
>> Regards
>> Mirko
>>
>> Regards Mirko
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: String index out of range: -12 in
ReleaseUtils.loadResolvedDependencies() when using Parent-Module-Layout
Posted by Robert Scholte <rf...@apache.org>.
Hi Mirko,
Hmmm, just noticed I answered the wrong message of this thread :S
But this is interesting.
I can't find a JIRA issue for it, so feel free to create one.
Robert
Op Fri, 12 Apr 2013 17:44:29 +0200 schreef Mirko Friedenhagen
<mf...@gmail.com>:
> Hello,
>
> I probably found the cause: in our Jenkins instance we had set
> MAVEN_OPTS="....-Ddependency.locations.enabled=false". This caused no
> problems during normal SNAPSHOT runs but we could not get the
> release-plugin working. Nothing was seen even with "-X",
> release.properties
> is not even started. Removing the property above from MAVEN_OPTS solved
> the
> proplem. I am not sure whether and where to create an issue for this
> (maybe
> it just works as intended :-)).
>
> Regards
> Mirko
>
> Regards Mirko
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: String index out of range: -12 in ReleaseUtils.loadResolvedDependencies()
when using Parent-Module-Layout
Posted by Mirko Friedenhagen <mf...@gmail.com>.
Hello,
I probably found the cause: in our Jenkins instance we had set
MAVEN_OPTS="....-Ddependency.locations.enabled=false". This caused no
problems during normal SNAPSHOT runs but we could not get the
release-plugin working. Nothing was seen even with "-X", release.properties
is not even started. Removing the property above from MAVEN_OPTS solved the
proplem. I am not sure whether and where to create an issue for this (maybe
it just works as intended :-)).
Regards
Mirko
Regards Mirko
--
http://illegalstateexception.blogspot.com/
https://github.com/mfriedenhagen/
https://bitbucket.org/mfriedenhagen/
On Fri, Jan 18, 2013 at 5:13 PM, Wayne Fay <wa...@gmail.com> wrote:
> Looks like a section of code that could benefit from some debug-level
> logging. Then OP could just turn on -X and send us more useful output.
>
> Wayne
>
> On Fri, Jan 18, 2013 at 8:26 AM, Robert Scholte <rf...@apache.org>
> wrote:
> >
> http://maven.apache.org/maven-release/maven-release-manager/xref/org/apache/maven/shared/release/config/ReleaseUtils.html#256
> >
> > I'm interested in your release.properties as well.
> > It looks like there's a property starting with 'dependency.' which
> doesn't
> > end with '.development' or '.release'
> > This should not be possible.
> >
> > thanks,
> > Robert
> >
> > Op Fri, 18 Jan 2013 09:11:39 +0100 schreef <th...@vkb.de>:
> >
> >
> >> Hi,
> >>
> >>> maven-release-plugin:2.4:prepare failed: String index out of range: -12
> >>>
> >>> at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >>> (MojoExecutor.java:225)
> >>
> >>
> >> *snip*
> >>
> >> Have you tried running "mvn -e -X ..."?
> >> Perhaps there's something missing in your pom.xml, such as an invalid
> >> property that is referenced somewhere, an empty or missing plugin
> >> configuration section etc.pp.
> >>
> >>
> >> HTH
> >>
> >> Thorsten
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
Re: String index out of range: -12 in ReleaseUtils.loadResolvedDependencies()
when using Parent-Module-Layout
Posted by Wayne Fay <wa...@gmail.com>.
Looks like a section of code that could benefit from some debug-level
logging. Then OP could just turn on -X and send us more useful output.
Wayne
On Fri, Jan 18, 2013 at 8:26 AM, Robert Scholte <rf...@apache.org> wrote:
> http://maven.apache.org/maven-release/maven-release-manager/xref/org/apache/maven/shared/release/config/ReleaseUtils.html#256
>
> I'm interested in your release.properties as well.
> It looks like there's a property starting with 'dependency.' which doesn't
> end with '.development' or '.release'
> This should not be possible.
>
> thanks,
> Robert
>
> Op Fri, 18 Jan 2013 09:11:39 +0100 schreef <th...@vkb.de>:
>
>
>> Hi,
>>
>>> maven-release-plugin:2.4:prepare failed: String index out of range: -12
>>>
>>> at org.apache.maven.lifecycle.internal.MojoExecutor.execute
>>> (MojoExecutor.java:225)
>>
>>
>> *snip*
>>
>> Have you tried running "mvn -e -X ..."?
>> Perhaps there's something missing in your pom.xml, such as an invalid
>> property that is referenced somewhere, an empty or missing plugin
>> configuration section etc.pp.
>>
>>
>> HTH
>>
>> Thorsten
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: String index out of range: -12 in
ReleaseUtils.loadResolvedDependencies() when using Parent-Module-Layout
Posted by Robert Scholte <rf...@apache.org>.
http://maven.apache.org/maven-release/maven-release-manager/xref/org/apache/maven/shared/release/config/ReleaseUtils.html#256
I'm interested in your release.properties as well.
It looks like there's a property starting with 'dependency.' which doesn't
end with '.development' or '.release'
This should not be possible.
thanks,
Robert
Op Fri, 18 Jan 2013 09:11:39 +0100 schreef <th...@vkb.de>:
> Hi,
>
>> maven-release-plugin:2.4:prepare failed: String index out of range: -12
>>
>> at org.apache.maven.lifecycle.internal.MojoExecutor.execute
>> (MojoExecutor.java:225)
>
> *snip*
>
> Have you tried running "mvn -e -X ..."?
> Perhaps there's something missing in your pom.xml, such as an invalid
> property that is referenced somewhere, an empty or missing plugin
> configuration section etc.pp.
>
>
> HTH
>
> Thorsten
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: String index out of range: -12 in ReleaseUtils.loadResolvedDependencies() when
using Parent-Module-Layout
Posted by th...@vkb.de.
Hi,
> maven-release-plugin:2.4:prepare failed: String index out of range: -12
>
> at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> (MojoExecutor.java:225)
*snip*
Have you tried running "mvn -e -X ..."?
Perhaps there's something missing in your pom.xml, such as an invalid
property that is referenced somewhere, an empty or missing plugin
configuration section etc.pp.
HTH
Thorsten
Re: String index out of range: -12 in
ReleaseUtils.loadResolvedDependencies() when using Parent-Module-Layout
Posted by Robert Scholte <rf...@apache.org>.
http://maven.apache.org/maven-release/maven-release-manager/xref/org/apache/maven/shared/release/config/ReleaseUtils.html#256
The plugin will read the release.properties and will collect the versions
per dependency.
It seems like there is a property which starts with "dependency.", but
doesn't contain ".development" or ".release".
That should not be possible.
If you could figure out which property is causing this issue (and maybe
can explain where this property is coming from), then please create an
issue at JIRA for it with the testcase.
Robert
Op Thu, 17 Jan 2013 16:31:50 +0100 schreef John, Ansu
<An...@thomascookonline.com>:
> Hi
>
> I have a Parent - mutimodule project layout.
>
> I get the following error while running release:prepare -DdryRun=true
>
> maven-release-plugin:2.4:prepare failed: String index out of range: -12
>
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:225)
>
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
>
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
>
> at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
>
> at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
>
> at
> org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
>
> at
> org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
>
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
>
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
>
> at
> org.jvnet.hudson.maven3.launcher.Maven3Launcher.main(Maven3Launcher.java:79)
>
> 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:616)
>
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:329)
>
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:239)
>
> at
> org.jvnet.hudson.maven3.agent.Maven3Main.launch(Maven3Main.java:158)
>
> at hudson.maven.Maven3Builder.call(Maven3Builder.java:100)
>
> at hudson.maven.Maven3Builder.call(Maven3Builder.java:66)
>
> at hudson.remoting.UserRequest.perform(UserRequest.java:118)
>
> at hudson.remoting.UserRequest.perform(UserRequest.java:48)
>
> at hudson.remoting.Request$2.run(Request.java:326)
>
> at
> hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
>
> at
> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
>
> at java.util.concurrent.FutureTask.run(FutureTask.java:166)
>
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
>
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
>
> at java.lang.Thread.run(Thread.java:679)
>
> Caused by: org.apache.maven.plugin.PluginExecutionException: Execution
> default-cli of goal
> org.apache.maven.plugins:maven-release-plugin:2.4:prepare failed: String
> index out of range: -12
>
> at
> org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:110)
>
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
>
> ... 27 more
>
> Caused by: java.lang.StringIndexOutOfBoundsException: String index out
> of range: -12
>
> at java.lang.String.substring(String.java:1949)
>
> at
> org.apache.maven.shared.release.config.ReleaseUtils.loadResolvedDependencies(ReleaseUtils.java:256)
>
> at
> org.apache.maven.shared.release.config.ReleaseUtils.copyPropertiesToReleaseDescriptor(ReleaseUtils.java:172)
>
> at
> org.apache.maven.plugins.release.PrepareReleaseMojo.prepareRelease(PrepareReleaseMojo.java:271)
>
> at
> org.apache.maven.plugins.release.PrepareReleaseMojo.execute(PrepareReleaseMojo.java:232)
>
> at
> org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
>
> ... 28 more
>
> channel stopped
>
> Finished: FAILURE
>
>
>
> Could anybody throw some light?
>
>
>
> Thank you for the help!!
>
> Regards
> Ansu
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org