<commit_before><?xml version="1.0" encoding="UTF-8" standalone="no"?>

<xsd:schema xmlns="http://www.openspaces.org/schema/core/gateway" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
            xmlns:beans="http://www.springframework.org/schema/beans"
            xmlns:tool="http://www.springframework.org/schema/tool"
            xmlns:os-core="http://www.openspaces.org/schema/core"
            targetNamespace="http://www.openspaces.org/schema/core/gateway"
            elementFormDefault="qualified" attributeFormDefault="unqualified">

    <xsd:import namespace="http://www.springframework.org/schema/beans"/>
    <xsd:import namespace="http://www.springframework.org/schema/tool"/>
    <xsd:import namespace="http://www.openspaces.org/schema/core"/>

    <xsd:element name="delegator">
		<xsd:complexType>
            <xsd:complexContent>
            <xsd:extension base="beans:identifiedType">
		    <xsd:sequence>
		      <xsd:element name="delegation" minOccurs="1" maxOccurs="unbounded">
				<xsd:complexType>
				<xsd:attribute name="target" type="xsd:string" use="required" />
				<xsd:attribute name="delegate-through" type="xsd:string" use="optional" />
				</xsd:complexType>
		      </xsd:element>
		    </xsd:sequence>
				<xsd:attribute name="local-gateway-name" type="xsd:string" use="required" />
				<xsd:attribute name="gateway-lookups" type="gatewayLookupsRefType" use="required" />
				<xsd:attribute name="start-embedded-lus" type="xsd:boolean" default="true" use="optional" />
				<xsd:attribute name="relocate-if-wrong-ports" type="xsd:boolean" default="true" use="optional" />
				<xsd:attribute name="custom-jvm-properties" type="xsd:string" use="optional" />
          </xsd:extension>
          </xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:element name="targets">
		<xsd:complexType>
            <xsd:complexContent>
            <xsd:extension base="beans:identifiedType">
		    <xsd:sequence>
		      <xsd:element name="target" minOccurs="1" maxOccurs="unbounded">
				<xsd:complexType>
				<xsd:attribute name="name" type="xsd:string" use="required" />
				<xsd:attribute name="bulk-size" type="xsd:string" />
				<xsd:attribute name="idle-time-threshold" type="xsd:string" />
				<xsd:attribute name="pending-operation-threshold" type="xsd:string" />
				<xsd:attribute name="max-redo-log-capacity" type="xsd:string" />
				<xsd:attribute name="on-redo-log-capacity-exceeded" type="xsd:string" />
				</xsd:complexType>
		      </xsd:element>
		    </xsd:sequence>
			<xsd:attribute name="local-gateway-name" type="xsd:string" use="required" />
			<xsd:attribute name="bulk-size" type="xsd:string" />
			<xsd:attribute name="idle-time-threshold" type="xsd:string" />
			<xsd:attribute name="pending-operation-threshold" type="xsd:string" />
			<xsd:attribute name="max-redo-log-capacity" type="xsd:string" />
			<xsd:attribute name="on-redo-log-capacity-exceeded">
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:enumeration value="block-operations" />
						<xsd:enumeration value="drop-oldest" />
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:attribute>
          </xsd:extension>
          </xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:element name="lookups">
		<xsd:complexType>
            <xsd:complexContent>
            <xsd:extension base="beans:identifiedType">
		    <xsd:sequence>
		      <xsd:element name="lookup" minOccurs="0" maxOccurs="unbounded">
				<xsd:complexType>
				<xsd:attribute name="gateway-name" type="xsd:string" use="required" />
				<xsd:attribute name="host" type="xsd:string" use="required" />
				<xsd:attribute name="discovery-port" type="xsd:string" use="required" />
				<xsd:attribute name="communication-port" type="xsd:string" use="optional" />
				</xsd:complexType>
		      </xsd:element>
		    </xsd:sequence>
			<xsd:attribute name="lookup-group" type="xsd:string" use="optional" />
          </xsd:extension>
          </xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:element name="sink">   
		<xsd:complexType>
    	    <xsd:complexContent>
        	<xsd:extension base="beans:identifiedType">
        	<xsd:sequence>
			    <xsd:element name="sources">
					<xsd:complexType>
			            <xsd:complexContent>
			            <xsd:extension base="beans:identifiedType">
					    <xsd:sequence>
					      <xsd:element name="source" minOccurs="1" maxOccurs="unbounded">
							<xsd:complexType>
							<xsd:attribute name="name" type="xsd:string" use="required" />
							</xsd:complexType>
					      </xsd:element>
					    </xsd:sequence>
			          </xsd:extension>
			          </xsd:complexContent>
					</xsd:complexType>
			    </xsd:element>
			    <xsd:element name="error-handling" minOccurs="0" maxOccurs="1">
			    	<xsd:complexType>
				    	<xsd:attribute name="conflict-resolver" type="conflictResolverRefType" use="optional" />
				    	<xsd:attribute name="max-retries-on-tx-lock" type="xsd:string" use="optional" />
				    	<xsd:attribute name="tx-lock-retry-interval" type="xsd:string" use="optional" />
			    	</xsd:complexType>
			    </xsd:element>
   	    	</xsd:sequence>
			<xsd:attribute name="local-gateway-name" type="xsd:string" use="required" />
			<xsd:attribute name="gateway-lookups" type="gatewayLookupsRefType" use="required" />
			<xsd:attribute name="local-space-url" type="xsd:string" use="required" />
			<xsd:attribute name="start-embedded-lus" type="xsd:boolean" default="true" />
			<xsd:attribute name="relocate-if-wrong-ports" type="xsd:boolean" default="true" use="optional" />
			<xsd:attribute name="requires-bootstrap" type="xsd:boolean" default="false" use="optional" />
			<xsd:attribute name="custom-jvm-properties" type="xsd:string" use="optional" />
    	   	</xsd:extension>
    	   	</xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:simpleType name="gatewayLookupsRefType">
        <xsd:annotation>
            <xsd:appinfo>
                <tool:annotation kind="ref">
                    <tool:expected-type type="org.openspaces.core.gateway.GatewayLookupsFactoryBean" />
                </tool:annotation>
            </xsd:appinfo>
        </xsd:annotation>
        <xsd:union memberTypes="xsd:string"/>
	</xsd:simpleType>
	    <xsd:simpleType name="conflictResolverRefType">
        <xsd:annotation>
            <xsd:appinfo><commit_msg>GS-8831 Added tx-timeout & lookup-timeout attributes to Sink element.<commit_after><?xml version="1.0" encoding="UTF-8" standalone="no"?>

