答复: how to implement an invisible job property plugin

2013-02-04 Thread Shen,Hui
I want to use a JobPropertyDescriptor, where add a creator property, it’s saved 
when job is created, and cannot be changed later, so we went this property is 
visible to user.


public final class JobCreatorProperty extends JobProperty> 
{
 private String creator;

 public String getCreator(){
   return creator;
 }

 public void setCreator(String creator){
   this.creator = creator;
 }

 @Extension
 public static final class DescriptorImpl extends JobPropertyDescriptor{
   public DescriptorImpl(){
super(JobCreatorProperty.class);
…
}


发件人: Walter Kacynski [mailto:walter.kacyn...@gmail.com]
发送时间: 2013年2月5日 1:10
收件人: jenkinsci-users@googlegroups.com
抄送: Shen,Hui
主题: Re: how to implement an invisible job property plugin

 I'm interested in doing something similar.  Which jelly file are you referring 
to?

-- 
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/groups/opt_out.




how to implement an invisible job property plugin

2013-02-03 Thread Shen,Hui
Hi,
I need to write a plugin to add some job property, but I don't want this 
property can been seen by users, in other words they are invisible in job's 
configure screen.
How should I do that, I have tried use style="display:none" for the element in 
jelly file, but there is still a blank line left on the screen.
Can anybody help me ?
Thanks very much.

Hui

-- 
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/groups/opt_out.




How can i get build number when using remote API

2012-11-28 Thread Shen,Hui
Hi guys,

I try to programmatically schedule a new build by posting a message to
http://HOSTNAME:PORT/jenkins/job/JOBNAME/build

This is worked, a new build was fired, but how can I get the build number it 
just fired.

I had try using http://HOSTNAME:PORT/jenkins/job/JOBNAME/lastBuild/, but it's 
not exactly the build number it fired.
Since there are cases two builds are fired in short time period.


Can anybody help with this. Thanks very much.


Shen Hui
BB - F2 - AW264|x28530



Re: Promoted Build Plugin: trigger a promotion remotely

2012-10-29 Thread Shen Hui
I meet the this requirement, we want to trigger a promotion remotely by cli
command or rest API.
Does anybody can provide some hints.
Thanks.



--
View this message in context: 
http://jenkins.361315.n4.nabble.com/Promoted-Build-Plugin-trigger-a-promotion-remotely-tp4641335p4644633.html
Sent from the Jenkins users mailing list archive at Nabble.com.


subversion SVNAuthenticationException

2012-10-22 Thread Shen,Hui

Hi guys,

We meet a problem when using Hudson-2.1.1.  (this is in fact a problem from 
Hudson, but I think I still can get some help from Jenkins community, :))

The problem is that svn update seems was succeed, but the revision check 
failed, it report 403 Forbiden error; in fact we do have correct svn user 
information.
Can anybody help on us ?
Thanks.


This is the output from Hudson log.


Started by an SCM change

Building remotely on slave-win-browser-c1085

Cleaning up c:\clientci\workspace\...

Updating https://svn...

A win8browser\doc

U bdbrowser\browser\Framework\Application\BrowserContent.cpp

U bdbrowser\common\base\util.cpp

At revision 37804

hudson.util.IOException2: revision check failed on https://svn

  at 
hudson.scm.SubversionChangeLogBuilder.buildModule(SubversionChangeLogBuilder.java:158)

  at 
hudson.scm.SubversionChangeLogBuilder.run(SubversionChangeLogBuilder.java:100)

  at hudson.scm.SubversionSCM.calcChangeLog(SubversionSCM.java:535)

  at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:652)

  at hudson.model.AbstractProject.checkout(AbstractProject.java:1218)

  at 
hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:507)

  at 
hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:424)

  at hudson.model.Run.run(Run.java:1367)

  at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)

  at hudson.model.ResourceController.execute(ResourceController.java:88)

  at hudson.model.Executor.run(Executor.java:145)

