Starting the File/Hadoop Event XML Adapter

Start the File/Hadoop Event XML adapter either in unmanaged or managed mode. In unmanaged mode, the adapter is started separately from the ESP project, and in managed mode, the adapter is started with the ESP project. In unmanaged mode, you can start the adapter from the command line or using the start command files.

Mode Steps
Unmanaged, from the command line

Open a terminal window and enter:

Windows:
  • For the File/Hadoop Event XML Input adapter: cd %ESP_HOME%\adapters\framework\instances\file_xmllist_input
  • For the File/Hadoop Event XML Output adapter: cd %ESP_HOME%\adapters\framework\instances\file_xmllist_output
  • start_adapter.bat <adapter configuration file name>
UNIX:
  • For the File/Hadoop Event XML Input adapter: cd $ESP_HOME/adapters/framework/instances/file_xmllist_input
  • For the File/Hadoop Event XML Output adapter: cd $ESP_HOME/adapters/framework/instances/file_xmllist_output
  • ./start_adapter.sh <adapter configuration file name>
Unmanaged, using the start command files
From the adapter directory (see directories above):
  1. Start the ESP node by running start_node.bat (Windows) or start_node.sh (UNIX).
  2. Start the adapter by running start_adapter.bat (Windows) or start_adapter.sh (UNIX).
Managed
  1. Add an ATTACH ADAPTER statement in the CCL file of your project to reference the adapter. For example,
    ATTACH INPUT ADAPTER Generic_Input_Adapter__external_1 
    TYPE genericinputadapter
    to  BaseInput
    PROPERTIES configFilePath =
    'C:/sybase/ESP-5_1/adapters/framework/instances/file_csv_input/adapter_config.xml' ;
  2. Start the node.
    Windows:
    cd %ESP_HOME%\cluster\nodes\<nodename>
    %ESP_HOME%\bin\esp_server --cluster-node <nodename>.xml
    or
    UNIX:
    cd $ESP_HOME/cluster/nodes/<nodename>
    $ESP_HOME/bin/esp_server --cluster-node <nodename>.xml
  3. Compile CCL to create CCX.
    Windows:
    %ESP_HOME%\bin\esp_compiler -i <modelname>.ccl -o <modelname>.ccx
    or
    UNIX:
    $ESP_HOME/bin/esp_compiler -i <modelname>.ccl -o <modelname>.ccx
  4. Deploy the project on the cluster.
    Windows:
    %ESP_HOME%\bin\esp_cluster_admin" --uri=esp://localhost:19011
    --username=sybase --password=sybase --add_project --workspacename=
    <workspacename> --project-name=<projectname> --ccx=<modelname>.ccx
    or
    UNIX:
    $ESP_HOME/bin/esp_cluster_admin" --uri=esp://localhost:19011
    --username=sybase --password=sybase --add_project --workspacename=
    <workspacename> --project-name=<projectname> --ccx=<modelname>.ccx
  5. Start the deployed project on the cluster.
    Windows:
    %ESP_HOME%\bin\esp_cluster_admin" --uri=esp://localhost:19011
    --username=sybase --password=sybase --start_project --
    workspace-name=<workspacename> --project-name=<projectname>
    or
    UNIX:
    $ESP_HOME/bin/esp_cluster_admin" --uri=esp://localhost:19011
    --username=sybase --password=sybase --start_project --
    workspace-name=<workspacename> --project-name=<projectname>