Changing to XMlBeans as discussed in - AIRAVATA-656
authorSuresh Marru <smarru@apache.org>
Sun, 21 Apr 2013 12:31:22 +0000 (12:31 +0000)
committerSuresh Marru <smarru@apache.org>
Sun, 21 Apr 2013 12:31:22 +0000 (12:31 +0000)
git-svn-id: https://svn.apache.org/repos/asf/airavata/sandbox@1470292 13f79535-47bb-0310-9956-ffa450edef68

grid-tools/jsdl-generator/pom.xml
grid-tools/jsdl-generator/src/main/java/org/apache/airavata/gridtools/jsdl/GenerateJSDLExample.java
grid-tools/jsdl-generator/src/main/resources/jsdl-hpcpa.xsd [new file with mode: 0644]
grid-tools/jsdl-generator/src/main/resources/jsdl-schemas.xsdconfig [new file with mode: 0644]
grid-tools/jsdl-generator/src/main/resources/jsdl-spmd.xsd [new file with mode: 0644]

index fa47df0..e8db18f 100644 (file)
@@ -1,15 +1,12 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
-<!--Licensed to the Apache Software Foundation (ASF) under one or more contributor 
-       license agreements. See the NOTICE file distributed with this work for additional 
-       information regarding copyright ownership. The ASF licenses this file to 
-       you under the Apache License, Version 2.0 (theÏ "License"); you may not use 
-       this file except in compliance with the License. You may obtain a copy of 
-       the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required 
-       by applicable law or agreed to in writing, software distributed under the 
-       License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 
-       OF ANY ~ KIND, either express or implied. See the License for the specific 
-       language governing permissions and limitations under the License. -->
+<!--Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file 
+       distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under 
+       the Apache License, Version 2.0 (theÏ "License"); you may not use this file except in compliance with the License. You may 
+       obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to 
+       in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF 
+       ANY ~ KIND, either express or implied. See the License for the specific language governing permissions and limitations under 
+       the License. -->
 
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
        <packaging>jar</packaging>
        <url>http://airavata.apache.org/</url>
 
+       <properties>
+               <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+               <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
+               <org.slf4j.version>1.7.2</org.slf4j.version>
+               <axiom.version>1.2.8</axiom.version>
+               <surefire.version>2.12</surefire.version>
+               <junit.version>4.7</junit.version>
+               <xmlbeans.version>2.5.0</xmlbeans.version>
+               <xpp3.version>1.1.3_7</xpp3.version>
+               <skipTests>false</skipTests>
+       </properties>
+
        <dependencies>
 
                <dependency>
-                       <groupId>javax.xml.bind</groupId>
-                       <artifactId>jaxb-api</artifactId>
-                       <version>2.2.7</version>
+                       <groupId>org.apache.xmlbeans</groupId>
+                       <artifactId>xmlbeans</artifactId>
+                       <version>${xmlbeans.version}</version>
+               </dependency>
+
+               <dependency>
+                       <groupId>wsdl4j</groupId>
+                       <artifactId>wsdl4j</artifactId>
+                       <version>1.6.2</version>
+               </dependency>
+
+               <dependency>
+                       <groupId>xpp3</groupId>
+                       <artifactId>xpp3</artifactId>
+                       <version>1.1.4c</version>
                </dependency>
 
                <dependency>
-                       <groupId>com.sun.xml.bind</groupId>
-                       <artifactId>jaxb-impl</artifactId>
-                       <version>2.2.7-b41</version>
+                       <groupId>org.slf4j</groupId>
+                       <artifactId>slf4j-api</artifactId>
+                       <version>${org.slf4j.version}</version>
                </dependency>
 
+               <!-- Testing -->
                <dependency>
-                       <groupId>com.sun.xml.bind</groupId>
-                       <artifactId>jaxb-xjc</artifactId>
-                       <version>2.2.7-b41</version>
+                       <groupId>junit</groupId>
+                       <artifactId>junit</artifactId>
+                       <version>${junit.version}</version>
+                       <scope>test</scope>
                </dependency>
 
