Hudson integration with UCM ClearCase

偶尔善良 提交于 2019-12-09 22:14:03

问题


I have a linux build machine with JBoss, UCM ClearCase and ant installed. I would like to find out how to configure a continuous integration using Hudson and Hudson clearcase plugin. Can I use an existing dynamic view that is already created. Please give me some basic steps. Thank you in advance.


回答1:


Yes you can use an existing dynamic view.

The principle is:

  • create the dynamic view on your hudson (master) server
  • indicate in the Hudson Job configuration you want to use an existing dynamic view (you will have to put its root path: /view/yourView)
  • let hudson monitor the files that have evolved since the last run (it will do that by querying the history of files in that dynamic view)

Off course, you will need the ClearCase plugin to be installed first.

Here is an illustration (complete with the mandatory Freehand Circles) of what the configuration of such a Job looks like:

alt text http://img405.imageshack.us/img405/3261/jobhudsoncc2.png

(Note: M:\myView instead of /view/MyView: that is because I am making this example on my Windows7 laptop)

The documentation of the "Use existing dynamic view" mentions:

If set, Hudson will use an existing dynamic view instead of creating a snapshot view. Hudson will behave differently when working with a dynamic view. It will not create or remove the view so the "Use update" configuration is ignored if this option is enabled. The plugin will update the config spec of the view when needed.

To use this option, the dynamic view has to be created outside Hudson using the common ClearCase tools. A check out will fail if the dynamic view does not exist. The tag of the view should be the same as specified in the "View name" field.

I recommend checking the option Do Not Reset Config Spec to preserve the existing config spec of your view.


workspace] $ cleartool setcs -tag vijaym_SNDBX_INT_View -stream
cleartool: Error: Unable to change configuration specification: Permission denied.
FATAL: UCM ClearCase failed. exit code=1

That means the protection on this view are somehow false:
Could you go on the server in /view/vijaym_SNDBX_INT_View et type

cleartool lsview -l -full -pro -cview?

Possible cause of error:

  • umask != 2 (type 'umask' to check the value, if different from 2, type 'umask 2')
  • owner not vijaym
  • group of the process running Hudson not one of the vob groups (check/set the primary group of the user running that process: 'id -a'

Solution: reset the protection on that view (make sure our path references /usr/atria/etc/utils, where fix_prot is)

cd /  # leave the view
cleartool endview -server vijaym_SNDBX_INT_View # stop completely the view
cleartool umount -all # make sure all vobs are unmounted
# reset protections
fix_prot -force -rec -chown vijaym -chgrp aCorrectGroup -chmod 775 /path/to/vijaym_SNDBX_INT_View.vws
fix_prot -force -root -chown vijaym -chgrp aCorrectGroup /path/to/vijaym_SNDBX_INT_View.vws
#restart the view and mount the vobs
cleartool startview vijaym_SNDBX_INT_View
cleartool mount -all
# check if the protections are ok
cd /view/vijaym_SNDBX_INT_View
cleartool lsview -l -full -pro -cview



回答2:


I had the same problem. but in my case the view which is pointing to the server is physically not there. In your case seems Hudson user doesn't have permission on unix box. Try run jboss and hudson user with proper credential for clearcase server.



来源:https://stackoverflow.com/questions/1892508/hudson-integration-with-ucm-clearcase

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!