开发者

how to create a webservice to wrap a perl scripts or shell scripts

Our development is mostly on windows, VCS is ClearCase. We also use quite lot of scripts (perl, bash) on Linux to do code quality checks, regression tests etc. For example a script takes stream name, creates a dynamic view, generate a CPD report for the newly added files. Another one submits specific tests to a sun grid engine(SGE)

Currently user should login to a linux machine with a 开发者_高级运维specific account, then edit some configuration files and run the scripts. User sometimes makes unwanted edits and creates trouble.

We could probably improve the flow by using rsh.

I guess exposing the whole thing via web service may better. The user could then use a java program(web service client) to invoke the taks.

   java com.check.MyQualityChecks -stream blah -generate-cpd

Is there any thing that could help to me wrap existing scripts via a web-service?


There isn't a direct cleartool encapsulation through web service.
The closest existing service is for CCRC (ClearCase Remote client), with its Java CM API, which you could use if Linux machine was a CCRC server.

I would recommend developing your own web service, which would then call the script, but beware of the primary group and owner executing that script through the web service: the account needs to be in the right group (one of the groups of the Vob) and with the right umask (in order to create correctly protected views).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