Tag SVN “Nightly” Builds with CruiseControl.Net

rajeshkumar created the topic: Tag SVN “Nightly” Builds with CruiseControl.Net
How would I do a nightly or other scheduled build for CruiseControl.NET without having a duplicate project?

In my current config, every 60 seconds, I am checking out the trunk using Subversion, running MSBuild, then either NUnit or MSTest.

I would like to commit back to SVN as a tag, but I don’t want it on every successful build. I want it to make a nightly build or some other set schedule. To me, it seems a bit tedious to have two CruiseControl.Net projects with basically the same options. What is the best way to handle that?

As a bonus, I would like it to build as a release build and commit the binaries in the same tag.
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

rajeshkumar replied the topic: Re:Tag SVN “Nightly” Builds with CruiseControl.Net
i’ll tell you how we use ccnet (and we’re quite happy with it that way).

we’ve got 20 projects on the build server and several release branches of previous versions. we only start builds on demand using the cctray application. so after a developer is done implementing a feature, he clicks the “force build” button and ccnet starts to do its thing (build, test, tag, copy build output to a network drive, notify other devs,…).

the advantage is that devs can decide when to start a build. projects that haven’t changed aren’t built. projects with work in progress can be built several commits later, only when a developer thinks that he needs a build.

one idea that comes to mind for starting nightly builds would be to use ccnet’s remoting interface (which is also used by cctray), connect it to the ccnet instance and call the force-build-method at midnight.

concerning “committing binaries to the same tag”:

there is a problem in ccnet that causes it to sometimes tag a revision from the trunk and sometimes to tag the working copy. it does this depending on if there were changes since the last build (in which case it tags the revision from the trunk), or if there were no changes since the last build (in which case it tags the working copy).

this is pretty annoying because you never know what will be committed – in the first case your binaries won’t get committed, in the second case they will.

we have actually patched ccnet ourselves to make it always commit the working copy so we get deterministic behaviour. i have once submitted the patch but it never made it in…
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

Tagged :

New Setup issues of CruseControl

scmuser created the topic: New Setup issues of CruseControl
Connectforu Config Tab Issues

Hi,

I have cruise contriol and when i navigated to Connectforu and click in Config Tab, i got following issues, plz guide me.

HTTP ERROR: 500

javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: epc-rajesh-wxp.chordiant-epc.com; nested exception is:
java.net.ConnectException: Connection refused: connect]

RequestURI=/cruisecontrol/config.jspa
Caused by:

java.io.IOException: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: epc-rajesh-wxp.chordiant-epc.com; nested exception is:
java.net.ConnectException: Connection refused: connect]
at mx4j.remote.resolver.rmi.Resolver.lookupStubInJNDI(Resolver.java:100)
at mx4j.remote.resolver.rmi.Resolver.lookupRMIServerStub(Resolver.java:72)
at mx4j.remote.resolver.rmi.Resolver.lookupClient(Resolver.java:52)
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:119)
at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:38)
at net.sourceforge.cruisecontrol.Configuration.(Configuration.java:91)
at net.sourceforge.cruisecontrol.interceptor.ConfigurationInterceptor.createConfiguration(ConfigurationInterceptor.java:76)
at net.sourceforge.cruisecontrol.interceptor.ConfigurationInterceptor.getConfiguration(ConfigurationInterceptor.java:86)
at net.sourceforge.cruisecontrol.interceptor.ConfigurationInterceptor.before(ConfigurationInterceptor.java:64)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:34)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:164)
at com.opensymphony.xwork.DefaultActionProxy.execute(DefaultActionProxy.java:116)
at com.opensymphony.webwork.dispatcher.ServletDispatcher.serviceAction(ServletDispatcher.java:272)
at com.opensymphony.webwork.dispatcher.ServletDispatcher.service(ServletDispatcher.java:237)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:362)
at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:729)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)
at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:206)
at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:324)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:829)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:513)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:395)
at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:488)

Powered by Jetty://

scmuser replied the topic: Re:New Setup issues of CruseControl
I’m using Cruisecontrol 2.6.2 and I’m having problems with the JMX Control Panel.

