John,

You're bumping into the same confusion I did when I first got started.
As I've grokked the subject, you've got two options (which you've
already figured out):

1. Store the build files with the source and use relative paths in your
build file to reference resources; this allows you to use the "clean
room" checkout method that Draco already does for you to a virgin
location for every build.

+ This is good because it is what Draco expects you to do.
+ This is good if you like to have a 100% fresh build every time.
+ This is good for smoke tests.
- This is bad if you care about your debug symbols and the paths to
source contained therein.

2. Store the build file somewhere else and manage the checkout of source
yourself using NAnt tasks to a location that you know and love
(duplicative effort, because Draco's already checked it out for you to
an imaginary location with a really scary file path) and use fully
qualified paths for all your resources in the build file so that it
doesn't matter where the build file is run from.

+ This is good if you're a masochist.
+ This is good if you're paranoid and don't trust "developers" to
maintain the build script.
+ This is good if you care about your debug symbols and the paths to
source contained therein.
- This is bad if you have high concurrency, because many simultaneous
runs of the same builds will step on each other and ugly things happen.
(I don't know if Draco prevents simultaneous runs of the same build yet
or not.)

[The biggest concurrency problems that I had were the previous version
of NDoc -- which they fixed -- and database changes (such as new sprocs)
-- which is a logical flaw in the SQL scripts and has to be re-fixed
every time a "developer" writes an unrepeatable transaction or doesn't
pre-test changes carefully.]

** Having fought with both methods in the past 18 months, I feel your
pain.  :)  I'm using #1 for CI builds to the sandbox servers.  To solve
the debug symbols problem on the integration servers, there are
scheduled builds using well-known file locations where we check out
source to and issue the same build logic with different target servers.

What we've long been missing is a snifty HOWTO document with some CI
theory and examples to expand on what's in default build config file...
It's on my wish list to contribute, but I won't have time until mid-1Q05
to even breathe, let alone actually do something fun.  :)


