<commit_before>﻿<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema 
  xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  elementFormDefault="qualified">

  <!-- ACTIONS -->
  <xsd:element name="Connection" abstract="true" type="ConnectionType"/>
  <xsd:complexType name="ConnectionType" abstract="true">
    <xsd:annotation><xsd:documentation xml:lang="en">
    The connection to be established when an event begin.
    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
    
      <xsd:element minOccurs="0" maxOccurs="1" name="respawnIncrement" type="xsd:positiveInteger">
        <xsd:annotation><xsd:documentation xml:lang="en">
        Each time a runtime dies, it is automatically restarted by the agent. To avoid
        system overloading, the agent waits for a given amount of time before restarting
        the runtime. This delay depends of the number of restart and the respawnincrement
        </xsd:documentation></xsd:annotation>
      </xsd:element>
      
      <xsd:element minOccurs="0" maxOccurs="1" name="javaStarterClass" type="javaClassName">
        <xsd:annotation><xsd:documentation xml:lang="en">
        The java class name to be started by the agent. 
        The element is optional since the agent will automatically starts the class
        corresponding to the Connection if not specified. This element can be used to 
        override the defaut class if needed.
        </xsd:documentation></xsd:annotation>
      </xsd:element>
    
      <xsd:element minOccurs="0" maxOccurs="1" name="nodename" type="nonEmptyString">
        <xsd:annotation><xsd:documentation xml:lang="en">
        The ProActive node name to be started
        </xsd:documentation></xsd:annotation>
      </xsd:element>
    </xsd:sequence>
    
    <xsd:attribute name="enabled" type="xsd:boolean" use="required">
      <xsd:annotation><xsd:documentation xml:lang="en">
      True if this action is enabled. False otherwise
      One and only one action can be enabled.
      </xsd:documentation></xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>


  <xsd:element name="localBind" substitutionGroup="Connection">
    <xsd:complexType>
      <xsd:annotation><xsd:documentation xml:lang="en">
      Starts a ProActive node with a given name.
      It is up to the infrastructure to discover this node by performing a lookup
      </xsd:documentation></xsd:annotation>
      <xsd:complexContent>
        <xsd:extension base="ConnectionType"/>
      </xsd:complexContent>
    </xsd:complexType>
  </xsd:element>


  <xsd:element name="rmConnection" substitutionGroup="Connection">
    <xsd:complexType>
      <xsd:annotation><xsd:documentation xml:lang="en">
      Starts a ProActive node and register to a ProActive Ressource Manager by
      using a callback	
      </xsd:documentation></xsd:annotation>
      <xsd:complexContent mixed="false">
        <xsd:extension base="ConnectionType">
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="1" name="url" type="nonEmptyString">
              <xsd:annotation><xsd:documentation xml:lang="en">
              The URL of the ProActive Ressource Manager
              </xsd:documentation></xsd:annotation>
            </xsd:element>

            <xsd:element minOccurs="0" maxOccurs="1" name="nodeSourceName" type="nonEmptyString">
              <xsd:annotation><xsd:documentation xml:lang="en">
              The name of the ProActive Ressource Manager node source
              </xsd:documentation></xsd:annotation>
            </xsd:element>

            <xsd:element minOccurs="1" maxOccurs="1" name="credential">
              <xsd:annotation><xsd:documentation xml:lang="en">
              The path of the file containing the credentials to use to connect
              to the ProActive Ressource Manager
              </xsd:documentation></xsd:annotation>
              <xsd:complexType>
                <xsd:sequence>
                  <xsd:element minOccurs="0" maxOccurs="1" name="path" type="nonEmptyString">
                    <xsd:annotation><xsd:documentation xml:lang="en">
                    The patht to the credential to use    
                    </xsd:documentation></xsd:annotation>
                  </xsd:element>
                </xsd:sequence>

                <xsd:attribute  name="usedefault" type="xsd:boolean" use="required">
                  <xsd:annotation><xsd:documentation xml:lang="en">
                  If true, the agent will try to use the credential located at the standard
                  path.
                  </xsd:documentation></xsd:annotation>
                </xsd:attribute>
              </xsd:complexType>
            </xsd:element>
          </xsd:sequence>
        </xsd:extension>
      </xsd:complexContent>
    </xsd:complexType>
  </xsd:element>


  <xsd:element name="customConnection" substitutionGroup="Connection">
  <xsd:complexType>
    <xsd:complexContent>
      <xsd:extension base="ConnectionType">
        <xsd:sequence>
          <xsd:element minOccurs="0" maxOccurs="1" name="args">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element minOccurs="1" maxOccurs="unbounded" name="arg" type="xsd:string">
                  <xsd:annotation><xsd:documentation xml:lang="en">
                      The arguments to be passed to the java class
                  </xsd:documentation></xsd:annotation>
                </xsd:element>
              </xsd:sequence>
            </xsd:complexType>
          </xsd:element>
        </xsd:sequence>
      </xsd:extension>
    </xsd:complexContent>
  </xsd:complexType>
  </xsd:element>




  <!-- EVENTS -->
  <xsd:complexType name="CalendarEvent">
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="start">
        <xsd:complexType>
          <xsd:attribute name="day" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The name of the starting day in the week
            (lowercase)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:string">
                <xsd:enumeration value="monday" />
                <xsd:enumeration value="tuesday" />
                <xsd:enumeration value="wednesday" />
                <xsd:enumeration value="thursday" />
                <xsd:enumeration value="friday" />
                <xsd:enumeration value="saturday" />
                <xsd:enumeration value="sunday" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>

          <xsd:attribute name="hour" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The hour of the start, 24 hour format (0 to 23)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="23" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>
   
          <xsd:attribute name="minute"  use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The minute of the start (0 to 59)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="59" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>
        
          <xsd:attribute name="second" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The second of the start (0 to 59)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="59" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>
        </xsd:complexType>
      </xsd:element>

      <xsd:element minOccurs="1" maxOccurs="1" name="duration">
        <xsd:complexType>
          <xsd:attribute name="days" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The number of days the event lasts (0 to 6).
            Since this is a weekly planning, cannot be greater than 6
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="6" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>

          <xsd:attribute name="hours" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The number of hours the event lasts (0 to 23).
            A number greater than 23 cannot be used to describe an event
            lasting more than one day. The durationDays element must be used.
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="23" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>

          <xsd:attribute name="minutes" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The number of minutes the event last (0 to 59)
            A number greater than 59 cannot be used to describe an event
            lasting more than one hour. The durationDays or durationHours
            elements must be used.
          </xsd:documentation></xsd:annotation>
          <xsd:simpleType>
            <xsd:restriction base="xsd:unsignedInt">
              <xsd:minInclusive value="0" />
              <xsd:maxInclusive value="59" />
            </xsd:restriction>
          </xsd:simpleType>
        </xsd:attribute>

        <xsd:attribute name="seconds" use="required">
          <xsd:annotation><xsd:documentation xml:lang="en">
          The number of seconds the event last (0 to 59)
          A number greater than 59 cannot be used to describe an event
          lasting more than one minute. The durationDays, durationHours or
          durationMinutes elements must be used.
          </xsd:documentation></xsd:annotation>
          <xsd:simpleType>
            <xsd:restriction base="xsd:unsignedInt">
              <xsd:minInclusive value="0" />
              <xsd:maxInclusive value="59" />
            </xsd:restriction>
          </xsd:simpleType>
        </xsd:attribute>
      </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>




  <!-- CONFIGURATION -->
  <xsd:complexType name="AgentConfig">
    <xsd:annotation><xsd:documentation xml:lang="en">
        The options defining how the ProActive runtime is
        started.
        Theses options apply to all the events
   	</xsd:documentation></xsd:annotation>
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="proactiveHome" type="xsd:string">
        <xsd:annotation><xsd:documentation xml:lang="en">
            The path to the ProActive Programming or
            ProActive Scheduling
            installation directory      		
        </xsd:documentation></xsd:annotation>
      </xsd:element>
      <xsd:element minOccurs="1" maxOccurs="1" name="javaHome" type="xsd:string">
        <xsd:annotation><xsd:documentation xml:lang="en">
            The path to the Java installation directory
        </xsd:documentation></xsd:annotation>
      </xsd:element>
      <xsd:element minOccurs="0" maxOccurs="1" name="jvmParameters"> 
        <xsd:annotation><xsd:documentation xml:lang="en">
            The list of parameters to be passed to the JVM
        </xsd:documentation></xsd:annotation>
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="unbounded" name="param" type="xsd:string" />
          </xsd:sequence>
       </xsd:complexType>
     </xsd:element>
      
     <xsd:element minOccurs="0" maxOccurs="1" name="memoryManagement">
        <xsd:annotation><xsd:documentation xml:lang="en">
            True is an only if the started ProActive runtimes
            must be memory
            constrained

            Both java and fork process memory can be
            constrained.
            TODO: Add the algorithm 
        </xsd:documentation></xsd:annotation>

        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="0" maxOccurs="1" name="java" type="xsd:positiveInteger"/>
            <xsd:element minOccurs="0" maxOccurs="1" name="native" type="xsd:positiveInteger"/>
          </xsd:sequence>
        
          <xsd:attribute name="enabled" type="xsd:boolean" use="required">
            <xsd:annotation><xsd:documentation>
              Is memory management enabled
             </xsd:documentation></xsd:annotation>
          </xsd:attribute>
        </xsd:complexType>
      </xsd:element>

            
     <xsd:element minOccurs="0" maxOccurs="1" name="nbRuntimes">
        <xsd:annotation><xsd:documentation xml:lang="en">
       
        </xsd:documentation></xsd:annotation>

        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="1" name="count" type="xsd:positiveInteger"/>
          </xsd:sequence>
        
          <xsd:attribute name="auto" type="xsd:boolean" use="optional">
            <xsd:annotation><xsd:documentation>

             </xsd:documentation></xsd:annotation>
          </xsd:attribute>
        </xsd:complexType>
      </xsd:element>
      
      <xsd:element minOccurs="0" maxOccurs="1" name="protocol" type="xsd:string">
        <xsd:annotation>
          <xsd:documentation xml:lang="en">
            The communication protocol to be used by the
            started ProActive
            runtime 		
      		</xsd:documentation>
        </xsd:annotation>
      </xsd:element>

      <xsd:element minOccurs="0" maxOccurs="1" name="initialPortValue" type="xsd:unsignedShort">
        <xsd:annotation>
          <xsd:documentation xml:lang="en">
            TODO
      		</xsd:documentation>
        </xsd:annotation>
      </xsd:element>

      <xsd:element minOccurs="0" maxOccurs="1" name="onRuntimeExitScript" type="xsd:string"> <!-- Fixme: should be on_runtime_exit_script -->
        <xsd:annotation>
          <xsd:documentation xml:lang="en">
            The path to an executable to be started each time
            a forked ProActive
            runtime exits
            It can be used to cleanup some
            ressources, or to gather some results
					</xsd:documentation>
        </xsd:annotation>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>

  <xsd:complexType name="Configuration">
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="config" type="AgentConfig" />
      <xsd:element minOccurs="1" maxOccurs="1" name="events">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="unbounded" name="event" type="CalendarEvent" />
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
      <xsd:element minOccurs="1" maxOccurs="1" name="connections">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="unbounded" ref="Connection" />
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>

  <xsd:element name="agent" type="Configuration" />



  <xsd:simpleType name="javaClassName" >
    <xsd:restriction base="xsd:string">
      <xsd:pattern value="([\w]+\.)*[\w]+"/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="nonEmptyString" >
    <xsd:restriction base="xsd:string">
      <xsd:minLength value="1" />
    </xsd:restriction>
  </xsd:simpleType>

