History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: CCNET-239
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Owen Rogers
Reporter: Mike Roberts
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
CruiseControl .NET

Allow per-project config files

Created: 03/Nov/04 07:32 PM   Updated: 29/Sep/09 02:24 PM
Return to search
Component/s: Source Control
Affects Version/s: 1.1.1
Fix Version/s: 0.9.1

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
File Attachments: 1. Zip Archive XmlFileEntities.zip (4 kb)

Environment: Windows 2000


 All   Comments   Work Log   Change History      Sort Order:
You can use an DTD entity in the XML to get this to a limited extent.

This link explains XML entities in detail:
http://tech.irt.org/articles/js212/

You declare an external entity like this:
<!ENTITY section1 SYSTEM "path/to/section_1.xml">

And you use it like this:
<document>
  &section1;
</document>

So for cruise control, for example, you can do:
<!ENTITY project1 SYSTEM "project1.xml">
<!ENTITY project2 SYSTEM "project2.xml">
<!ENTITY project3 SYSTEM "project3.xml">
<cruisecontrol>
  &project1;
  &project2;
  &project3;
</cruisecontrol>

Further, in each project you could take common settings and break them out as well:
<!EMTITY schedule SYSTEM "schedule.xml">
<!ENTITY sourcecontrol SYSTEM "sourcecontrol.xml">
<!ENTITY buildnant SYSTEM "buildnant.xml">
<!ENTITY standardtasks SYSTEM "stdtasks.xml">
<!ENTITY publishers SYSTEM "publishers.xml">
<project name="project1">
  <webURL>http://localhost/iis/ccweb&lt;/webURL>
  &schedule;
  &sourcecontrol;
  &buildnant;
  &stdtasks;
  &publishers;
  <modificationDelaySeconds>10</modificationDelaySeconds>
</project>

This should work with any XML application. It's part of the standard, and entities are used heavily by XHTML. Unfortunately, a lot of people "wrote their own XML parser" for their application, and when you have to deal with the full XML feature set, these usually fail miserably to handle fundamental XML features such as external entities.

Owen Rogers [17/May/05 08:44 PM]
Ben Lowery wrote:

I just wrote up some code [1] to figure this out.

It appears that the XmlValidatingReader can resolve entities, so this should
work. However, you probably want to specify the ValidationType on the
reader explicitly if it's not already being done; if the reader sees a DTD,
it will most likely switch to DTD-based validation.

So, in theory, it's possible. I don't have my CCNET instance readily
available, so I can't test to see if CCNET current supports it. It would be
super easy to test if it did though.

Also, Mike, here's the full URL that worked for me:
http://peeps.dallas.focus-technologies.com/roller/page/nithy/20040128#using_the_entity_includes_in

Change by Owen Rogers [17/May/05 08:45 PM]
Field Original Value New Value
Attachment XmlFileEntities.zip [ 10313 ]

Change by Owen Rogers [19/May/05 07:31 AM]
Assignee Owen Rogers [ orogers ]

Change by Owen Rogers [19/May/05 07:31 AM]
Fix Version/s Next [ 10111 ]
Environment
Description From Brenton House's request on ccnet-user:
--
Is it possible to split multiple projects into separate xml config files? I have a several very complex projects running under CC.NET and it would be very nice for maintainability to be able to separate them into different xml config files and just include them from the main ccnet.config file.
--
Probably for a separate 'config service' at a later date.
From Brenton House's request on ccnet-user:
--
Is it possible to split multiple projects into separate xml config files? I have a several very complex projects running under CC.NET and it would be very nice for maintainability to be able to separate them into different xml config files and just include them from the main ccnet.config file.
--
Probably for a separate 'config service' at a later date.

Owen Rogers [19/May/05 01:58 PM]
fixed in build 934. as suggested i set the ValidationType to None. this disallows schema validation and i needed to change some tests that were using the ccnet.xsd. i wrote a test to verify that this works together with NetReflector.

Change by Owen Rogers [19/May/05 01:58 PM]
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]

Change by ahmed sabri [20/Nov/06 09:11 AM]
Component/s Source Control [ 10007 ]
Component/s Builder [ 10000 ]
Issue Type New Feature [ 2 ] Bug [ 1 ]
Description From Brenton House's request on ccnet-user:
--
Is it possible to split multiple projects into separate xml config files? I have a several very complex projects running under CC.NET and it would be very nice for maintainability to be able to separate them into different xml config files and just include them from the main ccnet.config file.
--
Probably for a separate 'config service' at a later date.
I can't have a working CCNET.CONFIG file for SCM Synergy, and I can't get a working sample file.

A POST is open in ccnet-user mailing list named "Synergy source control with Cruise Control .Net.
".

So, I have made the following tests for example :

file content : <sourcecontrol type="synergy"></sourcecontrol>
--> the server doesn't start

file content : <sourcecontrol type="vss"></sourcecontrol>
--> [GESDEM_DT:ERROR] Exception: Registry key or value name not found: Software\\Microsoft\\SourceSafe\SCCServerPath

It seems that the SCM configuration for Synergy isn't taken by the server.

Help pleasea separate 'config service' at a later date.
Affects Version/s 1.1.1 [ 10230 ]
Environment Windows 2000
Priority Minor [ 4 ] Critical [ 2 ]

Change by ahmed sabri [20/Nov/06 09:13 AM]
Description I can't have a working CCNET.CONFIG file for SCM Synergy, and I can't get a working sample file.

A POST is open in ccnet-user mailing list named "Synergy source control with Cruise Control .Net.
".

So, I have made the following tests for example :

file content : <sourcecontrol type="synergy"></sourcecontrol>
--> the server doesn't start

file content : <sourcecontrol type="vss"></sourcecontrol>
--> [GESDEM_DT:ERROR] Exception: Registry key or value name not found: Software\\Microsoft\\SourceSafe\SCCServerPath

It seems that the SCM configuration for Synergy isn't taken by the server.

Help pleasea separate 'config service' at a later date.

Change by Craig Sutherland [29/Sep/09 02:24 PM]
Status Resolved [ 5 ] Closed [ 6 ]