Re: Cucumber Test Result Plugin - It does not appear at my window the test results

2014-09-22 Thread teilo
There's a cent jiraComponent issue where jenkins gets confused if you have 
multiple test result types (both a Junit report and a cucumber report for 
example).

I would argue that cucumber is a different tool to Junit and should be testing 
stuff built elsewhere so you should not have this mix in a single job  (each 
jenkins job does a few smaller parts).

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Building a specific commit with Gerrit

2014-09-22 Thread Michael Vincent
I need to build every commit that gets submitted into a Gerrit repo 
(preferably in order).

I have all the latest git/Gerrit plugins on the latest Jenkins 1.565.2 LTS. 
Jenkins master is running on Linux and slave nodes are running on Windows 7 
with msysgit-1.8.3. The Gerrit server is running 2.9.1.

I've set up a job and set the Gerrit Trigger "Trigger on" field to "Ref 
Updated". The git plugin "Refspec" field is set to "$GERRIT_REFSPEC", the 
"Branches to build" field is set to "$GERRIT_NEWREV", and the "Choosing 
strategy" is set to "Gerrit Trigger".

This works fine until multiple instances of this job get queued up, at 
which point it continues to just build the tip revision of the branch. This 
is particularly apparent if an older job is retriggered. Here's an example.

The tip of "origin/master" is currently at 4d5f54f, but this job should be 
building 0af0a0f. Here are some of the Gerrit environment variables defined 
for the job:

GERRIT_EVENT_TYPE ref-updated
GERRIT_NEWREV 0af0a0fd5c533f258a18ea3bf72add14a3d43a3c
GERRIT_OLDREV 57672ba6daa5674a561911706551e66b70a5c01a
GERRIT_REFSPECrefs/heads/master

and the log output:

Fetching changes from the remote Git repository
 > C:\Program Files (x86)\Git\cmd\git.exe config remote.origin.url 
 > ssh://gerrit/repo 
# timeout=10
Fetching upstream changes from ssh://gerrit/repo
 > C:\Program Files (x86)\Git\cmd\git.exe --version # timeout=10
using GIT_SSH to set credentials id_dsa
 > C:\Program Files (x86)\Git\cmd\git.exe fetch --tags --progress 
 > ssh://gerrit/repo 
refs/heads/master
 
*> C:\Program Files (x86)\Git\cmd\git.exe rev-parse "FETCH_HEAD^{commit}" # 
timeout=10Checking out Revision 4d5f54fe49ad4adbe8b494a9da3408f4206193a2 
(0af0a0fd5c533f258a18ea3bf72add14a3d43a3c)*
 > C:\Program Files (x86)\Git\cmd\git.exe config core.sparsecheckout # 
timeout=10
 *> C:\Program Files (x86)\Git\cmd\git.exe checkout -f 
4d5f54fe49ad4adbe8b494a9da3408f4206193a2*
 > C:\Program Files (x86)\Git\cmd\git.exe rev-parse "FETCH_HEAD^{commit}" # 
timeout=10
 > C:\Program Files (x86)\Git\cmd\git.exe rev-list 
0af0a0fd5c533f258a18ea3bf72add14a3d43a3c # timeout=10
 > C:\Program Files (x86)\Git\cmd\git.exe remote # timeout=10
 > C:\Program Files (x86)\Git\cmd\git.exe submodule init # timeout=10
 > C:\Program Files (x86)\Git\cmd\git.exe submodule sync # timeout=10
 > C:\Program Files (x86)\Git\cmd\git.exe config --get remote.origin.url # 
timeout=10
 > C:\Program Files (x86)\Git\cmd\git.exe submodule update --init --
recursive

It looks like the Gerrit Trigger choosing strategy is checking out 
FETCH_HEAD even though I told it to check out "$GERRIT_NEWREV". I can work 
around this fairly easily by adding a "git checkout --force $GERRIT_NEWREV" 
command to the beginning of the build script, but it would be nice for the 
git/Gerrit plugins to handle this case. Is there something I should change 
in the job configuration or is this currently a plugin limitation?

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Convert existing Job to DSL