First off, the URL for the Control Panel contains the hostname of the computer, which can’t be resolved over the network. I have tried setting the jmxhost parameter in the web.xml file to its IP adress, but it doesn’t work; it still uses the host name. As a workaround I’ve now entered the host name and the corresponding IP adress in my Hosts file, but I don’t want to do that for every computer, so is there a way to do this within cruisecontrol?

With the above workaround the host name can be resolved, but all that I get when I click the button for the control panel is an XML file:

“There is no/ style /i/nformation/ connected to this /XML file/. Subsequent the /Tree/-/View/ of the //document// is /shown/.”

….

Does anybody know how to fix this? Thanks.

Tagged :

Unregister Issues in JMX Interface

scmuser created the topic: Unregister Issues in JMX Interface
Hi,

I am just learning Cruise Control. I access http://localhost:8000/ link and click on un-register and then this Page is disappeared.

Can you guide me how to reset this back to earlier state?

scmuser replied the topic: Re:Unregister Issues in JMX Interface
Hi

I got this solution by restarting server…

still dont knw the root cause for this.

Tagged :

Msbuild slower than devenv

scmuser created the topic: msbuild slower than devenv
Hi, I’m experiencing performance inconsistencies with regards to build duration when building a VS2008 solution file with either devenv or msbuild from command line.

My solution contains both C# and C++ projects, and I have these results:

devenv.exe (either command line or within the ide): 7 minutes msbuild.exe: 14 minutes

I tried tuning the msbuild switches passing /maxcpucount and /p:VCBuildAdditionalOptions=m# but with no luck so far.

Any idea?

scmuser replied the topic: Re:msbuild slower than devenv
what is the full msbuild command you are running?

As a side point, have you got the build output turned down to Quiet or Minimal? That reduces build time a little…

7 minutes to build in the IDE!! Personally I’d go insane, debugging must be a nightmare

Tagged :

Build Archive Policy

sgoldstein created the topic: Build Archive Policy
I wanted to get some input from the SCM community regarding build archiving. When using either a CI or nightly build approach, a number of builds are generated during a release. How do people generally define a retention policy for retaining builds on disk? Once the retention policy dictates that a build should be removed from disk, what happens to it? Do people back it up to tape or some other media? Do people simply delete it entirely?

I ask because there are situations in which, for example, a bug is filed against a particular build and the dev team may want to go back an investigate. Typically, we’ve been archiving to tape, but it’s very time consuming and I don’t feel that the value is outweighing the cost.

Thanks.

rajeshkumar replied the topic: Re:Build Archive Policy
It’s all about process you follow and what release cycle you have..Dev team doesn’t need to refer old build until some milestone has been achieved as part of build. So as a Build engineer you need to know all the milestone achieved and which build CI# and revision number.
you can write a script which will store a information about revision number associated with the build and Build number, this number can be referenced in the future to get same build using CI tools
Scenario two: here I do follow some process. Like

I always clean up incremental build.

I do escrow audit after any patch, major or minor release.

Base line after any milestone met and documentation

Keep more than one year build only when if its matching with some milestone
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

Tagged :

MSBuild Tool

rambabu1683 created the topic: MSBuild Tool
Hi guys,

i am new to this forum.
can anyone help me about MSBUILD tool with small examples?

Warm Regards,
Rambabu.M

rajeshkumar replied the topic: MSBuild Tool
These quicks urls might help you…
www.scmgalaxy.com/189-msbuild/229-introduction-to-msbuild.html
www.scmgalaxy.com/189-msbuild/161-runnin…ous-integration.html
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

Tagged :

Windows: “OpenSCManager failed – Access is denied. (0x5)” errors when

scmuser created the topic: Windows: “OpenSCManager failed – Access is denied. (0x5)” errors when
Problem:
Windows: “OpenSCManager failed – Access is denied. (0x5)” errors when starting Nexus

Solution:
You need to run the command prompt as an Administrator to avoid the problem. For example:
1. click on start
2. click “All Programs”
3. click on accessories
4. right click on “Command Prompt” icon
5. click “properties”
6. click on the “shortcut” tab on the top
7. click the advanced button at the bottom
8. click on the check box that says “Run as Administrator”.
9. click OK
When you now use the modified shortcut to the command prompt session it will allow you to perform Administrator operations and avoid the error.