+               <dependency>
+                       <groupId>org.slf4j</groupId>
+                       <artifactId>jcl-over-slf4j</artifactId>
+                       <version>${org.slf4j.version}</version>
+                       <scope>test</scope>
+               </dependency>
+
+               <dependency>
+                       <groupId>org.slf4j</groupId>
+                       <artifactId>slf4j-log4j12</artifactId>
+                       <version>${org.slf4j.version}</version>
+                       <scope>test</scope>
+               </dependency>
+
+
        </dependencies>
 
-       <build>
-               <plugins>
-                       <plugin>
-                               <groupId>org.apache.maven.plugins</groupId>
-                               <artifactId>maven-compiler-plugin</artifactId>
-                               <version>3.0</version>
-                       </plugin>
-                       <plugin>
-                               <groupId>org.codehaus.mojo</groupId>
-                               <artifactId>jaxb2-maven-plugin</artifactId>
-                               <version>1.5</version>
-                               <executions>
-                                       <execution>
-                                               <id>jsdl-schemas</id>
-                                               <goals>
-                                                       <goal>xjc</goal>
-                                               </goals>
-                                       </execution>
-                               </executions>
-                               <configuration>
-                                       <schemaDirectory>src/main/resources</schemaDirectory>
-                                       <packageName>org.ogf.jsdl</packageName>
-                               </configuration>
-                       </plugin>
-               </plugins>
-       </build>
+   <build>
+        <plugins>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>build-helper-maven-plugin</artifactId>
+                <version>1.7</version>
+                <executions>
+                    <execution>
+                        <id>add-source</id>
+                        <phase>generate-sources</phase>
+                        <goals>
+                            <goal>add-source</goal>
+                        </goals>
+                        <configuration>
+                            <sources>
+                                <source>${basedir}/target/generated-sources/xmlbeans</source>
+                            </sources>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>xmlbeans-maven-plugin</artifactId>
+                <version>2.3.3</version>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>xmlbeans</goal>
+                        </goals>
+                    </execution>
+                </executions>
+                <inherited>true</inherited>
+                <configuration>
+                    <schemaDirectory>src/main/resources</schemaDirectory>
+                    <xmlConfigs>
+                        <xmlConfig implementation="java.io.File">src/main/resources/jsdl-schemas.xsdconfig</xmlConfig>
+                    </xmlConfigs>
+                    <outputJar>target/generated/${project.artifactId}-${project.version}.jar</outputJar>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
 
 </project>
index b00bed5..3f85530 100644 (file)
@@ -23,18 +23,14 @@ package org.apache.airavata.gridtools.jsdl;
 
 import java.io.StringWriter;
 