2014-09-22 Thread Brantone
Hey,
So I had created a bunch of jobs before stumbling upon the DSL plugin. 
Wondering if there's an efficient way to convert existing jobs to DSL?
I did find https://issues.jenkins-ci.org/browse/JENKINS-16360 from a year 
ago, marked as minor ... but considering the description of "pretty 
straightforward", wondering if anyone has even a quick 'n dirty way to do 
the conversion.
Cheers.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to set "Environment variables" in "Global properties" of global Jenkins configuration programmatically?

2014-09-22 Thread Walter Kacynski
I use the following script to inject a username and password:

usernamePassword = build.getEnvironment(null)[secret]
def (username, password) = usernamePassword.split(':')

e = new hudson.EnvVars()
e.put(secret + '_USERNAME', username)
e.put(secret + '_PASSWORD', password)
build.environments.add(hudson.model.Environment.create(e))


On Monday, September 22, 2014 3:23:51 AM UTC-4, mr wrote:
>
> Hi Folks!
>
> Do anybody have an idea how to set/change the variables within a Groovy 
> script?
>
> Regards!
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: No more plugin updates on LTS update site?

2014-09-22 Thread Daniel Beck
Plugins are developed independently from core and usually have no 'LTS line', 
except maybe to backport fixes to a version compatible with LTS when the main 
development line requires a more recent core.

Still, most plugins are compatible with 1.565.x. Make sure the date on the 
lower right of /pluginManager/advanced is recent. If not, press 'Check now' and 
wait until the page confirms it was updated ("Checking Updates... Done").

Make sure there's an update center configured on /pluginManager/advanced (URL 
field in Update Site section), it should likely point to 
http://updates.jenkins-ci.org/update-center.json

On 22.09.2014, at 14:59, Johannes Wienke  
wrote:

> Hi again,
> 
> we are using the LTS version of Jenkins (currently 1.565.1) with the LTS
> plugin update channel. Until a few weeks ago, despite using LTS, there
> were constant plugin updates available. This however has stopped since
> then. I am a bit confused about this. Is this intended or is there an
> error in our installation that prevents the updates from showing up?
> 
> Cheers,
> Johannes
> -- 
> Johannes Wienke, Researcher at CoR-Lab / CITEC, Bielefeld University
> Address: Inspiration 1, D-33619 Bielefeld, Germany (Room 1.307)
> Phone: +49 521 106-67277
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] Examine Jenkins thread state with Dumpling

2014-09-22 Thread Christoph Kutzinski

Looks like a nice tool!

Am 22.09.2014 um 18:28 schrieb oliver gondža:

Hi,

There is a plugin that bring Dumpling DSL into Jenkins:
https://wiki.jenkins-ci.org/display/JENKINS/Dumpling+Plugin

What's Dumpling?

Domain model and DSL to query thread state. Read more here:
https://olivergondza.github.io/dumpling/



--
You received this message because you are subscribed to the Google Groups "Jenkins 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[ANN] Examine Jenkins thread state with Dumpling

2014-09-22 Thread oliver gondža

Hi,

There is a plugin that bring Dumpling DSL into Jenkins:  
https://wiki.jenkins-ci.org/display/JENKINS/Dumpling+Plugin


What's Dumpling?

Domain model and DSL to query thread state. Read more here:  
https://olivergondza.github.io/dumpling/


--
oliver

--
You received this message because you are subscribed to the Google Groups "Jenkins 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Reverse proxy verification fails (AJAX)

2014-09-22 Thread Eric Darchis
Hi.

I am hosting a jenkins on https://www.mysite.com/jenkins/ with a NGinx 
reverse proxy. I recently updated http to httpS and upgraded Jenkins to the 
current latest, plugins as well.

When I try to access the "Manage Jenkins" page, all subsequent requests 
fails with error 401. This only happens after the AJAX call verifying the 
reverse proxy setup has failed. Apart from that one, everything works just 
fine. With an SSH forwarding and direct access (with login), it works too.

>From the specific help page 
,
 
I tried the suggested request:
curl -iL -u user:pass -e https://www.mysite.com/jenkins/manage 
https://www.mysite.com/jenkins/administrativeMonitor/hudson.diagnosis.ReverseProxySetupMonitor/test

Result:

> HTTP/1.1 302 Found
> Server: nginx/1.1.19
> Date: Mon, 22 Sep 2014 14:50:45 GMT
> Content-Length: 0
> Connection: keep-alive
> Cache-Control: private
> Expires: Thu, 01 Jan 1970 01:00:00 CET
> Location: 
> https://www.mysite.com/jenkins/administrativeMonitor/hudson.diagnosis.ReverseProxySetupMonitor/testForReverseProxySetup/https%3A%2F%2Fwww.mysite.com%2Fjenkins%2Fmanage/
> Front-End-Https: on
> Cache-Control: public, must-revalidate
> Strict-Transport-Security: max-age=2592000; includeSubdomains
>
 

> HTTP/1.1 404 Not Found
> Server: nginx/1.1.19
> Date: Mon, 22 Sep 2014 14:50:45 GMT
> Content-Type: text/html;charset=utf-8
> Content-Length: 1053
> Connection: keep-alive
> Cache-Control: private
> Expires: Thu, 01 Jan 1970 01:00:00 CET
> Content-Language: en


Given that the Location returns https://www.mysite.com/jenkins/... rather 
than localhost:8080, I would say that it's properly configured. Yet, it 
ends up with a 404.

Here is the NGinx extract:

> location /jenkins {
> proxy_pass  http://localhost:8080/jenkins;
> proxy_redirect http:// https://;
> sendfile off;
> proxy_set_headerHost $host;
> proxy_set_headerX-Real-IP $remote_addr;
> proxy_set_headerX-Forwarded-For 
> $proxy_add_x_forwarded_for;
> proxy_max_temp_file_size 0;
> proxy_set_headerX-Forwarded-Proto $scheme;
> proxy_connect_timeout   150;
> proxy_send_timeout  100;
> proxy_read_timeout  100;
> proxy_buffers   4 32k;
> client_max_body_size8m;
> client_body_buffer_size 128k;
>
 

> auth_basic "mysite login";
> auth_basic_user_file "/etc/nginx/mysite.passwd";
> }


(I normally have an LDAP server) 

Does anyone know what could be wrong ? Or how to disable the test ?

Thanks
Eric.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Build Failure Analyzer - Email Ext

2014-09-22 Thread Lukasz Wasylow
Hi 
I've been trying to use a Build Failure Analyzer to issue some emails using 
ext-Email.
I ve been trying to use a Jelly Templates but it looks like BFA scanning 
for issues after ext-Email is being sent.

I have tried to use a token macro ${BUILD_FAILURE_ANALYZER, 
includeTitle=true, includeIndications=true, useHtmlFormat=true} but either 
I'm not undestandt how to use it or its not working.

Is anyone had a luck with that email macro?

Regards
Lukasz

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


No more plugin updates on LTS update site?

2014-09-22 Thread Johannes Wienke
Hi again,

we are using the LTS version of Jenkins (currently 1.565.1) with the LTS
plugin update channel. Until a few weeks ago, despite using LTS, there
were constant plugin updates available. This however has stopped since
then. I am a bit confused about this. Is this intended or is there an
error in our installation that prevents the updates from showing up?

Cheers,
Johannes
-- 
Johannes Wienke, Researcher at CoR-Lab / CITEC, Bielefeld University
Address: Inspiration 1, D-33619 Bielefeld, Germany (Room 1.307)
Phone: +49 521 106-67277



signature.asc
Description: OpenPGP digital signature


Git merge checking out impossible commits

2014-09-22 Thread Johannes Wienke
Hi,

we are using special merge simulator projects for feature branches where
the idea is that the feature branch is automatically merged onto the
master before compiling and testing it so that also the merging behavior
is verified. All of these projects are multi configuration jobs. So far
this worked quite well but since a few days we are noticing a weird
behavior:

In one of the feature branches we did some force pushing and after that
we noticed two error conditions.

1. The coordinator performed the merge successfully, which created a new
revision with hash 5af79d528388216aa25a24c27f0a16d8dc55bdb6. All slaves
of the multi configuration project then try to checkout that revision,
which obviously does not exist in their local repositories. Hence, they
end up with