Tagged :

The nexus-webapp service is not installed – The specified service does

scmuser created the topic: The nexus-webapp service is not installed – The specified service does
While installing Sonatype nexus in Windows 7, I get following error..

wrapper | The nexus-webapp service is not installed – The specified service does not exist as an installed service. (0x424)

I checked java version but no help..
C:\tools\nexus\nexus-2.7.0-04\bin>java -version
java version “1.7.0_45”
Java(TM) SE Runtime Environment (build 1.7.0_45-b18)
Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)

Some Solution on Net but no help
This happens when you run with JDK7 and is a problem with the XStream
version in Nexus. This has been fixed in XStream itself, so you can
donwload xstream-1.4.x and replace the xstream, xmlpull and xpp3 jars with
the newer versions.
You should only run Nexus on JDK7 if you have at least 7u1 or higher,
otherwise Lucene may cause fireworks.

Nexus Prerequisites

Nexus Open Source and Nexus Professional only have one prerequisite, a Java Runtime Environment (JRE) compatible with Java 7. Nexus is most often run with the JRE that is bundled with a Java Development Kit (JDK) installation, and it can be run with Oracle’s JDK for Java 7. To download the Oracle JDK, go to www.oracle.com/technetwork/java/javase/downloads/index.html . At a minium Java 7u2 is required, but we recommend tha latest available version.

Any Solution for this problem?

scmuser replied the topic: The nexus-webapp service is not installed – The specified service does
Solution:

I was stratting the nexus using ..
C:\tools\nexus\nexus-2.7.0-04\bin\nexus.bat start
But i should be using as below;

Change the wrapper.startup.timeout in C:\tools\nexus\nexus-2.7.0-04\bin\jsw\conf\wrapper.prop
# How much to wait for application to start up (increase on slower machines if needed)
wrapper.startup.timeout=30

Install Nexus…
C:\tools\nexus\nexus-2.7.0-04\bin\jsw\windows-x86-64\install-nexus.bat

Start Nexus
C:\tools\nexus\nexus-2.7.0-04\bin\nexus.bat

Run nexus
http://localhost:8081/nexus
or
http://hostname:8081/nexus

scmuser replied the topic: The nexus-webapp service is not installed – The specified service does
Start Nexus
C:\tools\nexus\nexus-2.7.0-04\bin\nexus.bat start

and default user id n password is – admin / admin123

Tagged :

Fatal error: Unable to find local grunt.

scmuser created the topic: Fatal error: Unable to find local grunt.
I am getting following error…

grunt lite
grunt-cli: The grunt command line interface. (v0.1.9)

Fatal error: Unable to find local grunt.

If you’re seeing this message, either a Gruntfile wasn’t found or grunt
hasn’t been installed locally to your project. For more information about
installing and configuring grunt, please see the Getting Started guide:

gruntjs.com/getting-started

Solution

The command line tools are not included with the latest version of Grunt (0.4 at time of writing) instead you need to install them separately.

This is a good idea because it means you can have different versions of Grunt running on different projects but still use the nice concise grunt command to run them.

So first install the grunt cli tools globally:

npm install -g grunt-cli

(or possibly sudo npm install -g grunt-cli ).

You can establish that’s working by typing grunt –version

Now you can install the current version of Grunt local to your project. So from your project’s location…

npm install grunt –save-dev

The save-dev switch isn’t strictly necessary but is a good idea because it will mark grunt in its package.json devDependencies section as a development only module.

rajeshkumar replied the topic: Fatal error: Unable to find local grunt.
while running “npm install -g grunt-cli”, i got following code…

npm http GET registry.npmjs.org/grunt-cli
npm http 304 registry.npmjs.org/grunt-cli