<xsd:schema xmlns="http://www.openspaces.org/schema/core/gateway" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
            xmlns:beans="http://www.springframework.org/schema/beans"
            xmlns:tool="http://www.springframework.org/schema/tool"
            xmlns:os-core="http://www.openspaces.org/schema/core"
            targetNamespace="http://www.openspaces.org/schema/core/gateway"
            elementFormDefault="qualified" attributeFormDefault="unqualified">

    <xsd:import namespace="http://www.springframework.org/schema/beans"/>
    <xsd:import namespace="http://www.springframework.org/schema/tool"/>
    <xsd:import namespace="http://www.openspaces.org/schema/core"/>

    <xsd:element name="delegator">
		<xsd:complexType>
            <xsd:complexContent>
            <xsd:extension base="beans:identifiedType">
		    <xsd:sequence>
		      <xsd:element name="delegation" minOccurs="1" maxOccurs="unbounded">
				<xsd:complexType>
				<xsd:attribute name="target" type="xsd:string" use="required" />
				<xsd:attribute name="delegate-through" type="xsd:string" use="optional" />
				</xsd:complexType>
		      </xsd:element>
		    </xsd:sequence>
				<xsd:attribute name="local-gateway-name" type="xsd:string" use="required" />
				<xsd:attribute name="gateway-lookups" type="gatewayLookupsRefType" use="required" />
				<xsd:attribute name="start-embedded-lus" type="xsd:boolean" default="true" use="optional" />
				<xsd:attribute name="relocate-if-wrong-ports" type="xsd:boolean" default="true" use="optional" />
				<xsd:attribute name="custom-jvm-properties" type="xsd:string" use="optional" />
          </xsd:extension>
          </xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:element name="targets">
		<xsd:complexType>
            <xsd:complexContent>
            <xsd:extension base="beans:identifiedType">
		    <xsd:sequence>
		      <xsd:element name="target" minOccurs="1" maxOccurs="unbounded">
				<xsd:complexType>
				<xsd:attribute name="name" type="xsd:string" use="required" />
				<xsd:attribute name="bulk-size" type="xsd:string" />
				<xsd:attribute name="idle-time-threshold" type="xsd:string" />
				<xsd:attribute name="pending-operation-threshold" type="xsd:string" />
				<xsd:attribute name="max-redo-log-capacity" type="xsd:string" />
				<xsd:attribute name="on-redo-log-capacity-exceeded" type="xsd:string" />
				</xsd:complexType>
		      </xsd:element>
		    </xsd:sequence>
			<xsd:attribute name="local-gateway-name" type="xsd:string" use="required" />
			<xsd:attribute name="bulk-size" type="xsd:string" />
			<xsd:attribute name="idle-time-threshold" type="xsd:string" />
			<xsd:attribute name="pending-operation-threshold" type="xsd:string" />
			<xsd:attribute name="max-redo-log-capacity" type="xsd:string" />
			<xsd:attribute name="on-redo-log-capacity-exceeded">
				<xsd:simpleType>
					<xsd:restriction base="xsd:string">
						<xsd:enumeration value="block-operations" />
						<xsd:enumeration value="drop-oldest" />
					</xsd:restriction>
				</xsd:simpleType>
			</xsd:attribute>
          </xsd:extension>
          </xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:element name="lookups">
		<xsd:complexType>
            <xsd:complexContent>
            <xsd:extension base="beans:identifiedType">
		    <xsd:sequence>
		      <xsd:element name="lookup" minOccurs="0" maxOccurs="unbounded">
				<xsd:complexType>
				<xsd:attribute name="gateway-name" type="xsd:string" use="required" />
				<xsd:attribute name="host" type="xsd:string" use="required" />
				<xsd:attribute name="discovery-port" type="xsd:string" use="required" />
				<xsd:attribute name="communication-port" type="xsd:string" use="optional" />
				</xsd:complexType>
		      </xsd:element>
		    </xsd:sequence>
			<xsd:attribute name="lookup-group" type="xsd:string" use="optional" />
          </xsd:extension>
          </xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:element name="sink">   
		<xsd:complexType>
    	    <xsd:complexContent>
        	<xsd:extension base="beans:identifiedType">
        	<xsd:sequence>
			    <xsd:element name="sources">
					<xsd:complexType>
			            <xsd:complexContent>
			            <xsd:extension base="beans:identifiedType">
					    <xsd:sequence>
					      <xsd:element name="source" minOccurs="1" maxOccurs="unbounded">
							<xsd:complexType>
							<xsd:attribute name="name" type="xsd:string" use="required" />
							</xsd:complexType>
					      </xsd:element>
					    </xsd:sequence>
			          </xsd:extension>
			          </xsd:complexContent>
					</xsd:complexType>
			    </xsd:element>
			    <xsd:element name="error-handling" minOccurs="0" maxOccurs="1">
			    	<xsd:complexType>
				    	<xsd:attribute name="conflict-resolver" type="conflictResolverRefType" use="optional" />
				    	<xsd:attribute name="max-retries-on-tx-lock" type="xsd:string" use="optional" />
				    	<xsd:attribute name="tx-lock-retry-interval" type="xsd:string" use="optional" />
			    	</xsd:complexType>
			    </xsd:element>
   	    	</xsd:sequence>
			<xsd:attribute name="local-gateway-name" type="xsd:string" use="required" />
			<xsd:attribute name="gateway-lookups" type="gatewayLookupsRefType" use="required" />
			<xsd:attribute name="local-space-url" type="xsd:string" use="required" />
			<xsd:attribute name="start-embedded-lus" type="xsd:boolean" default="true" />
			<xsd:attribute name="relocate-if-wrong-ports" type="xsd:boolean" default="true" use="optional" />
			<xsd:attribute name="requires-bootstrap" type="xsd:boolean" default="false" use="optional" />
			<xsd:attribute name="custom-jvm-properties" type="xsd:string" use="optional" />
			<xsd:attribute name="tx-timeout" type="xsd:string" use="optional" />
			<xsd:attribute name="lookup-timeout" type="xsd:string" use="optional" />
    	   	</xsd:extension>
    	   	</xsd:complexContent>
		</xsd:complexType>
    </xsd:element>
    <xsd:simpleType name="gatewayLookupsRefType">
        <xsd:annotation>
            <xsd:appinfo>
                <tool:annotation kind="ref">
                    <tool:expected-type type="org.openspaces.core.gateway.GatewayLookupsFactoryBean" />
                </tool:annotation>
            </xsd:appinfo>
        </xsd:annotation>
        <xsd:union memberTypes="xsd:string"/>
	</xsd:simpleType>
	    <xsd:simpleType name="conflictResolverRefType">
        <xsd:annotation>
            <xsd:appinfo>
{'fraction_non_alphanumeric': 0.17024704618689582, 'fraction_numerical': 0.0024551173852999848, 'mean_word_length': 3.556099265990912, 'pattern_counts': {'":': 0, '<': 265, '<?xml version=': 2, '>': 265, 'https://': 0, 'lorem ipsum': 0, 'www.': 18, 'xml': 12}, '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': '6001350', 'n_tokens_mistral': 4897, 'n_tokens_neox': 4011, 'n_words': 564}