FATAL: Could not checkout master with start point
5af79d528388216aa25a24c27f0a16d8dc55bdb6
hudson.plugins.git.GitException: Could not checkout master with start
point 5af79d528388216aa25a24c27f0a16d8dc55bdb6
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl$8.execute(CliGitAPIImpl.java:1448)
at
org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:153)
at
org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:146)
at hudson.remoting.UserRequest.perform(UserRequest.java:118)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:328)
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:1146)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:701)
Caused by: hudson.plugins.git.GitException: Command "git checkout -f
5af79d528388216aa25a24c27f0a16d8dc55bdb6" returned status code 128:
stdout:
stderr: fatal: reference is not a tree:
5af79d528388216aa25a24c27f0a16d8dc55bdb6

at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1276)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1253)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1249)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1065)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1075)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl$8.execute(CliGitAPIImpl.java:1431)
... 11 more

2. After wiping the workspace of that job we ended up in a second error
condition already on the coordinator side:

Merging Revision 5af79d528388216aa25a24c27f0a16d8dc55bdb6 () onto
origin/master using default strategy
FATAL: Could not checkout master with start point
5af79d528388216aa25a24c27f0a16d8dc55bdb6
hudson.plugins.git.GitException: Could not checkout master with start
point 5af79d528388216aa25a24c27f0a16d8dc55bdb6
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl$8.execute(CliGitAPIImpl.java:1448)
at
org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:153)
at
org.jenkinsci.plugins.gitclient.RemoteGitImpl$CommandInvocationHandler$1.call(RemoteGitImpl.java:146)
at hudson.remoting.UserRequest.perform(UserRequest.java:118)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:328)
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:1146)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:701)
Caused by: hudson.plugins.git.GitException: Command "git checkout -f
5af79d528388216aa25a24c27f0a16d8dc55bdb6" returned status code 128:
stdout:
stderr: fatal: reference is not a tree:
5af79d528388216aa25a24c27f0a16d8dc55bdb6

