In this section: |
This section provides a walkthrough (demo) of deploying an iWay Service Manager (iSM) application to a Hadoop cluster.
This section provides an overview of the environment and the iSM application that will be deployed.
You can use any node within a cluster for the iSM installation.
For example, on the Cloudera Hadoop cluster that is used for this demo, you must add /opt/cloudera/parcels/CDH/jars/* to the iSM post classpath to enable HDFS/Avro services.
You may not require all of the .jar files, but it is a good practice to simply add all of the .jar files just to be sure. Ensure to add the path that is specific to your environment as the above example is provided only for reference purposes.
You can test run your process flows against this remote iSM instance and also deploy your applications to this instance.
For example, you can run the hadoop fs -ls /user command to retrieve a list of the home directories, as shown in the following image.
The write_file object is configured for the HDFS Emit Service, as shown in the following image.
The following HDFS Emit Service parameters are critical in this configuration:
hadoop fs -ls | grep file_pattern
The file written can be on any node or split across nodes in the Hadoop cluster.
As shown in the following image, two files with demo_### pattern have been written to the cluster.
Note: The Path setting to include HDFS .jar files had to be added to an application and separately, as it is not inherited from the base configuration due to a different deployment template.
The iWay Service Manager (iSM) application must first be packaged to be deployable under YARN using Slider. For more information on how to create a Slider package, see Creating an iWay Service Manager Slider Package.
You will need to:
The final .zip file must either be created on your Hadoop node or moved to your Hadoop node.
Note: If you copy the sample scripts that are provided in this documentation, you will need to reformat them slightly to be compatible with Python syntax. You can also refer to the sample scripts provided within the zip file (iway7master.zip) along with this documentation.
When creating a tarball (tar archive) for iSM, you can reduce its size by removing any unused .jar files and directories. For example, if you are not using iWay Trading Partner Manager (TPM), then you can remove TPM components. If you are not using iWay Data Quality (DQ), then you can remove DQ components, and so on. This strategy can be used to reduce the overall size of the .zip file (package) for smaller cluster deployments.
This section describes how to install and deploy the sample Slider package.
slider install-package --name IWAY7 --package iway7master.zip
Note: This command has changed in the latest Slider documentation.
To replace an existing package, add the --replacepkg attribute, as shown in the following example.
slider install-package --name IWAY7 --package iway7master.zip --replacepkg
If you do not have a Slider environment configured through the slider-client.xml and slider-env.sh files, then you must define additional properties using a command line.
By default the slider-client.xml file contains all of the properties, which are commented by default. You will need to uncomment the properties if you are setting the Slider configuration in the file. Minimally, you will need to have the following property uncommented and set according to your environment.
<property> <name>hadoop.registry.zk.quorum</name> <value>iwhadoop8:2181,iwhadoop9:2181,iwhadoop2:2181</value> </property>
Note: The specific value should match your environment. This example is only for reference purposes.
If the Slider is not configured, then you must add the corresponding manager and filesystem commands as shown in the following example. Ensure that your Slider is properly configured.
slider install-package --name IWAY7 --package iway7master.zip --
replacepkg --manager iwhadoop2:8033 --filesystem hdfs://iwhadoop2:8020
Note: This example is only for reference purposes. The port and host values will vary for each system.
slider create iway7_1 --template appConfig-default.json --resources resources-default.json
slider create iway7_1 --template appConfig-default.json --resources resources-default.json --manager iwhadoop2:8032 --filesystem hdfs://iwhadoop2:8020
For example:
http://iwhadoop2:8088/cluster
In the application monitoring console you can see your installed application listed, which you can select to view more details, as shown in the following image.
You can see on which node the application was started, as shown in the following image.
You can also review the running statistics for the application, as shown in the following image.
iWay Software |