Caused by: org.tmatesoft.svn.core.SVNAuthenticationException: svn: OPTIONS of 
'/app/...': 403 Forbidden (https://svn)

  at 
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:62)

  at 
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:51)

  at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:624)

  at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:275)

  at 
org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:263)

  at 
org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516)

  at 
org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98)

  at 
org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001)

  at 
org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getLatestRevision(DAVRepository.java:178)

  at 
org.tmatesoft.svn.core.wc.SVNBasicClient.getRevisionNumber(SVNBasicClient.java:482)

  at 
org.tmatesoft.svn.core.wc.SVNBasicClient.getLocations(SVNBasicClient.java:873)

  at 
org.tmatesoft.svn.core.wc.SVNBasicClient.createRepository(SVNBasicClient.java:534)

  at 
org.tmatesoft.svn.core.wc.SVNLogClient.doLog(SVNLogClient.java:1019)

  at org.tmatesoft.svn.core.wc.SVNLogClient.doLog(SVNLogClient.java:894)

  at org.tmatesoft.svn.core.wc.SVNLogClient.doLog(SVNLogClient.java:826)

  at 
hudson.scm.SubversionChangeLogBuilder.buildModule(SubversionChangeLogBuilder.java:146)

  ... 10 more



Shen Hui
BB - F2 - AW264|x28530



Re: 答复: How can jenkins master share slave nodes.

2012-10-16 Thread Shen Hui
Because we have too many jobs (more than 1 thousand) coming from different
divisions; we wish each division use a separated master, and all masters can
share a slave pool.



--
View this message in context: 
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699p4643446.html
Sent from the Jenkins users mailing list archive at Nabble.com.


答复: How can jenkins master share slave nodes.

2012-10-12 Thread Shen Hui
Yes, I do want to share the logical slave, because if there is a master that 
delivered a job to slave1 (physical machine), and I want another master to 
deliver its job to slave2(physical); in this case, we can balance the jobs 
between different physical machine.


Shen Hui
BB - F2 - AW264|x28530

发件人: vf-2 [via Jenkins] [mailto:ml-node+s361315n4643048...@n4.nabble.com]
发送时间: 2012年10月12日 13:15
收件人: Shen,Hui
主题: Re: How can jenkins master share slave nodes.

Not sure if i understand you correctly. A slave is only a logical unit, it has 
not to be a physical machine. You can have multiple slaves running on one host, 
without interfering each other. So, every master can have as many slave as you 
want on any hosts, as long as each slave (not host) has its own root-fs. Then 
it does not matter hou many hosts you have, you can have 5 *independent* 
jenkins master-slave cluster across your build farm, each one does not care 
(does not know) the existence of other clusters. You can share all the hardware 
resources of you 20 hosts, the slave configuration is totally orthognal.

So you can share the hardware resources across 5 independent clasters, each has 
(theoretically) as many slaves as necessary. but if you want to share the 
(logical unit) *slave*, i dont think it is possible, even it is, i can not find 
any reason to do so.


Shen Hui <[hidden email]> 
schrieb:

Hi buddy,
I have 5 masters, and suppose I have a slave pool with 20 nodes.
Can these 5 master share these 20 slaves; because if i separate 20 slave
into 5 group(each has 4), each attached to a master, that's meaning a single
master can schedule only with 4 slaves; so there is this case, some groups
are busing, and other may be idle. i'd like these 20 slaves can share jobs
schedule among these 5 masters.
Can anybody help me on this? Appreciate very much.





--
View this message in context: 
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699.html
Sent from the Jenkins users mailing list archive at 
Nabble.com<http://Nabble.com>.

--
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.

If you reply to this email, your message will be added to the discussion below:
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699p4643048.html
To unsubscribe from How can jenkins master share slave nodes., click 
here<http://jenkins.361315.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=4642699&code=c2hlbmh1aTAyQGJhaWR1LmNvbXw0NjQyNjk5fC0yMTI1MDQwODgy>.
NAML<http://jenkins.361315.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>