at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1276)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1253)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1249)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1065)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1075)
at
org.jenkinsci.plugins.gitclient.CliGitAPIImpl$8.execute(

Re: Connect Jenkins Server to Build server

2014-09-22 Thread Les Mikesell
On Sun, Sep 21, 2014 at 10:51 PM, aniket jindal  wrote:
> Hi Felix
>
> I have a server running the Jenkins instance (the jenkins master), and a
> Linux server having my software builds images (ISO). I want to execute my
> TCL scripts using jenkins on this  ISO build images.
>

That sounds like a normal jenkins slave configuration.  Are you having
some problem setting it up?Normally you would start the jobs in
jenkins or have it configured to run a job when you change something
in your version control system but the job will run on the slave.

-- 
  Les Mikesell
 lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins and Perforce password issue

2014-09-22 Thread David Rabinowitz
No, P$CHARSET is not set, but the password contains only US-ASCII 
characters. Also, I have verified there is no typo.

On Monday, September 22, 2014 12:16:47 PM UTC+3, Jan Seidel wrote:
>
> Is P4CHARSET set to winansi?
> Maybe you should write the P4PAASWD into a text file and inject it with 
> env_inject.
> This would make the testing a bit easier.
>
> You can then find whitespace characters and have no encoding trouble with 
> the password.
> If this works is your problem probably a matter of encoding, typo or the 
> like.
>
> P4CHARSET=winansi has to be set explicitly as far as I recall or it will 
> got Unicode.
> Well, if your P4 Servers runs with the code page. But it is likely.
>
>
> Am Sonntag, 21. September 2014 20:35:29 UTC+2 schrieb David Rabinowitz:
>
> I'm using Jenkins with Perforce to build a maven project, and I need to 
> use the maven-release plugin. I have configured my project and the build is 
> going well, until I have tried to use the maven release plugin using the 
> relevant Jenkins plugin. With dry run everything went well, but when trying 
> to make the release I got this nasty error message (below). For some reason 
> the Jenkins cannot connect to the P4 server. Also, the "Expose P4PASSWD in 
> environment" is checked.
>
> Answering some questions I got
>
>- When you say dry run, do you perform it using Jenkins only or from 
>command line? *Both*
>- Where exactly are you setting the password for P4? In the 'Global 
>credentials' section? *In the project configuration, under Source Code 
>Management->Perforce->Password*
>- Where are you getting the option of 'Expose P4PASSWD in 
>environment'? *Same place*
>- In the log above, is this line setting up the password for P4 
> "d:\program 
>files\perforce\p4.exe" set? *This line exposes the P4 parameters - all 
>of them (including P4PASSWD) are set correctly. I have removed the actual 
>values from obvious reasons...*
>
> This is the error message:
>
> Started by user David [EnvInject] - Loading node environment 
> variables.Building on master in workspace 
> X:\hudson\jobs\myproject\workspaceUsing master perforce client: 
> myproject[workspace] $ "D:\Program Files\Perforce\p4.exe" workspace -o 
> myproject[workspace] $ "D:\Program Files\Perforce\p4.exe" login -a 
> -p[workspace] $ "D:\Program Files\Perforce\p4.exe" -P *** workspace -o 
> myprojectLast build changeset: 1062732[workspace] $ "D:\Program 
> Files\Perforce\p4.exe" -P *** changes -s submitted -m 1 
> //myproject/...Sync'ing workspace to changelist 1062732 (forcing sync of 
> unchanged files).[workspace] $ "D:\Program Files\Perforce\p4.exe" -P *** -s 
> sync -f //myproject/...@1062732Sync complete, took 108 ms[workspace] $ cmd /c 
> call D:\apache-tomcat-6\temp\hudson368187580614800030.bat
>
> X:\hudson\jobs\myproject\workspace>"d:\program files\perforce\p4.exe" set 
> P4CLIENT=myproject
> P4PASSWD=***
> P4PORT=***
> P4USER=***
>
> X:\hudson\jobs\myproject\workspace>exit 0 Parsing POMsDownloaded artifact 
> ...[workspace] $ D:/ins/Java/jdk1.7.0_10.x64/bin/java -DcreateChecksum=true 
> -cp 
> X:\hudson\plugins\maven-plugin\WEB-INF\lib\maven31-agent-1.4.jar;X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1\boot\plexus-classworlds-2.5.1.jar;X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1/conf/logging
>  jenkins.maven3.agent.Maven31Main 
> X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1 
> D:\apache-tomcat-6\webapps\hudson\WEB-INF\lib\remoting-2.37.jar 
> X:\hudson\plugins\maven-plugin\WEB-INF\lib\maven31-interceptor-1.4.jar 
> X:\hudson\plugins\maven-plugin\WEB-INF\lib\maven3-interceptor-commons-1.4.jar 
> 51470<===[JENKINS REMOTING CAPACITY]===>channel startedExecuting Maven:  -B 
> -f X:\hudson\jobs\myproject\workspace\pom.xml 
> -DdevelopmentVersion=0.0.2-SNAPSHOT -DreleaseVersion=0.0.1 -Dresume=false 
> release:prepare release:perform -XApache Maven 3.1.1 
> (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 18:22:22+0300)Maven 
> home: X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1Java 
> version: 1.7.0_10, vendor: Oracle CorporationJava home: 
> D:\ins\Java\jdk1.7.0_10.x64\jreDefault locale: en_US, platform encoding: 
> Cp1252
> OS name: "windows server 2008", version: "6.0", arch: "amd64", family: 
> "windows"[INFO] Error stacktraces are turned on.[DEBUG] Reading global 
> settings from 
> X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1\conf\settings.xml[DEBUG]
>  Reading user settings from C:\...\.m2\settings.xml[INFO] Scanning for 
> projects...[INFO] Downloading: ...[INFO] Downloaded: ...[INFO] 
> [INFO]
>  Reactor Build Order:[INFO] [INFO] proj-parent[INFO] proja[INFO] projb[INFO] 
> projc[INFO] test-reactor[INFO]
>  [INFO] 
> 

Re: Jenkins and Perforce password issue

2014-09-22 Thread David Rabinowitz
Hi Dan,

Thanks, I will check if I can take this plugin

David

On Monday, September 22, 2014 7:40:40 AM UTC+3, Dan Tran wrote:
>
>
> The combination of new P4Jenkins[1] and P4Maven[2]  works well with 
> maven-release-plugin. you will need cut an internal release of p4maven
>
> -D
>
>
>
> [1] https://wiki.jenkins-ci.org/display/JENKINS/P4+Plugin
>
> [2] https://swarm.workshop.perforce.com/files/guest/dantran/p4maven . 
> p4maven has not officially release yet , do have snapshot deploy at sonatype
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Jan Seidel
Thanks for the explanation :)
The site you have mentioned is indeed a real nice one. It is already added 
to my bookmarks.

