CCNet 1.6 条件插件需要帮助!

发布于 2024-08-31 08:37:47 字数 6060 浏览 7 评论 0原文

我无法使已添加到 CCNet 1.6 版本的条件插件正常工作 - 点击。我正在运行最新版本的 CCNet (1.6.7258.1),并且我的 ccnet.config 中有以下代码:

<project name="9iCompile"> 
<sourcecontrol type="svn"> 
  <trunkUrl>http://bis-build:81/svn/Oracle/oas_forms/COPEN</trunkUrl> 
  <workingDirectory>C:\OAS\COPEN</workingDirectory> 
  <username>*</username> 
  <password>*</password> 
  <executable>C:\Program Files\VisualSVN\bin\svn.exe</executable> 
</sourcecontrol> 


<conditional> 
  <conditions> 
    <compareCondition> 
      <value1>$[ProjectType]</value1> 
      <value2>copen</value2> 
      <evaluation>equal</evaluation> 
      <ignoreCase>true</ignoreCase> 
    </compareCondition> 
  </conditions> 

  <tasks> 
  <nant> 
    <executable>C:\Program Files\nant-0.85\bin\nant.exe</executable> 
    <baseDirectory>C:\OAS</baseDirectory> 
    <buildFile>Oracle9i_Automation_v2.build</buildFile> 
    <targetList> 
      <target>build</target> 
    </targetList> 
  </nant> 
  </tasks> 
</conditional> 


<!-- more conditional statements would be here for different project types if I can get it to work --> 

<parameters> 
  <selectParameter name="ProjectType"> 
    <description>The type of project to operate on.</description> 
    <allowedValues> 
      <value name="COPEN">copen</value> 
      <value name="BCS">bcs</value> 
      <value name="FCDD">fcdd</value> 
    </allowedValues> 
  </selectParameter>
</parameters> 

<security type="defaultProjectSecurity" defaultRight="Deny"> 
  <permissions> 
    <rolePermission name="Developers" ref="Developers"/> 
    <rolePermission name="Accepters" ref="Accepters"/> 
    <rolePermission name="Releasers" ref="Releasers"/> 
    <rolePermission name="Administrators" ref="Administrators"/> 
  </permissions> 
</security> 
</project> 

每当我尝试运行此配置时,CCNet 服务器就会崩溃 以下输出:

[14:ERROR] Exception: Unused node detected:
        <conditional>
          <conditions>
            <compareCondition>
              <value1>$[ProjectType]</value1>
              <value2>copen</value2>
              <evaluation>equal</evaluation>
              <ignoreCase>true</ignoreCase>
            </compareCondition>
          </conditions>
          <tasks>
            <nant>
              <executable>C:\Program Files\nant-0.85\bin\nant.exe</executable>
              <baseDirectory>C:\OAS</baseDirectory>
              <buildFile>Oracle9i_Automation_v2.build</buildFile>
              <targetList>
                <target>build</target>
              </targetList>
            </nant>
          </tasks>
        </conditional>
        ----------
        ThoughtWorks.CruiseControl.Core.Config.ConfigurationException: Unused
        node detected:
        <conditional>
          <conditions>
            <compareCondition>
              <value1>$[ProjectType]</value1>
              <value2>copen</value2>
              <evaluation>equal</evaluation>
              <ignoreCase>true</ignoreCase>
            </compareCondition>
          </conditions>
          <tasks>
            <nant>
              <executable>C:\Program Files\nant-0.85\bin\nant.exe</executable>
              <baseDirectory>C:\OAS</baseDirectory>
              <buildFile>Oracle9i_Automation_v2.build</buildFile>
              <targetList>
                <target>build</target>
              </targetList>
            </nant>
          </tasks>
        </conditional>

         at ThoughtWorks.CruiseControl.Core.Config.NetReflectorConfigurationReader.Defa­ultErrorProcesser.ProcessError(String message)
         at ThoughtWorks.CruiseControl.Core.Config.NetReflectorConfigurationReader.<>c_­_DisplayClass1.<Read>b__0(InvalidNodeEventArgs args) 
         at Exortech.NetReflector.InvalidNodeEventHandler.Invoke(InvalidNodeEventArgsar­gs) 
         at Exortech.NetReflector.NetReflectorTypeTable.OnInvalidNode(InvalidNodeEventA­rgs args) 
         at Exortech.NetReflector.XmlTypeSerialiser.HandleUnusedNode(NetReflectorTypeTa­ble table, XmlNode orphan) 
         at Exortech.NetReflector.XmlTypeSerialiser.ReadMembers(XmlNode node, Object instance, NetReflectorTypeTable table) 
         at Exortech.NetReflector.XmlTypeSerialiser.Read(XmlNode node, NetReflectorTypeTable table) 
         at Exortech.NetReflector.NetReflectorReader.Read(XmlNode node) 
         at ThoughtWorks.CruiseControl.Core.Config.NetReflectorConfigurationReader.Read­(XmlDocument document, IConfigurationErrorProcesser errorProcesser) 
         at ThoughtWorks.CruiseControl.Core.Config.DefaultConfigurationFileLoader.Load(­FileInfo configFile) 
         at ThoughtWorks.CruiseControl.Core.Config.FileConfigurationService.Load() 
         at ThoughtWorks.CruiseControl.Core.Config.FileWatcherConfigurationService.Load­() 
         at ThoughtWorks.CruiseControl.Core.Config.CachingConfigurationService.Load() 
         at ThoughtWorks.CruiseControl.Core.CruiseServer.Restart() 
         at ThoughtWorks.CruiseControl.Core.Config.ConfigurationUpdateHandler.Invoke() 
         at ThoughtWorks.CruiseControl.Core.Config.FileWatcherConfigurationService.Hand­leConfigurationFileChanged(Object source, FileSystemEventArgs args) 
      ---------- 