> -----Original Message-----
> From: [EMAIL PROTECTED]
[mailto:draconet-users-
> [EMAIL PROTECTED] On Behalf Of John Sheppard
> Sent: Thursday, December 09, 2004 10:13 AM
> To: [EMAIL PROTECTED]
> Subject: [Draconet-users] Question about NAnt integration and
compiling C#
> code
> 
> Hi all,
>    I am having a problem getting Draco to run my NAnt build file. The
> polling and checkout of source works as expected with one caveat.  I
have
> to
> designate an '$' character in front of my VSS path for it to poll and
> check
> my solution.  I thought I could do a '\x\y\z' type of path but instead
I
> have to do a '$\x\y\z' style path in order for it to work.
> 
> Here are the details (specifics changed to protect the innocent).
> 
> I have set NAnt to debug to try to get a better handle on the failure.
> Here
> are the details of my project config:
> 
>   <rootsourcedir>Source</rootsourcedir>
>   <pollperiod>600</pollperiod>
>   <timeoutperiod>3600</timeoutperiod>
>   <quietperiod>60</quietperiod>
>   <mailserver>mail.yourdomain.com</mailserver>
>   <fromaddress>[EMAIL PROTECTED]</fromaddress>
>   <builds>
>     <build>
>       <alwaysbuild>true</alwaysbuild>
>       <name>Tropicos2</name>
>       <pollperiod>600</pollperiod>
>       <quietperiod>600</quietperiod>
>       <timeoutperiod>600</timeoutperiod>
>       <notification>
>         <file>
>           <dir>d:\BuildTools\AutomatedBuilds\Tropicos</dir>
>           <create>true</create>
>         </file>
>       </notification>
>       <nant program="D:\BuildTools\nant-0.85-rc1\bin\nant.exe
-debug:+">
>         <buildfile>master.build</buildfile>
>       </nant>
>       <vss>
>         <project>$/MOBOT/Tropicos2/Tropicos</project>
>         <username>username</username>
>         <password>password</password>
>         <ssdir>\\UNCEncoded path\VSS</ssdir>
>       </vss>
>     </build>
>   </builds>
> 
> Notice the path to the build file.  When I set this to an absolute
path
> where I was storing my master.build file Draco would do a cd /d into
that
> directory then run the nant.exe with the correct parameters passed.
NAnt
> would fail because it couldn't find my solution file in the directory
that
> draco had cd'd into.  So I changed my build file to be included in my
> solution files and when my project is checked out the build file is
> checked
> out into the base directory of my solution.  My solution is three
levels
> deep in my source safe structure so my project is checked out as
follows:
> 
> D:\BuildTools\Draco.NET Service\Source\ProjectName-TempID\Path to my
> source
> safe project (in this case '$\MOBOT\Tropicos2\Tropicos'.  This is
where
> the
> directory structure for the project is created with both the solution
file
> and build file at this level.  I am thinking all is as it should be.
VSS
> checks all the files out, builds the directory structure then NAnt is
> called
> and here is where it is throwing an error.  The error is: 'The given
> path's
> format is not supported.'.  I assumed that it would 'cd /d' into the
root
> directory for my solution and try to find the build file there and run
it.
> This evedently is not the case.  Any help that you may be able to give
> would
> be greatly appreciated.
> 
> Thanks,
> 
> John Sheppard
> 
> 
> The specific error I get is:
> 
> ERROR Draco.Core.Runtime.BuildRunner - Failed to process build
> 'Tropicos2'.
> The following exception occurred:
> System.NotSupportedException: The given path's format is not
supported.
>    at System.Security.Util.StringExpressionSet.CanonicalizePath(String
> path,
> Boolean needFullPath)
>    at System.Security.Util.StringExpressionSet.AddExpressions(String[]
> str,
> Boolean checkForDuplicates, Boolean needFullPath)
>    at
>
System.Security.Permissions.FileIOPermission.AddPathList(FileIOPermissio
nA
> ccess
> access, String[] pathListOrig, Boolean checkForDuplicates, Boolean
> needFullPath, Boolean copyPathList)
>    at
>
System.Security.Permissions.FileIOPermission..ctor(FileIOPermissionAcces
s
> access, String[] pathList, Boolean checkForDuplicates, Boolean
> needFullPath)
>    at System.IO.Path.GetFullPath(String path)
>    at Draco.Core.Tool.NAntBuildTool.Execute(String baseDirectory)
>    at Draco.Core.Runtime.BuildRunner.BuildModule(BuildResult results)
>    at Draco.Core.Runtime.BuildRunner.Start(BuildType buildType)
> Exception: System.NotSupportedException
> Message: The given path's format is not supported.
> Source: mscorlib
>    at System.Security.Util.StringExpressionSet.CanonicalizePath(String
> path,
> Boolean needFullPath)
>    at System.Security.Util.StringExpressionSet.AddExpressions(String[]
> str,
> Boolean checkForDuplicates, Boolean needFullPath)
>    at
>
System.Security.Permissions.FileIOPermission.AddPathList(FileIOPermissio
nA
> ccess
> access, String[] pathListOrig, Boolean checkForDuplicates, Boolean
> needFullPath, Boolean copyPathList)
>    at
>
System.Security.Permissions.FileIOPermission..ctor(FileIOPermissionAcces
s
> access, String[] pathList, Boolean checkForDuplicates, Boolean
> needFullPath)
>    at System.IO.Path.GetFullPath(String path)
>    at Draco.Core.Tool.NAntBuildTool.Execute(String baseDirectory)
>    at Draco.Core.Runtime.BuildRunner.BuildModule(BuildResult results)
>    at Draco.Core.Runtime.BuildRunner.Start(BuildType buildType)
> 
> 
> 
> 
> -------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT Products from real
users.
> Discover which products truly live up to the hype. Start reading now.
> http://productguide.itmanagersjournal.com/
> _______________________________________________
> Draconet-users mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/draconet-users


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/
_______________________________________________
Draconet-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/draconet-users

Reply via email to