Cheers
Jan

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Richard Lavoie
What ( ) does is that whenever it matches the inner pattern, it keeps it in 
memory for further reference in code.

(?: ) allows to have a complex inner pattern with OR cases without keeping the 
matched content in memory.

That's what mean "non-capturing" for (?:).

Also www.regular-expressions.info has a really nice reference on regex and also 
tells you which engine supports which feature.

Richard Lavoie

> On 2014-09-22, at 05:03, Jan Seidel  wrote:
> 
> Last but not least.
> Looks like Jenkins adheres to Java Regex, even if I sometimes doubted it.
> 
> "(?:X)X, as a non-capturing group"
> Does this mean ... "don't jump on this pattern"?
> Sorry, I'm no developer :)
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins and Perforce password issue

2014-09-22 Thread Jan Seidel
Is P4CHARSET set to winansi?
Maybe you should write the P4PAASWD into a text file and inject it with 
env_inject.
This would make the testing a bit easier.

You can then find whitespace characters and have no encoding trouble with 
the password.
If this works is your problem probably a matter of encoding, typo or the 
like.

P4CHARSET=winansi has to be set explicitly as far as I recall or it will 
got Unicode.
Well, if your P4 Servers runs with the code page. But it is likely.


Am Sonntag, 21. September 2014 20:35:29 UTC+2 schrieb David Rabinowitz:
>
> I'm using Jenkins with Perforce to build a maven project, and I need to 
> use the maven-release plugin. I have configured my project and the build is 
> going well, until I have tried to use the maven release plugin using the 
> relevant Jenkins plugin. With dry run everything went well, but when trying 
> to make the release I got this nasty error message (below). For some reason 
> the Jenkins cannot connect to the P4 server. Also, the "Expose P4PASSWD in 
> environment" is checked.
>
> Answering some questions I got
>
>- When you say dry run, do you perform it using Jenkins only or from 
>command line? *Both*
>- Where exactly are you setting the password for P4? In the 'Global 
>credentials' section? *In the project configuration, under Source Code 
>Management->Perforce->Password*
>- Where are you getting the option of 'Expose P4PASSWD in 
>environment'? *Same place*
>- In the log above, is this line setting up the password for P4 
> "d:\program 
>files\perforce\p4.exe" set? *This line exposes the P4 parameters - all 
>of them (including P4PASSWD) are set correctly. I have removed the actual 
>values from obvious reasons...*
>
> This is the error message:
>
> Started by user David [EnvInject] - Loading node environment 
> variables.Building on master in workspace 
> X:\hudson\jobs\myproject\workspaceUsing master perforce client: 
> myproject[workspace] $ "D:\Program Files\Perforce\p4.exe" workspace -o 
> myproject[workspace] $ "D:\Program Files\Perforce\p4.exe" login -a 
> -p[workspace] $ "D:\Program Files\Perforce\p4.exe" -P *** workspace -o 
> myprojectLast build changeset: 1062732[workspace] $ "D:\Program 
> Files\Perforce\p4.exe" -P *** changes -s submitted -m 1 
> //myproject/...Sync'ing workspace to changelist 1062732 (forcing sync of 
> unchanged files).[workspace] $ "D:\Program Files\Perforce\p4.exe" -P *** -s 
> sync -f //myproject/...@1062732Sync complete, took 108 ms[workspace] $ cmd /c 
> call D:\apache-tomcat-6\temp\hudson368187580614800030.bat
>
> X:\hudson\jobs\myproject\workspace>"d:\program files\perforce\p4.exe" set 
> P4CLIENT=myproject
> P4PASSWD=***
> P4PORT=***
> P4USER=***
>
> X:\hudson\jobs\myproject\workspace>exit 0 Parsing POMsDownloaded artifact 
> ...[workspace] $ D:/ins/Java/jdk1.7.0_10.x64/bin/java -DcreateChecksum=true 
> -cp 
> X:\hudson\plugins\maven-plugin\WEB-INF\lib\maven31-agent-1.4.jar;X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1\boot\plexus-classworlds-2.5.1.jar;X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1/conf/logging
>  jenkins.maven3.agent.Maven31Main 
> X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1 
> D:\apache-tomcat-6\webapps\hudson\WEB-INF\lib\remoting-2.37.jar 
> X:\hudson\plugins\maven-plugin\WEB-INF\lib\maven31-interceptor-1.4.jar 
> X:\hudson\plugins\maven-plugin\WEB-INF\lib\maven3-interceptor-commons-1.4.jar 
> 51470<===[JENKINS REMOTING CAPACITY]===>channel startedExecuting Maven:  -B 
> -f X:\hudson\jobs\myproject\workspace\pom.xml 
> -DdevelopmentVersion=0.0.2-SNAPSHOT -DreleaseVersion=0.0.1 -Dresume=false 
> release:prepare release:perform -XApache Maven 3.1.1 
> (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 18:22:22+0300)Maven 
> home: X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1Java 
> version: 1.7.0_10, vendor: Oracle CorporationJava home: 
> D:\ins\Java\jdk1.7.0_10.x64\jreDefault locale: en_US, platform encoding: 
> Cp1252
> OS name: "windows server 2008", version: "6.0", arch: "amd64", family: 
> "windows"[INFO] Error stacktraces are turned on.[DEBUG] Reading global 
> settings from 
> X:\hudson\tools\hudson.tasks.Maven_MavenInstallation\Maven_3.1.1\conf\settings.xml[DEBUG]
>  Reading user settings from C:\...\.m2\settings.xml[INFO] Scanning for 
> projects...[INFO] Downloading: ...[INFO] Downloaded: ...[INFO] 
> [INFO]
>  Reactor Build Order:[INFO] [INFO] proj-parent[INFO] proja[INFO] projb[INFO] 
> projc[INFO] test-reactor[INFO]
>  [INFO] 
> [INFO]
>  Building test-reactor 0.0.1-SNAPSHOT[INFO] 
> [INFO]
>  [INFO] --- maven-release-plugin:2.5:prepare (default-cli) @ test-reactor 
>

Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Jan Seidel
Last but not least.
Looks like Jenkins adheres to Java Regex, even if I sometimes doubted it.