有人可以帮忙吗?我不知道我在这里做错了什么或者 如果这是一个错误:( 几天前我也在 ccnet-user 组上发帖,但没有收到任何回复:(

I cannot get the conditional plugin to work that has been added to CCNet as of version 1.6 - clicky. I am running the latest version of CCNet (1.6.7258.1) and have the following code in my ccnet.config:

<project name="9iCompile"> 
<sourcecontrol type="svn"> 
  <trunkUrl>http://bis-build:81/svn/Oracle/oas_forms/COPEN</trunkUrl> 
  <workingDirectory>C:\OAS\COPEN</workingDirectory> 
  <username>*</username> 
  <password>*</password> 
  <executable>C:\Program Files\VisualSVN\bin\svn.exe</executable> 
</sourcecontrol> 


<conditional> 
  <conditions> 
    <compareCondition> 
      <value1>$[ProjectType]</value1> 
      <value2>copen</value2> 
      <evaluation>equal</evaluation> 
      <ignoreCase>true</ignoreCase> 
    </compareCondition> 
  </conditions> 

  <tasks> 
  <nant> 
    <executable>C:\Program Files\nant-0.85\bin\nant.exe</executable> 
    <baseDirectory>C:\OAS</baseDirectory> 
    <buildFile>Oracle9i_Automation_v2.build</buildFile> 
    <targetList> 
      <target>build</target> 
    </targetList> 
  </nant> 
  </tasks> 
</conditional> 


<!-- more conditional statements would be here for different project types if I can get it to work --> 

<parameters> 
  <selectParameter name="ProjectType"> 
    <description>The type of project to operate on.</description> 
    <allowedValues> 
      <value name="COPEN">copen</value> 
      <value name="BCS">bcs</value> 
      <value name="FCDD">fcdd</value> 
    </allowedValues> 
  </selectParameter>
</parameters> 

<security type="defaultProjectSecurity" defaultRight="Deny"> 
  <permissions> 
    <rolePermission name="Developers" ref="Developers"/> 
    <rolePermission name="Accepters" ref="Accepters"/> 
    <rolePermission name="Releasers" ref="Releasers"/> 
    <rolePermission name="Administrators" ref="Administrators"/> 
  </permissions> 
</security> 
</project> 

The CCNet server crashes whenever I try to run this config though with
the following output:

[14:ERROR] Exception: Unused node detected:
        <conditional>
          <conditions>
            <compareCondition>
              <value1>$[ProjectType]</value1>
              <value2>copen</value2>
              <evaluation>equal</evaluation>
              <ignoreCase>true</ignoreCase>
            </compareCondition>
          </conditions>
          <tasks>
            <nant>
              <executable>C:\Program Files\nant-0.85\bin\nant.exe</executable>
              <baseDirectory>C:\OAS</baseDirectory>
              <buildFile>Oracle9i_Automation_v2.build</buildFile>
              <targetList>
                <target>build</target>
              </targetList>
            </nant>
          </tasks>
        </conditional>
        ----------
        ThoughtWorks.CruiseControl.Core.Config.ConfigurationException: Unused
        node detected:
        <conditional>
          <conditions>
            <compareCondition>
              <value1>$[ProjectType]</value1>
              <value2>copen</value2>
              <evaluation>equal</evaluation>
              <ignoreCase>true</ignoreCase>
            </compareCondition>
          </conditions>
          <tasks>
            <nant>
              <executable>C:\Program Files\nant-0.85\bin\nant.exe</executable>
              <baseDirectory>C:\OAS</baseDirectory>
              <buildFile>Oracle9i_Automation_v2.build</buildFile>
              <targetList>
                <target>build</target>
              </targetList>
            </nant>
          </tasks>
        </conditional>

         at ThoughtWorks.CruiseControl.Core.Config.NetReflectorConfigurationReader.Defa­ultErrorProcesser.ProcessError(String message)
         at ThoughtWorks.CruiseControl.Core.Config.NetReflectorConfigurationReader.<>c_­_DisplayClass1.<Read>b__0(InvalidNodeEventArgs args) 
         at Exortech.NetReflector.InvalidNodeEventHandler.Invoke(InvalidNodeEventArgsar­gs) 
         at Exortech.NetReflector.NetReflectorTypeTable.OnInvalidNode(InvalidNodeEventA­rgs args) 
         at Exortech.NetReflector.XmlTypeSerialiser.HandleUnusedNode(NetReflectorTypeTa­ble table, XmlNode orphan) 
         at Exortech.NetReflector.XmlTypeSerialiser.ReadMembers(XmlNode node, Object instance, NetReflectorTypeTable table) 
         at Exortech.NetReflector.XmlTypeSerialiser.Read(XmlNode node, NetReflectorTypeTable table) 
         at Exortech.NetReflector.NetReflectorReader.Read(XmlNode node) 
         at ThoughtWorks.CruiseControl.Core.Config.NetReflectorConfigurationReader.Read­(XmlDocument document, IConfigurationErrorProcesser errorProcesser) 
         at ThoughtWorks.CruiseControl.Core.Config.DefaultConfigurationFileLoader.Load(­FileInfo configFile) 
         at ThoughtWorks.CruiseControl.Core.Config.FileConfigurationService.Load() 
         at ThoughtWorks.CruiseControl.Core.Config.FileWatcherConfigurationService.Load­() 
         at ThoughtWorks.CruiseControl.Core.Config.CachingConfigurationService.Load() 
         at ThoughtWorks.CruiseControl.Core.CruiseServer.Restart() 
         at ThoughtWorks.CruiseControl.Core.Config.ConfigurationUpdateHandler.Invoke() 
         at ThoughtWorks.CruiseControl.Core.Config.FileWatcherConfigurationService.Hand­leConfigurationFileChanged(Object source, FileSystemEventArgs args) 
      ---------- 

Can someone please help?? I have no idea what I'm doing wrong here or
if this is a bug :( I have also posted on the ccnet-user group several days ago but have not received any response :(

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

稍尽春風 2024-09-07 08:37:47

我收到了来自 ccnet-user 的回复现在组。条件块实际上是一种任务类型,因此需要位于任务或发布者元素中。

I have received a response from the ccnet-user group now. The conditional block is in fact a task type so needs to be in a tasks or publishers element.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文