-import javax.xml.bind.JAXBContext;
-import javax.xml.bind.JAXBElement;
-import javax.xml.bind.JAXBException;
-import javax.xml.bind.Marshaller;
-
-import org.ogf.jsdl.ApplicationType;
-import org.ogf.jsdl.FileNameType;
-import org.ogf.jsdl.JobDefinitionType;
-import org.ogf.jsdl.JobDescriptionType;
-import org.ogf.jsdl.JobIdentificationType;
-import org.ogf.jsdl.ObjectFactory;
-import org.ogf.jsdl.POSIXApplicationType;
+import org.apache.xmlbeans.ObjectFactory;
+import org.ogf.schemas.jsdl.ApplicationType;
+import org.ogf.schemas.jsdl.JobDefinitionDocument;
+import org.ogf.schemas.jsdl.JobDefinitionType;
+import org.ogf.schemas.jsdl.JobDescriptionType;
+import org.ogf.schemas.jsdl.JobIdentificationType;
+import org.ogf.schemas.jsdl.posix.FileNameType;
+import org.ogf.schemas.jsdl.posix.POSIXApplicationType;
 
 public class GenerateJSDLExample {
 
@@ -43,45 +39,50 @@ public class GenerateJSDLExample {
      */
     public static void main(String[] args) {
 
-        try {
-
-            ObjectFactory jsdlObjFact = new ObjectFactory();
-            JobDefinitionType jsdlJobDefType = jsdlObjFact.createJobDefinitionType();
-            JobDescriptionType jsdlJobDescType = jsdlObjFact.createJobDescriptionType();
-            
-            
-            JobIdentificationType jsdlJobIdenType = jsdlObjFact.createJobIdentificationType();
-            jsdlJobIdenType.setJobName("Airavata Test");
-            jsdlJobIdenType.setDescription("Airavata JSDL Test Job");
-            jsdlJobDescType.setJobIdentification(jsdlJobIdenType);
-            
-            POSIXApplicationType jsdlPosixAppType = jsdlObjFact.createPOSIXApplicationType();
-            FileNameType execFileType = jsdlObjFact.createFileNameType();
-            execFileType.setValue("/bin/date");
-            jsdlPosixAppType.setExecutable(execFileType);
-            JAXBElement<POSIXApplicationType> jsdlPosixApp = jsdlObjFact.createPOSIXApplication(jsdlPosixAppType);
-            
-            ApplicationType jsdlAppType = jsdlObjFact.createApplicationType();
-            jsdlAppType.setApplicationName("Test Date");
-            jsdlAppType.setApplicationVersion("v1.0");
-            jsdlAppType.setDescription("Testing Date");
-            jsdlAppType.getAny().add(jsdlPosixApp);
-            jsdlJobDescType.setApplication(jsdlAppType);          
-            
-            jsdlJobDefType.setJobDescription(jsdlJobDescType);
-            JAXBElement<JobDefinitionType> jsdlJobDef = jsdlObjFact.createJobDefinition(jsdlJobDefType);
-
-            //generate the required jsdl
-            JAXBContext jaxbContext = JAXBContext.newInstance(new Class[] { JobDefinitionType.class });
-            StringWriter jsdlXMLString = new StringWriter();
-            Marshaller jaxbMarshaller = jaxbContext.createMarshaller();
-            jaxbMarshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, true);
-            jaxbMarshaller.marshal(jsdlJobDef, jsdlXMLString);
-            System.out.println(jsdlXMLString.toString());
-         
-        } catch (JAXBException e) {
-            e.printStackTrace();
-        }
+//        try {
+//
+//            JobDefinitionDocument jobDefDoc = JobDefinitionDocument.Factory
+//                    .newInstance();
+//            JobDefinitionType jobDef = jobDefDoc.addNewJobDefinition();
+//            
+//            jobDef.addNewJobDescription().addNewResources() addNewJobDescription();
+//            
+//            ObjectFactory jsdlObjFact = new ObjectFactory();
+//            JobDefinitionType jsdlJobDefType = jsdlObjFact.createJobDefinitionType();
+//            JobDescriptionType jsdlJobDescType = jsdlObjFact.createJobDescriptionType();
+//                   
+//            JobIdentificationType jsdlJobIdenType = jsdlObjFact.createJobIdentificationType();
+//            jsdlJobIdenType.setJobName("Airavata Test");
+//            jsdlJobIdenType.setDescription("Airavata JSDL Test Job");
+//            jsdlJobDescType.setJobIdentification(jsdlJobIdenType);
+//            
+//            POSIXApplicationType jsdlPosixAppType = jsdlObjFact.createPOSIXApplicationType();
+//            FileNameType execFileType = jsdlObjFact.
+//            execFileType.setValue("/bin/date");
+//            jsdlPosixAppType.setExecutable(execFileType);
+//            JAXBElement<POSIXApplicationType> jsdlPosixApp = jsdlObjFact.createPOSIXApplication(jsdlPosixAppType);
+//            
+//            ApplicationType jsdlAppType = jsdlObjFact.createApplicationType();
+//            jsdlAppType.setApplicationName("Test Date");
+//            jsdlAppType.setApplicationVersion("v1.0");
+//            jsdlAppType.setDescription("Testing Date");
+//            jsdlAppType.getAny().add(jsdlPosixApp);
+//            jsdlJobDescType.setApplication(jsdlAppType);          
+//            
+//            jsdlJobDefType.setJobDescription(jsdlJobDescType);
+//            JAXBElement<JobDefinitionType> jsdlJobDef = jsdlObjFact.createJobDefinition(jsdlJobDefType);
+//
+//            //generate the required jsdl
+//            JAXBContext jaxbContext = JAXBContext.newInstance(new Class[] { JobDefinitionType.class });
+//            StringWriter jsdlXMLString = new StringWriter();
+//            Marshaller jaxbMarshaller = jaxbContext.createMarshaller();
+//            jaxbMarshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, true);
+//            jaxbMarshaller.marshal(jsdlJobDef, jsdlXMLString);
+//            System.out.println(jsdlXMLString.toString());
+//         
+//        } catch (JAXBException e) {
+//            e.printStackTrace();
+//        }
 
     }
 
diff --git a/grid-tools/jsdl-generator/src/main/resources/jsdl-hpcpa.xsd b/grid-tools/jsdl-generator/src/main/resources/jsdl-hpcpa.xsd
new file mode 100644 (file)
index 0000000..60bb133
--- /dev/null
@@ -0,0 +1,107 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+       The OGF takes no position regarding the validity or scope of any intellectual property or 
+       other rights that might be claimed to pertain to the implementation or use of the technology 
+       described in this document or the extent to which any license under such rights might or 
+       might not be available; neither does it represent that it has made any effort to identify 
+       any such rights.  Copies of claims of rights made available for publication and any 
+       assurances of licenses to be made available, or the result of an attempt made to obtain a 
+       general license or permission for the use of such proprietary rights by implementers or users 
+       of this specification can be obtained from the OGF Secretariat.
+       
+       The OGF invites any interested party to bring to its attention any copyrights, patents or 
+       patent applications, or other proprietary rights which may cover technology that may be 
+       required to practice this recommendation.  Please address the information to the OGF 
+       Executive Director.
+       
+       This document and the information contained herein is provided on an "As Is" basis and the 
+       OGF disclaims all warranties, express or implied, including but not limited to any warranty 
+       that the use of the information herein will not infringe any rights or any implied warranties 
+       of merchantability or fitness for a particular purpose.
+       
+       Copyright (C) Open Grid Forum (2006). All Rights Reserved. 
+       
+       This document and translations of it may be copied and furnished to others, and derivative 
+       works that comment on or otherwise explain it or assist in its implementation may be prepared, 
+       copied, published and distributed, in whole or in part, without restriction of any kind, 
+       provided that the above copyright notice and this paragraph are included on all such copies 
+       and derivative works. However, this document itself may not be modified in any way, such as 
+       by removing the copyright notice or references to the OGF or other organizations, except as 
+       needed for the purpose of developing Grid Recommendations in which case the procedures for 
+       copyrights defined in the OGF Document process must be followed, or as required to translate 
+       it into languages other than English. 
+       
+       The limited permissions granted above are perpetual and will not be revoked by the OGF or its 
+       successors or assignees.
+-->
+<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
+       xmlns="http://schemas.ggf.org/jsdl/2006/07/jsdl-hpcpa" 
+       xmlns:jsdl-hpcpa="http://schemas.ggf.org/jsdl/2006/07/jsdl-hpcpa" 
+       targetNamespace="http://schemas.ggf.org/jsdl/2006/07/jsdl-hpcpa" elementFormDefault="qualified">
+       <!--========================================================================-->
+       <xsd:complexType name="Environment_Type">
+               <xsd:simpleContent>
+                       <xsd:extension base="xsd:string">
+                               <xsd:attribute name="name" type="xsd:NCName" use="required"/>
+                               <xsd:anyAttribute namespace="##other" processContents="lax"/>
+                       </xsd:extension>
+               </xsd:simpleContent>
+       </xsd:complexType>
+       <!--========================================================================-->
+       <xsd:complexType name="Argument_Type">
+               <xsd:simpleContent>
+                       <xsd:extension base="xsd:string">
+                               <xsd:anyAttribute namespace="##other" processContents="lax"/>
+                       </xsd:extension>
+               </xsd:simpleContent>
+       </xsd:complexType>
+       <!--========================================================================-->
+       <xsd:complexType name="FileName_Type">
+               <xsd:simpleContent>
+                       <xsd:extension base="xsd:string">
+                               <xsd:anyAttribute namespace="##other" processContents="lax"/>
+                       </xsd:extension>
+               </xsd:simpleContent>
+       </xsd:complexType>
+       <!--========================================================================-->
+       <xsd:complexType name="DirectoryName_Type">
+               <xsd:simpleContent>
+                       <xsd:extension base="xsd:string">
+                               <xsd:anyAttribute namespace="##other" processContents="lax"/>
+                       </xsd:extension>
+               </xsd:simpleContent>
+       </xsd:complexType>
+       <!--========================================================================-->
+       <xsd:complexType name="UserName_Type">
+               <xsd:simpleContent>
+                       <xsd:extension base="xsd:string">
+                               <xsd:anyAttribute namespace="##other" processContents="lax"/>
+                       </xsd:extension>
+               </xsd:simpleContent>
+       </xsd:complexType>
+       <!--========================================================================-->
+       <xsd:complexType name="HPCProfileApplication_Type">
+               <xsd:sequence>
+                       <xsd:element ref="jsdl-hpcpa:Executable" minOccurs="0"/>
+                       <xsd:element ref="jsdl-hpcpa:Argument" minOccurs="0" maxOccurs="unbounded"/>
+                       <xsd:element ref="jsdl-hpcpa:Input" minOccurs="0"/>
+                       <xsd:element ref="jsdl-hpcpa:Output" minOccurs="0"/>
+                       <xsd:element ref="jsdl-hpcpa:Error" minOccurs="0"/>
+                       <xsd:element ref="jsdl-hpcpa:WorkingDirectory" minOccurs="0"/>
+                       <xsd:element ref="jsdl-hpcpa:Environment" minOccurs="0" maxOccurs="unbounded"/>
+                       <xsd:element ref="jsdl-hpcpa:UserName" minOccurs="0"/>
+               </xsd:sequence>
+               <xsd:attribute name="name" type="xsd:NCName" use="optional"/>
+               <xsd:anyAttribute namespace="##other" processContents="lax"/>
+       </xsd:complexType>
+       <!--========================================================================-->
+       <xsd:element name="HPCProfileApplication" type="jsdl-hpcpa:HPCProfileApplication_Type"/>
+       <xsd:element name="Executable" type="jsdl-hpcpa:FileName_Type"/>
+       <xsd:element name="Argument" type="jsdl-hpcpa:Argument_Type"/>
+       <xsd:element name="Input" type="jsdl-hpcpa:FileName_Type"/>
+       <xsd:element name="Output" type="jsdl-hpcpa:FileName_Type"/>
+       <xsd:element name="Error" type="jsdl-hpcpa:FileName_Type"/>
+       <xsd:element name="WorkingDirectory" type="jsdl-hpcpa:DirectoryName_Type"/>
+       <xsd:element name="Environment" type="jsdl-hpcpa:Environment_Type"/>
+       <xsd:element name="UserName" type="jsdl-hpcpa:UserName_Type"/>
+</xsd:schema>
diff --git a/grid-tools/jsdl-generator/src/main/resources/jsdl-schemas.xsdconfig b/grid-tools/jsdl-generator/src/main/resources/jsdl-schemas.xsdconfig
new file mode 100644 (file)
index 0000000..860ed0e
--- /dev/null
@@ -0,0 +1,27 @@
+<!--Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file 
+       distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under 
+       the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may 
+       obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to 
+       in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF 
+       ANY ~ KIND, either express or implied. See the License for the specific language governing permissions and limitations under 
+       the License. -->
+       
+<xb:config  xmlns:xb="http://www.bea.com/2002/09/xbean/config">
+    
+    <xb:namespace uri="http://schemas.ggf.org/jsdl/2005/11/jsdl">
+        <xb:package>org.ogf.schemas.jsdl</xb:package>
+    </xb:namespace>
+    
+    <xb:namespace uri="http://schemas.ggf.org/jsdl/2005/11/jsdl-posix">
+        <xb:package>org.ogf.schemas.jsdl.posix</xb:package>
+    </xb:namespace>
+    
+    <xb:namespace uri="http://schemas.ogf.org/jsdl/2007/02/jsdl-spmd">
+        <xb:package>org.ogf.schemas.jsdl.spmd</xb:package>
+    </xb:namespace>
+  
+    <xb:namespace uri="http://schemas.ggf.org/jsdl/2006/07/jsdl-hpcpa">
+        <xb:package>org.ogf.schemas.jsdl.hpcpa</xb:package>
+    </xb:namespace>
+      
+</xb:config>
\ No newline at end of file
diff --git a/grid-tools/jsdl-generator/src/main/resources/jsdl-spmd.xsd b/grid-tools/jsdl-generator/src/main/resources/jsdl-spmd.xsd
new file mode 100644 (file)
index 0000000..d694f1d
--- /dev/null
@@ -0,0 +1,116 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<!--\r
+       The OGF takes no position regarding the validity or scope of any \r
+intellectual property or other rights that might be claimed to pertain \r
+to the implementation or use of the technology described in this \r
+document or the extent to which any license under such rights might or \r
+might not be available; neither does it represent that it has made any \r
+effort to identify any such rights.  Copies of claims of rights made \r
+available for publication and any assurances of licenses to be made \r
+available, or the result of an attempt made to obtain a general license \r
+or permission for the use of such proprietary rights by implementers or \r
+users of this specification can be obtained from the OGF Secretariat.\r
+       \r
+       The OGF invites any interested party to bring to its attention any \r
+copyrights, patents or patent applications, or other proprietary rights \r
+which may cover technology that may be required to practice this \r
+recommendation.  Please address the information to the OGF Executive \r
+Director.\r
+       \r
+       This document and the information contained herein is provided on an \r
+"As Is" basis and the OGF disclaims all warranties, express or implied, \r
+including but not limited to any warranty that the use of the \r
+information herein will not infringe any rights or any implied\r
+warranties of merchantability or fitness for a particular purpose.\r
+       \r
+       Copyright (C) Open Grid Forum (2006, 2007). All Rights Reserved. \r
+       \r
+       This document and translations of it may be copied and furnished to\r
+others, and derivative works that comment on or otherwise explain it or\r
+assist in its implementation may be prepared, copied, published and \r
+distributed, in whole or in part, without restriction of any kind, \r
+provided that the above copyright notice and this paragraph are included \r
+on all such copies and derivative works. However, this document itself \r
+may not be modified in any way, such as by removing the copyright notice\r
+or references to the OGF or other organizations, except as needed for\r
+the purpose of developing Grid Recommendations in which case the\r
+procedures for copyrights defined in the OGF Document process must be\r
+followed, or as required to translate it into languages other than \r
+English. \r
+       \r
+       The limited permissions granted above are perpetual and will not be \r
+revoked by the OGF or its successors or assignees.\r
+-->\r
+\r
+<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"\r
+       xmlns:jsdl-posix="http://schemas.ggf.org/jsdl/2005/11/jsdl-posix"\r
+       xmlns="http://schemas.ogf.org/jsdl/2007/02/jsdl-spmd"\r
+       xmlns:jsdl-spmd="http://schemas.ogf.org/jsdl/2007/02/jsdl-spmd"\r
+       targetNamespace="http://schemas.ogf.org/jsdl/2007/02/jsdl-spmd" \r
+               elementFormDefault="qualified">\r
+       <xsd:import namespace="http://schemas.ggf.org/jsdl/2005/11/jsdl-posix"\r
+               schemaLocation="http://schemas.ggf.org/jsdl/2005/11/jsdl-posix"/>\r
+       <!--==========================================================-->\r
+       <xsd:complexType name="NumberOfProcesses_Type">\r
+               <xsd:simpleContent>\r
+                       <xsd:extension base="xsd:positiveInteger">\r
+                               <xsd:attribute name="actualtotalcpucount" \r
+                                       type="xsd:boolean" use="optional"/>\r
+                               <xsd:anyAttribute namespace="##other" \r
+                                       processContents="lax"/>\r
+                       </xsd:extension>\r
+               </xsd:simpleContent>\r
+       </xsd:complexType>\r
+       <!--==========================================================-->\r
+       <xsd:complexType name="ProcessesPerHost_Type">\r
+               <xsd:simpleContent>\r
+                       <xsd:extension base="xsd:positiveInteger">\r
+                               <xsd:anyAttribute namespace="##other" \r
+                                       processContents="lax"/>\r
+                       </xsd:extension>\r
+               </xsd:simpleContent>\r
+       </xsd:complexType>\r
+       <!--==========================================================-->\r
+       <xsd:complexType name="ThreadsPerProcess_Type">\r
+               <xsd:simpleContent>\r
+                       <xsd:extension base="xsd:positiveInteger">\r
+                               <xsd:attribute name="actualindividualcpucount" \r
+                                       type="xsd:boolean" use="optional"/>\r
+                               <xsd:anyAttribute namespace="##other" \r
+                                       processContents="lax"/>\r
+                       </xsd:extension>\r
+               </xsd:simpleContent>\r
+       </xsd:complexType>      \r
+       <!--==========================================================-->\r
+       <xsd:complexType name="SPMDApplication_Type">\r
+               <xsd:sequence>\r
+                       <xsd:element ref="jsdl-posix:Executable" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-posix:Argument" minOccurs="0" \r
+                               maxOccurs="unbounded"/>\r
+                       <xsd:element ref="jsdl-posix:Input" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-posix:Output" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-posix:Error" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-posix:WorkingDirectory" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-posix:Environment" minOccurs="0" \r
+                               maxOccurs="unbounded"/>\r
+                       <xsd:element ref="jsdl-posix:UserName" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-spmd:NumberOfProcesses" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-spmd:ProcessesPerHost" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-spmd:ThreadsPerProcess" minOccurs="0"/>\r
+                       <xsd:element ref="jsdl-spmd:SPMDVariation" minOccurs="1" maxOccurs="1"/>\r
+                       <xsd:any namespace="##other" processContents="lax"\r
+                               minOccurs="0" maxOccurs="unbounded"/>\r
+               </xsd:sequence>\r
+               <xsd:attribute name="name" type="xsd:NCName" use="optional"/>\r
+               <xsd:anyAttribute namespace="##other" processContents="lax"/>\r
+       </xsd:complexType>\r
+       <!--==========================================================-->\r
+       <xsd:element name="SPMDApplication" type="SPMDApplication_Type"/>\r
+       <xsd:element name="NumberOfProcesses" \r
+               type="jsdl-spmd:NumberOfProcesses_Type" nillable="true"/>\r
+       <xsd:element name="ProcessesPerHost" \r
+               type="jsdl-spmd:ProcessesPerHost_Type"/>\r
+       <xsd:element name="ThreadsPerProcess" \r
+               type="jsdl-spmd:ThreadsPerProcess_Type" nillable="true"/>\r
+       <xsd:element name="SPMDVariation" type="xsd:anyURI"/>\r
+</xsd:schema>\r