npm ERR! Error: No compatible version found: grunt-cli
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR! at installTargetsError (/usr/share/npm/lib/cache.js:488:10)
npm ERR! at next_ (/usr/share/npm/lib/cache.js:438:17)
npm ERR! at next (/usr/share/npm/lib/cache.js:415:44)
npm ERR! at /usr/share/npm/lib/cache.js:408:5
npm ERR! at saved (/usr/share/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR! at Object.oncomplete (/usr/lib/nodejs/graceful-fs.js:230:7)
npm ERR! You may report this log at:
npm ERR! < bugs.debian.org/npm >
npm ERR! or use
npm ERR! reportbug –attach /home/scmbuild/npm-debug.log npm
npm ERR!
npm ERR! System Linux 3.2.0-53-generic
npm ERR! command “node” “/usr/bin/npm” “install” “-g” “grunt-cli”
npm ERR! cwd /home/scmbuild
npm ERR! node -v v0.6.12
npm ERR! npm -v 1.1.4
npm ERR! message No compatible version found: grunt-cli
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/scmbuild/npm-debug.log
npm not ok
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

rajeshkumar replied the topic: Fatal error: Unable to find local grunt.
Seems like node is older version so need to user latest…
How to upgrade nodes in Ubantu
Install the dependencies:

sudo apt-get install g++ curl libssl-dev apache2-utils
sudo apt-get install git-core

Run the following commands:

git clone git://github.com/ry/node.git
cd node
./configure
make
sudo make install

How to install grunt
Here’s what I did to fix this:

Uninstalled grunt globally:

npm uninstall -g grunt

Installed grunt-cli globally:

npm install -g grunt-cli

Then, in project root dir:

npm install

And all is good. Hope this works for anyone else running into this.
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

rajeshkumar replied the topic: Fatal error: Unable to find local grunt.
After running latest nodes, while using folliowing commands i got following error…”npm install -g grunt-cli”

module.js:333
throw err;
^
Error: Cannot find module ‘graceful-fs’
at Function.Module._resolveFilename (module.js:331:15)
at Function.Module._load (module.js:273:25)
at Module.require (module.js:357:17)
at require (module.js:373:17)
at Object. (/usr/share/npm/lib/utils/ini.js:32:10)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:349:32)
at Function.Module._load (module.js:305:12)
at Module.require (module.js:357:17)
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

rajeshkumar replied the topic: Fatal error: Unable to find local grunt.
From in stacekoverlfow..

Don’t download npm from aptitude or apt-get. Instead try:

git clone git://github.com/isaacs/npm.git
cd npm/scripts
chmod +x install.sh
sudo ./install.sh

saw it here: NPM can’t install appjs. Error: Cannot find module ‘graceful-fs’

or

sudo npm install

or

sudo apt-get remove npm
sudo apt-get install npm
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

Tagged :

Error: Cannot find module ‘graceful-fs’

rajeshkumar created the topic: Error: Cannot find module ‘graceful-fs’
Error –

Error: Cannot find module ‘graceful-fs’
at Function.Module._resolveFilename (module.js:331:15)
at Function.Module._load (module.js:273:25)
at Module.require (module.js:357:17)
at require (module.js:373:17)
at Object. (/usr/share/npm/lib/utils/ini.js:32:10)
at Module._compile (module.js:449:26)
at Object.Module._extensions..js (module.js:467:10)
at Module.load (module.js:349:32)
at Function.Module._load (module.js:305:12)
at Module.require (module.js:357:17)
root@mtv-ubld-39:~/node/npm/scripts# export NODE_PATH=/usr/lib/nodejs/graceful-fs.js
root@mtv-ubld-39:~/node/npm/scripts# echo $NODE_PATH
/usr/lib/nodejs/graceful-fs.js
root@mtv-ubld-39:~/node/npm/scripts# echo $NODE_PATH
/usr/lib/nodejs/graceful-fs.js

Solution

Your npm isn’t properly installed. Execute (as root):

curl npmjs.org/install.sh | bash

This reinstalls npm on your computer, it should work afterwards.

You might need to restart your shell after that for the changes to take effect.

In some cases even the installer fails because of the graceful-fs error, in this case you might need to remove npm using your distribution’s package manager first, e.g.

sudo apt-get remove npm

Or

www.scmgalaxy.com/48-other-build-tools/2…ind-local-grunt.html
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

Tagged :