Do not do jenkins work if svn poll failed

I have a jenkins job, i.e. polling svn every 5 minutes and doing my unittests if some changes happen.

My problem is that svn polling is not performed randomly due to an unreachable proxy.

org.tmatesoft.svn.core.SVNAuthenticationException: svn: E170001: HTTP proxy authorization failed

I assume this problem is due to some problems with the proxy used, and not with the configuration of my work or machine.

Now my question is: can I skip the task if the svn poll is not working and is only executed if it was successful? So I do not have unsuccessful builds in my job list due to a problem with the proxy server.

Or do you have an idea why this random error can happen?

Fyi, I don’t want the proxy server problem itself to be fixed, as this is probably due to network problems, but I just want to skip the task if the svn request failed.

+4
source share
2 answers

Instead of polling svn, you can try the hook after commit so that svn notifies Jenkins of the changes; see https://wiki.jenkins-ci.org/display/JENKINS/Subversion+Plugin?focusedCommentId=43352266

+1
source

, , set + e script. -e - , - 1 ( ). . @mikep - . .

0

Source: https://habr.com/ru/post/1679788/


All Articles