"(?:*X*) *X*, as a non-capturing group"Does this mean ... "don't jump on 
this pattern"?
Sorry, I'm no developer :)

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Jan Seidel
It works like a charm :)

Thank you two for helping me out on this one.

Jan

Am Freitag, 19. September 2014 09:38:17 UTC+2 schrieb Jan Seidel:
>
> Hi all,
>
> I have a weird issue with a regular expression.
> Hopefully you can help me out here.
>
> I have a RegEx like *(.*)GUIDE_(?!MIB)(.*)(?!P4)*
> It should, as far as I can tell, list all jobs containing GUIDE but 
> exclude GUIDE jobs with a MIB in the middle or P4 at the end of the project 
> name, right?
>
> My problem here is, that jobs with a P4 at the end still are listed :(
>
> I have for testing purposes tried all kind of RegEx that crossed my mind 
> but without any success.
> Later I tried just to exclude job names with a P4 at the end. No joy
>
> The RegEx I used was: *(.*)GUIDE_(.*)(?!P4)*
> The list is then completely emtpy.
>
> Can someone tell me where I glitch?
>
> Cheers
> Jan
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Jan Seidel
Nice advice! :)

what does *?:* actually imply?
Where do I find this information?

If you want to allow that MIB can appear anywhere else other that 
immmediately after GUIDE_ you can change the regex for :
(.*)GUIDE_(?!MIB)((?!P4).)*$

This pattern confuses me a bit... Ohh now I get it. Dumb little me 
XD
That explains another issue I have. *geesh* I start to become dizzy of RegEx

Thanks for helping out.
I will do some tests right away

Cheers
Jan

Am Freitag, 19. September 2014 12:53:12 UTC+2 schrieb DarkRift:
>
> As a few people already mentioned you need to anchor your pattern. 
> Otherwise, .* might match what you want to exclude and attempt the match 
> after it, resulting in an unwanted result.
>
> What your regx is doing in words is this:
>
> (.*) match anywhere
> GUIDE_ : normal text match
> (?!MIB) : immediately not followed by MIB
> (.*) : match anywhere
> (?!P4) : not followed by P4
>
> Now, what you want to do if MIB and P4 can be anywhere after GUIDE_ is to 
> match every character and the make sure it is not followed by any of those, 
> up to the end. The regex for that would be:
>
> (.*)GUIDE_(?:(?!MIB)(?!P4).)*$
>
> The fancy part at the end translates into :
>
> Make sure the following text is neither MIB or P4 when you try to match 
> the next char, up to the end of string. it does not make a distinction 
> weither MIB comes before or after P4. It will make sure any of those is not 
> after GUIDE_
>
> Richard Lavoie
>
>
 

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Jan Seidel
GUIDE_(?!MIB)(FOO|BAR|BAZ)(?!P4)$ is a nice idea.
I have been working with it quite at the beginning of my test cases but I 
neglected ^ and $.
This may be the hint I needed to anchor the parttern. :)