--
View this message in context: 
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699p4643063.html
Sent from the Jenkins users mailing list archive at Nabble.com.

Re: How can jenkins master share slave nodes.

2012-10-10 Thread Shen Hui
OK, thank you Mark



--
View this message in context: 
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699p4642835.html
Sent from the Jenkins users mailing list archive at Nabble.com.


Re: How can jenkins master share slave nodes.

2012-10-10 Thread Shen Hui
Yes, Mark, I agree your solution is workable.
But as you said each slave is working in itself sandbox, there is no shared
knowledge between the 
masters about each others utilization; that means masters can send jobs into
same slave at the same time.
I wish if one master find a slave is running(its job is delivered by other
master), it will try to deliver job into another slave; that mean masters
share a slave group.



--
View this message in context: 
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699p4642821.html
Sent from the Jenkins users mailing list archive at Nabble.com.


How can jenkins master share slave nodes.

2012-10-10 Thread Shen Hui
Hi buddy,
I have 5 masters, and suppose I have a slave pool with 20 nodes.
Can these 5 master share these 20 slaves; because if i separate 20 slave
into 5 group(each has 4), each attached to a master, that's meaning a single
master can schedule only with 4 slaves; so there is this case, some groups
are busing, and other may be idle. i'd like these 20 slaves can share jobs
schedule among these 5 masters.
Can anybody help me on this? Appreciate very much.





--
View this message in context: 
http://jenkins.361315.n4.nabble.com/How-can-jenkins-master-share-slave-nodes-tp4642699.html
Sent from the Jenkins users mailing list archive at Nabble.com.


答复: Can a slave can be shared between masters

2012-09-20 Thread Shen,Hui
Thank Mark,

So each slave instance(on slave machine) is running in a separated sandbox, 
although they are running on same machine, they are not communicate with each 
other.

And multiply masters (when they share a same slave) will deliver job to the 
slave at the same time, since these masters do not know whether there is  
job(delivered from other master) is running.



Shen Hui (慎辉)
BB - F2 - AW264|x28530

发件人: jenkinsci-users@googlegroups.com [mailto:jenkinsci-users@googlegroups.com] 
代表 Mark Waite
发送时间: 2012年9月20日 20:06
收件人: jenkinsci-users@googlegroups.com
主题: Re: Can a slave can be shared between masters

I use this technique frequently with good results.  One machine has been able 
to host slaves from different masters for me so long as I assign a different 
directory to each slave.  In my case, I include the name of the master in the 
slave directory path so that I will now which master is using that directory 
based on the path to the slave directory.

/var/lib/jenkins/markwaite2-slave/ is the path (on the slave) for a slave that 
is serving the markwaite2 Jenkins master.

Mark Waite


From: "Shen,Hui" mailto:shenhu...@baidu.com>>
To: "jenkinsci-users@googlegroups.com<mailto:jenkinsci-users@googlegroups.com>" 
mailto:jenkinsci-users@googlegroups.com>>
Sent: Wednesday, September 19, 2012 10:44 PM
Subject: Can a slave can be shared between masters

Hi guys,

I have a cluster environment with several Jenkins master, and also many 
slavers; does anybody know can slavers be shared within different masters. For 
example master1 and masters they have same slave machine slave1; so what will 
happen if both master1 and master2 deliver a task to slave2 ?
Thanks very much.


Shen Hui
BB - F2 - AW264|x28530




Can a slave can be shared between masters

2012-09-19 Thread Shen,Hui
Hi guys,

I have a cluster environment with several Jenkins master, and also many 
slavers; does anybody know can slavers be shared within different masters. For 
example master1 and masters they have same slave machine slave1; so what will 
happen if both master1 and master2 deliver a task to slave2 ?
Thanks very much.


Shen Hui
BB - F2 - AW264|x28530