Announcement Announcement Module
Collapse
No announcement yet.
How to integrate Spring with Pig using xml file? Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to integrate Spring with Pig using xml file?

    Hi,
    I recently tried to run pig job from context.xml as i am integrating pig with spring. But i couldnt resolve <hdp : pig-factory> and <hdp : pig-runner> . I have attached the png file below showing my configuration. Please advice. Thanks

    My context.xml file is as follows,
    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:hdp="http://www.springframework.org/schema/hadoop"
    xmlns:context="http://www.springframework.org/schema/context"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schem...ring-beans.xsd
    http://www.springframework.org/schema/hadoop http://www.springframework.org/schem...ing-hadoop.xsd
    http://www.springframework.org/schema/context http://www.springframework.org/schem...ng-context.xsd
    http://www.springframework.org/schema/hadoop http://www.springframework.org/schema/hadoop/spring-hadoop.xsd">

    <context: property-placeholder location="hadoop.properties" />

    <hdp:configuration>
    fs.default.name=${hd.fs}
    </hdp:configuration>

    <hdp : pig properties-location="pig-server.properties" exec-type="MAPREDUCE" />

    <hdp: pig-factory exec-type="LOCAL" job-name="pig-script" configuration-ref="hadoopConfiguration"
    properties-location="pig-server.properties" xmlns="http://www.springframework.org/schema/hadoop">
    source=${pig.script.src}
    <hdp:script location="src/main/resources/ixp.pig">
    <arguments>electric=sea</arguments>
    </hdp:script>
    </hdp: pig-factory>

    </beans>

    Regards,
    George
    Last edited by GeorgeJ; Mar 5th, 2013, 11:42 PM.
Working...
X