Cheers

Am Freitag, 19. September 2014 12:20:49 UTC+2 schrieb Gunnar Strand:
>
>  
> On 09/19/14 11:44, Jan Seidel wrote:
>  
> Yay, got it.
> A set of projects rules. each one containing a positve match and then 
> combine the rule works well.
>
> One odd thing I learned is, that you don't need wildcards if your match 
> has a trailing string.
>
> e.g. *MB**_GUIDE**_Pxxx_P4**_DELIVERY* will also be found when you 
> work with *(.*)GUIDE_(.*)P4*
>
> You can by the way combine RegEx like this* 
> (.*)GUIDE_MIB(.*)|(.*)GUIDE_(.*)P4 *the pipe "|" works well one positive 
> matches. negative matches don't make fun with it
>  
>
> The "^" and the "$" commands matches the beginning of the string and the 
> end of the string, respectively. Some parsers, or rather some designers, 
> adds these commands to the pattern, ie "GUIDE_.*P4" would actually be 
> "^GUIDE_.*P4$" and would not match "MB_GUIDE_P4" nor "GUIDE_P4_DELIVERY".
>
> However, that does *not* appear to the case above, which is why your 
> pattern matches the "P4_DELIVERY" name above. You need to add "^" and "$" 
> yourself if you want to include "starts with" and "ends with" parts for the 
> pattern.
>
> If you know which text the '.*' will match, then you could do this:
>
> GUIDE_(?!MIB)(FOO|BAR|BAZ)(?!P4)$
>
> This should match any name containing GUIDE_, where GUIDE_ is not followed 
> by MIB, and then followed by one of a specific list of possible strings, 
> which are not followed by "P4". Remove the "$" at the end if the name may 
> contain other text after the FOO/BAR/BAZ part.
>
> BR
> Gunnar
>
>
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with RegEx for project roles in Matrix Authorization Strategy Plugin

2014-09-22 Thread Jan Seidel
X(?!Y) works when it is used in a RegEx but the plugins botches as soon as 
you start to combine several negations.

X(?!Y)|A(!?B) won't behave as expected.
Applying the de Morgan's law (double negation to create and AND from an OR) 
does not interest the plugin at all.
I tried (!?(X(?!Y)|A(!?B)), (!?((X(?!Y)|A(!?B))) and all other combinations 
that made sense to me.

Latest crime I committed was: 
(!?((!?((.*)GUIDE_MIB.*))|(!?((.*)GUIDE_Pxx(.*)))|(!?((.*)GUIDE_(.*)P4
Looks like that Jenkins does not care about negations when combining 
patterns :/

Am Freitag, 19. September 2014 12:04:24 UTC+2 schrieb Gunnar Strand:
>
>  
> On 09/19/14 11:27, Jan Seidel wrote:
>  
> True (.*) is very greedy, but (?!P4) is a but not P4 and I would expect it 
> to work.
> It isn't as I just figured out in a test run with a completely different 
> RegEx to skim for other jobs :/
>  
>
> I don't know what kind of regex the Matrix supports, but "X(?!Y)" normally 
> means "X" not followed by "Y". If you precede it with a match anything 
> repeating pattern: "X.*(?!Y), the parser will happily match "XY" where "Y" 
> is matched using the ".*" pattern, and determine that the matching string 
> XY is not followed by "Y", hence it returns true. Using a negative 
> look-ahead pattern is tricky, you must anchor the pattern to something.
>
> BR
> Gunnar
>
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to set "Environment variables" in "Global properties" of global Jenkins configuration programmatically?

2014-09-22 Thread mr
Hi Folks!

Do anybody have an idea how to set/change the variables within a Groovy 
script?

Regards!

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.