</xsd:schema><commit_msg>Added an optional <config> in <event> to override the default configuration<commit_after>﻿<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema 
  xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  elementFormDefault="qualified">


<!-- 
               /!\   PLEASE DO NOT REFORMAT THIS FILE /!\     
  
     This file is correctly formated and highly readable. Please do not ruin our efforts. Thanks !
 -->





  <!--  Root element -->

  <xsd:element name="agent" type="AgentType">
    <xsd:annotation><xsd:documentation>
    A ProActive Agent configuration file
    </xsd:documentation></xsd:annotation>
  </xsd:element>


  <xsd:complexType name="AgentType">
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="config" type="GlobalAgentConfigType">
        <xsd:annotation><xsd:documentation>
          The global configuration of the ProActive Agent. This configuration can be overriden by each event.
        </xsd:documentation></xsd:annotation>
      </xsd:element>
      <xsd:element minOccurs="1" maxOccurs="1" name="events">
        <xsd:annotation><xsd:documentation>
          A ProActive Agent configuration file
        </xsd:documentation></xsd:annotation>
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="unbounded" name="event" type="CalendarEventType" />
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
      <xsd:element minOccurs="1" maxOccurs="1" name="connections">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="unbounded" ref="Connection" />
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>





  <!-- ACTIONS -->
  
  <xsd:element name="Connection" abstract="true" type="ConnectionType"/>
  <xsd:complexType name="ConnectionType" abstract="true">
    <xsd:annotation><xsd:documentation xml:lang="en">
    The connection to be established when an event begin.
    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
    
      <xsd:element minOccurs="0" maxOccurs="1" name="respawnIncrement" type="xsd:positiveInteger">
        <xsd:annotation><xsd:documentation xml:lang="en">
        Each time a runtime dies, it is automatically restarted by the agent. To avoid system overloading, the agent waits for a given amount of time before restarting the runtime. This delay depends of the number of restart and the respawnincrement
        </xsd:documentation></xsd:annotation>
      </xsd:element>
      
      <xsd:element minOccurs="0" maxOccurs="1" name="javaStarterClass" type="javaClassName">
        <xsd:annotation><xsd:documentation xml:lang="en">
        The java class name to be started by the agent. 
        The element is optional since the agent will automatically starts the class
        corresponding to the Connection if not specified. This element can be used to 
        override the defaut class if needed.
        </xsd:documentation></xsd:annotation>
      </xsd:element>
    
      <xsd:element minOccurs="0" maxOccurs="1" name="nodename" type="nonEmptyString">
        <xsd:annotation><xsd:documentation xml:lang="en">
        The ProActive node name to be started
        </xsd:documentation></xsd:annotation>
      </xsd:element>
    </xsd:sequence>
    
    <xsd:attribute name="enabled" type="xsd:boolean" use="required">
      <xsd:annotation><xsd:documentation xml:lang="en">
      True if this action is enabled. False otherwise
      One and only one action can be enabled.
      </xsd:documentation></xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>


  <xsd:element name="localBind" substitutionGroup="Connection">
    <xsd:complexType>
      <xsd:annotation><xsd:documentation xml:lang="en">
      Starts a ProActive node with a given name.
      It is up to the infrastructure to discover this node by performing a lookup
      </xsd:documentation></xsd:annotation>
      <xsd:complexContent>
        <xsd:extension base="ConnectionType"/>
      </xsd:complexContent>
    </xsd:complexType>
  </xsd:element>


  <xsd:element name="rmConnection" substitutionGroup="Connection">
    <xsd:complexType>
      <xsd:annotation><xsd:documentation xml:lang="en">
      Starts a ProActive node and register to a ProActive Ressource Manager by
      using a callback	
      </xsd:documentation></xsd:annotation>
      <xsd:complexContent mixed="false">
        <xsd:extension base="ConnectionType">
          <xsd:sequence>
            <xsd:element minOccurs="1" maxOccurs="1" name="url" type="nonEmptyString">
              <xsd:annotation><xsd:documentation xml:lang="en">
              The URL of the ProActive Ressource Manager
              </xsd:documentation></xsd:annotation>
            </xsd:element>

            <xsd:element minOccurs="0" maxOccurs="1" name="nodeSourceName" type="nonEmptyString">
              <xsd:annotation><xsd:documentation xml:lang="en">
              The name of the ProActive Ressource Manager node source
              </xsd:documentation></xsd:annotation>
            </xsd:element>

            <xsd:element minOccurs="1" maxOccurs="1" name="credential">
              <xsd:annotation><xsd:documentation xml:lang="en">
              The path of the file containing the credentials to use to connect
              to the ProActive Ressource Manager
              </xsd:documentation></xsd:annotation>
              <xsd:complexType>
                <xsd:sequence>
                  <xsd:element minOccurs="0" maxOccurs="1" name="path" type="nonEmptyString">
                    <xsd:annotation><xsd:documentation xml:lang="en">
                    The patht to the credential to use    
                    </xsd:documentation></xsd:annotation>
                  </xsd:element>
                </xsd:sequence>

                <xsd:attribute  name="usedefault" type="xsd:boolean" use="required">
                  <xsd:annotation><xsd:documentation xml:lang="en">
                  If true, the agent will try to use the credential located at the standard
                  path.
                  </xsd:documentation></xsd:annotation>
                </xsd:attribute>
              </xsd:complexType>
            </xsd:element>
          </xsd:sequence>
        </xsd:extension>
      </xsd:complexContent>
    </xsd:complexType>
  </xsd:element>


  <xsd:element name="customConnection" substitutionGroup="Connection">
  <xsd:complexType>
    <xsd:complexContent>
      <xsd:extension base="ConnectionType">
        <xsd:sequence>
          <xsd:element minOccurs="0" maxOccurs="1" name="args">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element minOccurs="1" maxOccurs="unbounded" name="arg" type="xsd:string">
                  <xsd:annotation><xsd:documentation xml:lang="en">
                      The arguments to be passed to the java class
                  </xsd:documentation></xsd:annotation>
                </xsd:element>
              </xsd:sequence>
            </xsd:complexType>
          </xsd:element>
        </xsd:sequence>
      </xsd:extension>
    </xsd:complexContent>
  </xsd:complexType>
  </xsd:element>





  <!-- EVENTS -->
  
  <xsd:complexType name="CalendarEventType">
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="start">
        <xsd:complexType>
          <xsd:attribute name="day" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The name of the starting day in the week
            (lowercase)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:string">
                <xsd:enumeration value="monday" />
                <xsd:enumeration value="tuesday" />
                <xsd:enumeration value="wednesday" />
                <xsd:enumeration value="thursday" />
                <xsd:enumeration value="friday" />
                <xsd:enumeration value="saturday" />
                <xsd:enumeration value="sunday" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>

          <xsd:attribute name="hour" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The hour of the start, 24 hour format (0 to 23)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="23" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>
   
          <xsd:attribute name="minute"  use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The minute of the start (0 to 59)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="59" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>
        
          <xsd:attribute name="second" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The second of the start (0 to 59)
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="59" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>
        </xsd:complexType>
      </xsd:element>

      <xsd:element minOccurs="1" maxOccurs="1" name="duration">
        <xsd:complexType>
          <xsd:attribute name="days" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The number of days the event lasts (0 to 6).
            Since this is a weekly planning, cannot be greater than 6
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="6" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>

          <xsd:attribute name="hours" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The number of hours the event lasts (0 to 23).
            A number greater than 23 cannot be used to describe an event
            lasting more than one day. The durationDays element must be used.
            </xsd:documentation></xsd:annotation>
            <xsd:simpleType>
              <xsd:restriction base="xsd:unsignedInt">
                <xsd:minInclusive value="0" />
                <xsd:maxInclusive value="23" />
              </xsd:restriction>
            </xsd:simpleType>
          </xsd:attribute>

          <xsd:attribute name="minutes" use="required">
            <xsd:annotation><xsd:documentation xml:lang="en">
            The number of minutes the event last (0 to 59)
            A number greater than 59 cannot be used to describe an event
            lasting more than one hour. The durationDays or durationHours
            elements must be used.
          </xsd:documentation></xsd:annotation>
          <xsd:simpleType>
            <xsd:restriction base="xsd:unsignedInt">
              <xsd:minInclusive value="0" />
              <xsd:maxInclusive value="59" />
            </xsd:restriction>
          </xsd:simpleType>
        </xsd:attribute>

        <xsd:attribute name="seconds" use="required">
          <xsd:annotation><xsd:documentation xml:lang="en">
          The number of seconds the event last (0 to 59)
          A number greater than 59 cannot be used to describe an event
          lasting more than one minute. The durationDays, durationHours or
          durationMinutes elements must be used.
          </xsd:documentation></xsd:annotation>
          <xsd:simpleType>
            <xsd:restriction base="xsd:unsignedInt">
              <xsd:minInclusive value="0" />
              <xsd:maxInclusive value="59" />
            </xsd:restriction>
          </xsd:simpleType>
        </xsd:attribute>
      </xsd:complexType>
      </xsd:element>
      
      <xsd:element minOccurs="0" maxOccurs="1" name="config" type="EventAgentConfigType"/>
    </xsd:sequence>
  </xsd:complexType>




  <!-- CONFIGURATION -->
  
  <xsd:complexType name="GlobalAgentConfigType">
    <xsd:annotation><xsd:documentation xml:lang="en">
        The options defining how the ProActive runtime is
        started.
        Theses options apply to all the events
    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="proactiveHome" type="ConfProactiveHomeType"/>
      <xsd:element minOccurs="1" maxOccurs="1" name="javaHome" type="ConfJavaHomeType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="jvmParameters" type="ConfJvmParametersType"/> 
      <xsd:element minOccurs="0" maxOccurs="1" name="memoryManagement" type="ConfMemoryManagementType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="nbRuntimes" type="ConfNbRuntimesType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="protocol" type="ConfProtocolType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="initialPortValue" type="ConfInitialPortValueType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="onRuntimeExitScript" type="ConfOnRuntimeExitScriptType"/>
    </xsd:sequence>
  </xsd:complexType>


  <xsd:complexType name="EventAgentConfigType">
    <xsd:annotation><xsd:documentation xml:lang="en">
    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
      <xsd:element minOccurs="0" maxOccurs="1" name="proactiveHome" type="ConfProactiveHomeType" />
      <xsd:element minOccurs="0" maxOccurs="1" name="javaHome" type="ConfJavaHomeType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="jvmParameters" type="ConfJvmParametersType"/> 
      <xsd:element minOccurs="0" maxOccurs="1" name="memoryManagement" type="ConfMemoryManagementType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="nbRuntimes" type="ConfNbRuntimesType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="protocol" type="ConfProtocolType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="initialPortValue" type="ConfInitialPortValueType"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="onRuntimeExitScript" type="ConfOnRuntimeExitScriptType"/>
    </xsd:sequence>
  </xsd:complexType>


  <xsd:simpleType name="ConfProactiveHomeType">
    <xsd:annotation><xsd:documentation xml:lang="en">
    The path to the ProActive Programming or ProActive Scheduling installation directory          
    </xsd:documentation></xsd:annotation>
    <xsd:list itemType="nonEmptyString"/>
  </xsd:simpleType>

  <xsd:simpleType name="ConfJavaHomeType">
    <xsd:annotation><xsd:documentation xml:lang="en">
    The path to the Java installation directory
    </xsd:documentation></xsd:annotation>
    <xsd:list  itemType="nonEmptyString"/>
  </xsd:simpleType>
      
  <xsd:complexType name="ConfJvmParametersType"> 
    <xsd:annotation><xsd:documentation xml:lang="en">
    The list of parameters to be passed to the JVM
    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="unbounded" name="param" type="xsd:string" />
    </xsd:sequence>
  </xsd:complexType>
      
  <xsd:complexType name="ConfMemoryManagementType">
    <xsd:annotation><xsd:documentation xml:lang="en">
    True is an only if the started ProActive runtimes must be memory constrained. Both java and fork process memory can be constrained.
    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
      <xsd:element minOccurs="0" maxOccurs="1" name="java" type="xsd:positiveInteger"/>
      <xsd:element minOccurs="0" maxOccurs="1" name="native" type="xsd:positiveInteger"/>
    </xsd:sequence>
    <xsd:attribute name="enabled" type="xsd:boolean" use="required">
      <xsd:annotation><xsd:documentation>
      Is memory management enabled
      </xsd:documentation></xsd:annotation>
   </xsd:attribute>
  </xsd:complexType>

  <xsd:complexType name="ConfNbRuntimesType">
    <xsd:annotation><xsd:documentation xml:lang="en">

    </xsd:documentation></xsd:annotation>
    <xsd:sequence>
      <xsd:element minOccurs="1" maxOccurs="1" name="count" type="xsd:positiveInteger"/>
    </xsd:sequence>
    <xsd:attribute name="auto" type="xsd:boolean" use="optional">
      <xsd:annotation><xsd:documentation>

      </xsd:documentation></xsd:annotation>
    </xsd:attribute>
  </xsd:complexType>
      
  <xsd:simpleType name="ConfProtocolType">
    <xsd:annotation><xsd:documentation xml:lang="en">
    The communication protocol to be used by the started ProActive runtime     
    </xsd:documentation></xsd:annotation>
    <xsd:list itemType="nonEmptyString"/>
  </xsd:simpleType>

  <xsd:simpleType name="ConfInitialPortValueType">
    <xsd:annotation><xsd:documentation xml:lang="en">

    </xsd:documentation></xsd:annotation>
    <xsd:list itemType="xsd:unsignedShort"/>
  </xsd:simpleType>

  <xsd:simpleType name="ConfOnRuntimeExitScriptType"> 
    <xsd:annotation><xsd:documentation xml:lang="en">
    The path to an executable to be started each time a forked ProActive runtime exits. It can be used to cleanup some ressources, or to gather some results
    </xsd:documentation></xsd:annotation>
    <xsd:list itemType="nonEmptyString"/>
  </xsd:simpleType>





  <xsd:simpleType name="javaClassName" >
    <xsd:restriction base="xsd:string">
      <xsd:pattern value="([\w]+\.)*[\w]+"/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="nonEmptyString">
    <xsd:restriction base="xsd:string">
      <xsd:minLength value="1" />
      <xsd:pattern value=".*[^\s].*" />
    </xsd:restriction>
  </xsd:simpleType>

</xsd:schema>
{'fraction_non_alphanumeric': 0.1293419854949056, 'fraction_numerical': 0.006988284346830314, 'mean_word_length': 2.6032585696148964, 'pattern_counts': {'":': 0, '<': 741, '<?xml version=': 2, '>': 741, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 65}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5355754', 'n_tokens_mistral': 10419, 'n_tokens_neox': 9160, 'n_words': 2140}