[JIRA] (JENKINS-12615) Discard Old Builds does not warn the user when no builds will be discarded

12 views
Skip to first unread message

nisshah1499@gmail.com (JIRA)

unread,
May 15, 2019, 6:00:03 AM5/15/19
to jenkinsc...@googlegroups.com
Nisarg Shah commented on Improvement JENKINS-12615
 
Re: Discard Old Builds does not warn the user when no builds will be discarded

I would like to work on this.

I am assigning this issue to myself.

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

nisshah1499@gmail.com (JIRA)

unread,
May 15, 2019, 6:01:03 AM5/15/19
to jenkinsc...@googlegroups.com

nisshah1499@gmail.com (JIRA)

unread,
May 24, 2019, 9:11:02 AM5/24/19
to jenkinsc...@googlegroups.com
 
Re: Discard Old Builds does not warn the user when no builds will be discarded

Jesse Glick 

In implementation, I have just added one if condition(type of flag) in LogRotator.java. Whenever value of numToKeep and daysToKeep are not blank, then according to flag(new variable declared) message will be displayed. Currently I have added only if condition and I got error. I have searched regarding this error, but I am not getting it clear. Error is of failure of JUnit tests. But I don't know why it failed.

[ERROR] Tests run: 7, Failures: 0, Errors: 7, Skipped: 0, Time elapsed: 0.006 s <<< FAILURE! - in hudson.cli.PrivateKeyProviderTest
[ERROR] loadKeyBroken(hudson.cli.PrivateKeyProviderTest) Time elapsed: 0.001 s <<< ERROR!
java.lang.Exception: Unexpected exception, expected<java.lang.IllegalArgumentException> but was<java.nio.file.NoSuchFileException>
at org.junit.internal.runners.statements.ExpectException.evaluate(ExpectException.java:28)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:236)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:386)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:323)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:143)
Caused by: java.nio.file.NoSuchFileException: C:\Open%20Source\cli\target\test-classes\hudson\cli\openssh-broken
at sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:79)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:97)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:102)
at sun.nio.fs.WindowsFileSystemProvider.newByteChannel(WindowsFileSystemProvider.java:230)
at java.nio.file.Files.newByteChannel(Files.java:361)
at java.nio.file.Files.newByteChannel(Files.java:407)
at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384)
at java.nio.file.Files.newInputStream(Files.java:152)
at hudson.cli.PrivateKeyProvider.readPemFile(PrivateKeyProvider.java:132)
at hudson.cli.PrivateKeyProvider.loadKey(PrivateKeyProvider.java:128)
at hudson.cli.PrivateKeyProviderTest.loadKeyBroken(PrivateKeyProviderTest.java:102)
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:498)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.internal.runners.statements.ExpectException.evaluate(ExpectException.java:19)
... 16 more
[ERROR] loadKeyDSA(hudson.cli.PrivateKeyProviderTest) Time elapsed: 0 s <<< ERROR!
java.nio.file.NoSuchFileException: C:\Open%20Source\cli\target\test-classes\hudson\cli\dsa
at sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:79)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:97)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:102)
at sun.nio.fs.WindowsFileSystemProvider.newByteChannel(WindowsFileSystemProvider.java:230)
at java.nio.file.Files.newByteChannel(Files.java:361)
at java.nio.file.Files.newByteChannel(Files.java:407)
at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384)
at java.nio.file.Files.newInputStream(Files.java:152)
at hudson.cli.PrivateKeyProvider.readPemFile(PrivateKeyProvider.java:132)
at hudson.cli.PrivateKeyProvider.loadKey(PrivateKeyProvider.java:128)
at hudson.cli.PrivateKeyProviderTest.loadKeyDSA(PrivateKeyProviderTest.java:26)
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:498)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:236)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:386)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:323)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:143)

[ERROR] loadKeyRSA(hudson.cli.PrivateKeyProviderTest) Time elapsed: 0.001 s <<< ERROR!
java.nio.file.NoSuchFileException: C:\Open%20Source\cli\target\test-classes\hudson\cli\rsa
at sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:79)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:97)
at sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:102)
at sun.nio.fs.WindowsFileSystemProvider.newByteChannel(WindowsFileSystemProvider.java:230)
at java.nio.file.Files.newByteChannel(Files.java:361)
at java.nio.file.Files.newByteChannel(Files.java:407)
at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384)
at java.nio.file.Files.newInputStream(Files.java:152)
at hudson.cli.PrivateKeyProvider.readPemFile(PrivateKeyProvider.java:132)
.......... and so on

nisshah1499@gmail.com (JIRA)

unread,
May 27, 2019, 1:36:04 AM5/27/19
to jenkinsc...@googlegroups.com

nisshah1499@gmail.com (JIRA)

unread,
Jun 1, 2019, 7:21:02 AM6/1/19
to jenkinsc...@googlegroups.com

nisshah1499@gmail.com (JIRA)

unread,
Jun 3, 2019, 11:58:02 AM6/3/19
to jenkinsc...@googlegroups.com

I request Adam Vollmer to mark this issue as resolved, because PR has been merged.

Thanks 

nisshah1499@gmail.com (JIRA)

unread,
Jun 5, 2019, 1:10:03 AM6/5/19
to jenkinsc...@googlegroups.com
Nisarg Shah updated an issue
Change By: Nisarg Shah
Comment: I request [~avollmer] to mark this issue as resolved, because PR has been merged.

Thanks :)
Reply all
Reply to author
Forward
0 new messages