Hello, You should upgrade your workflow schema to 0.3 or above. Custom action schemas not supported in 0.2 .. <workflow-app xmlns="uri:oozie:workflow:0.3"
-- Mona On 8/19/13 11:18 PM, "Giridhar Addepalli" <[email protected]> wrote: >Hi All, > >Please let me know if you need more information from my side. > >Thanks, >Giridhar. > > >On Mon, Aug 19, 2013 at 5:59 PM, Giridhar Addepalli ><[email protected]>wrote: > >> Hi All, >> >> I am trying to create custom action. >> I followed steps on infoq. >> >> Here is my xsd for new action >> >> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" >> >> xmlns:publishhamakeevent="uri:oozie:publishhamakeevent-action:0.1" >> elementFormDefault="qualified" >> targetNamespace="uri:oozie:publishhamakeevent-action:0.1"> >> >> <xs:element name="publishhamakeevent" >> type="publishhamakeevent:ACTION"/> >> >> <xs:complexType name="ACTION"> >> <xs:sequence> >> <xs:element name="user" type="xs:string" minOccurs="0" >> maxOccurs="1"/> >> <xs:element name="project" type="xs:string" minOccurs="1" >> maxOccurs="1"/> >> <xs:element name="dtr" type="xs:string" minOccurs="0" >> maxOccurs="1"/> >> <xs:element name="status" type="xs:string" minOccurs="1" >> maxOccurs="1"/> >> <xs:element name="type" type="xs:string" minOccurs="1" >> maxOccurs="1"/> >> <xs:element name="timestamp" type="xs:string" minOccurs="0" >> maxOccurs="1"/> >> <xs:element name="hamakerunid" type="xs:string" >>minOccurs="0" >> maxOccurs="1"/> >> <xs:element name="taskrunid" type="xs:string" minOccurs="0" >> maxOccurs="1"/> >> <xs:element name="logfilelocs" type="xs:string" >>minOccurs="0" >> maxOccurs="1"/> >> </xs:sequence> >> </xs:complexType> >> </xs:schema> >> >> >> I made following changes to oozie-site.xml >> >> <property> >> <name>oozie.service.ActionService.executor.ext.classes</name> >> <value> >> org.apache.oozie.action.email.EmailActionExecutor, >> org.apache.oozie.action.hadoop.HiveActionExecutor, >> org.apache.oozie.action.hadoop.ShellActionExecutor, >> org.apache.oozie.action.hadoop.SqoopActionExecutor, >> org.apache.oozie.action.hadoop.DistcpActionExecutor, >> >> com.walmartlabs.dare.oozie.custom.PublishHamakeEventActionExecutor >> </value> >> </property> >> >> <property> >> <name>oozie.service.SchemaService.wf.ext.schemas</name> >> >> >><value>shell-action-0.1.xsd,shell-action-0.2.xsd,email-action-0.1.xsd,hiv >>e-action-0.2.xsd,hive-action-0.3.xsd,sqoop-action-0.2.xsd,sqoop-action-0. >>3.xsd,ssh-action-0.1.xsd,distcp-action-0.1.xsd,publishhamakeevent-action- >>0.1.xsd</value> >> </property> >> >> <property> >> <name>oozie.service.WorkflowSchemaService.ext.schemas</name> >> <value>publishhamakeevent-action-0.1.xsd</value> >> </property> >> >> I added new jar via oozie-setup.sh >> >> I am trying to run following workflow.xml : >> >> <workflow-app xmlns="uri:oozie:workflow:0.2" name="pub-wf"> >> <start to="pub-node"/> >> <action name="pub-node"> >> <publishhamakeevent >> xlmns="uri:oozie:publishhamakeevent-action:0.1"> >> <project>test</project> >> <status>success</status> >> <type>start</type> >> </publishhamakeevent> >> <ok to="end"/> >> <error to="fail"/> >> </action> >> <kill name="fail"> >> <message>Publish event failed, error >> message[${wf:errorMessage(wf:lastErrorNode())}]</message> >> </kill> >> <end name="end"/> >> </workflow-app> >> >> >> I get the following error : >> >> Error: E0701 : E0701: XML schema error, cvc-complex-type.2.4.a: Invalid >> content was found starting with element 'publishhamakeevent'. One of >> '{"uri:oozie:workflow:0.2":map-reduce, "uri:oozie:workflow:0.2":pig, >> "uri:oozie:workflow:0.2":sub-workflow, "uri:oozie:workflow:0.2":fs, >> "uri:oozie:workflow:0.2":java, WC[##other:"uri:oozie:workflow:0.2"]}' is >> expected. >> >> >> Please help. >> >> Thanks, >> Giridhar. >>
