[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

I suspect my hooks are choking my server

From: Eric Carlson <eric.carlson_at_group-technical.com>
Date: 2004-08-18 17:37:45 CEST

RH Fed C2 Final, svn 1.0.6, 256M RAM Athlon XP 2400+
From a fresh boot the hook scripts fire & complete in 5 seconds. Over
a day the same operation gets longer and longer until it takes 10
minutes! Once there was an OOM error and on the console the message
that the vm *and* svn process had been killed appeared. The vm I'm
assuming was the java process, because these hooks invoke an ant batch
to build the committed source and copy to a qa server. The other
unusual thing is I've been playing wav files ;-) Well, its a great way
to monitor remote activity when I'm in the same room as the server.

Thanks for reading so far, I wonder if anyone can spot any howlers

The 2 pertinent questions are, is it ok to use the "&" in my
post-commit the way I am doing and also is there any know leak/problem
playing the wav files this way?

It just happened now and "top" showed some astonishing numbers:

(Each hooks folder contains a /wav, /log and /mail folder populated


cd $1/hooks
# Launch handler and return so clients don't have to wait
sh ./post-commit-handler.sh $1 $2 &


# $1 = full path to repos
# $2 = revision

play wav/begin.wav
source /etc/profile

repos=$(echo $1 | gawk 'BEGIN {FS ="[ \t]*|[/]"} {print $5}')

./publish.sh $1 $2 $repos > log/publish.log
./send-email.sh $1 $2 $repos $repos.svn.log@<mydomain>.com
play wav/end.wav


cd $wd
echo Exporting from svn repository $1
echo Destination is $dest

# Ensure target dir is clean by removing it - careful for multiple
if [ -w $ws ]
  echo Workspace exists from previous build - deleting $ws
  rm -r $ws

mkdir -p $ws
svn export svn://svn.<mydomain>.com/$3/trunk $ws --username foo
--password bar --force

if [ -w $ws/WEB-INF/ant/m.sh ]
  echo Ant buildfile exists, invoking build...
  cd $ws/WEB-INF/ant
  echo Ant build complete.
  echo Ant buildfile does not exist

echo Invoking ant upload...
cd $wd
ant -q -f publish.xml -Dproject=$1 -Dant.home="$ANT_HOME"
-Dresin.home="$BUILD_RESIN_TARGET" -Dsrc="$ws" -Ddest="$dest" >
cd $wd
echo Ant upload completed.

# $1 = REPOS (fq)
# $2 = REVNUM
# $3 = project
# $4 = Email To:
# $5 = Email From:

./commit-email-summary.pl --from $5 -s "$3" "$1" "$2" $4

Note: Everytime "play wav" fires I see a console message saying it
uses an out of date OSS driver
Note: commit-email.summary.pl is almost the same as commit-email.pl
but contains some minor cosmetic tweaks I'm certain don't affect this

To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Aug 18 17:38:11 2004

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.