ECL Plug-in for the Eclipse IDEBoca Raton Documentation TeamWe welcome your comments and feedback about this document via
email to docfeedback@hpccsystems.comPlease include Documentation
Feedback in the subject line and reference the document name,
page numbers, and current Version Number in the text of the
message.LexisNexis and the Knowledge Burst logo are registered trademarks
of Reed Elsevier Properties Inc., used under license.HPCC Systems is a registered trademark of LexisNexis Risk Data
Management Inc.Other products, logos, and services may be trademarks or
registered trademarks of their respective companies.All names and example data used in this manual are fictitious. Any
similarity to actual persons, living or dead, is purely
coincidental.HPCC SystemsIntroductionEclipse is an alternative Integrated Development Environment (IDE)
which can be used with the HPCC Systems Platform. Eclipse is open-source,
and multi-platform. It can be used instead of the ECL IDE to write and
execute queries into data on an HPCC cluster .The ECL plug-in is also open source.The following sections cover how to install and use the ECL plug-in
for Eclipse.Prerequisites and RequirementsThese are the basic requirements to run the Eclipse
plug-in.Windows Prerequisites:The HPCC Client Tools (available from http://hpccsystems.com/download/free-community-edition/client-tools
)This installs the ECL compiler, eclcc, command line tools,
and related componentsThe Graph Control (available from http://hpccsystems.com/download/free-community-edition/graph-control)Eclipse Indigo or laterThe ECL plug-in for EclipseOn a machine running Windows 7 (either the 32-
or 64-bit), depending on your install location, you
may need to start Eclipse with administrator
privileges for plug-ins to install
properly. This is necessary even if your account has
administrator privileges. Right-click on the
Eclipse shortcut, then select Run as Administrator from the
pop-up menu. After installing the
plug-in, you do not need to run as administrator in
the normal course of your work. However, to install
any future updates will require running as
administrator. Linux Prerequisites:The HPCC Client Tools (available from http://hpccsystems.com/download/free-community-edition/client-tools
)This installs the ECL compiler, eclcc, command line tools,
and related componentsThe Graph Control (available from http://hpccsystems.com/download/free-community-edition/graph-control)64-bit desktop edition of LinuxEclipse Indigo or laterThe ECL plug-in for EclipseMac (Intel-based) Prerequisites:The HPCC Client Tools (available from http://hpccsystems.com/download/free-community-edition/client-tools
)This installs the ECL compiler, eclcc, command line tools,
and related componentsThe Graph Control (available from http://hpccsystems.com/download/free-community-edition/graph-control)Mac OS X 64-bit (10.6.x or later)Eclipse Indigo or laterThe ECL plug-in for EclipseInstalling EclipseThis section describes how to install the Eclipse IDE. If you
already have the Eclipse IDE installed, skip this section and go to
Installing the ECL Plug-In.Getting EclipseDownload the Eclipse IDE from the site:http://www.eclipse.org/downloads/Choose the Eclipse IDE for Java Developers packageDownload the appropriate Eclipse IDE for your
platformThe Eclipse IDE is delivered as a compressed (.zip or
.tar.gz) file. Extract this file into the folder of your choice
(for example, c:\Eclipse on Windows).You can optionally create a shortcut to the executable file
(eclipse.exe on Windows, or
eclipse on Linux).Installing the ECL Plug-inTo install the Eclipse plug-in:In Eclipse IDE, select Help >>
Install New Software…Press the Add
button.Install Software: AddProvide a suitable name, for example, ECL_PlugIn.Enter one of the locations below in the Location field.Note:We recommend the latest stable build for production
work.http://eclipse.hpccsystems.com/stableThe latest stable build.http://eclipse.hpccsystems.com/developThe cutting-edge, untested development
build.Enter LocationSelect the ECL Language box
then press the Next >
button.Note:This can take a while before it appears.Select ECL LanguageReview the items to be installed and press the Next > button.Accept the licensing agreement, then press the Finish button to complete the installation
wizard.After completing the wizard, it prompts you to restart
eclipse. You should restart eclipse in order for the changes to
take effect.Updating the ECL Plug-in for EclipseWe recommend using the Eclipse Automatic Update feature.In Eclipse IDE, select Window >>
Preferences.Expand the Install/Update
branch on the left, then select Automatic
Updates.Check the Automatically find new
updates and notify me button.Automatic Update SettingsSet your options, then press the
OK button.To manually update the Eclipse plug-in:In Eclipse IDE, select Help >>
Check for Updates…A progress window displays as it checks for any available
updates.If an update is available, follow the prompts to install
it.Using Eclipse with HPCCThe following sections tell you how you can use Eclipse to interact
with the HPCC Platform.Creating an ECL ProjectIn order to use Eclipse with an HPCC Platform, you will need to be
able to create, edit, and submit ECL projects. This is how to do that
with a simple "Hello World" project.Open the Eclipse IDEFrom the Workbench File menu, select File >> New
>> Project…
This launches a New Project
window which prompts you to Select a wizardExpand the ECL folder,
select ECL Project, then press
the Next button.In the Project window, give
it an appropriate name. For example, hello_world.Press the Finish
button.If your ECL Development perspective is not already open, you
are prompted to Open Associated
Perspective? Press the Yes button.Tip:If you check the Remember my
decision checkbox, you won't have to do this
every time.In the ECL Explorer panel,
right-click on the newly created project, then select New >>
File.The New File window
displays.If necessary, select the parent folder, then provide a name
for the file. For example, hello.ecl.No matter what you name your file, be sure you
ALWAYS include the .ecl extension. The extension is
required for the project to work correctly with the HPCC
compiler.Add the following code (including the quotes):
OUTPUT('Hello world'); Save your code by pressing the Save button on the toolbar, or selecting
the File >> Save from the
menu.Saving an ECL file automatically invokes a syntax
check. If there is an error, it is indicated by a red X
next to the line containing the error.Execute the ECL CodeYou can choose where to execute your ECL Code. Each target is
defined in a Run Configuration.Execute your ECL Code Remotely on a Server.Expand your project (hello_world), then rt-click on
hello.ecl, and select Run As>>Run Configurations…Double click ECL Targets to
create a new Run As
configuration. On the HPCC Platfom tab
enter the following:NameGive it an appropriate name, for example: ThorClusterIP addressIP address or DNS name of your ESP serverPortThe port to use (default is 8010)Target nameThe name of the cluster (for example, hthor, thor,
or roxie)CredentialsOptional Username and Password to use (required if
security is enabled on the cluster)ECL Watch / AddressThis is autofilled from the Server IP Address above;
however, if your ECL Watch service is running on a
different IP or port, you can modify it here.Tip:Press the test button and you will see its
current ECL Watch page. This lets you know you have
the correct configuration.Correct ConfigurationOn the ECLCC Compiler tab
check the settings. The location of your installed Client Tools
should have been found and auto-completed. If they are not
correct, check the Override Defaults box and fill in the location
of your Client Tools.Press the Apply button to
save your configuration.Press the Run
button.In the Workunits panel on
the left, click and expand the Workunit, then click and expand the
Outputs folder.The result(s) display in the center panel. (If your query
has multiple results, then each result displays in a separate
tab.)Later you can use the drop list on the toolbar button to run
on an established Run
Configuration, as show below.Next StepsTo familiarize yourself with the Eclipse IDE and the ECL Development
perspective, we recommend working the following tutorials in Eclipse:
The HPCC Data TutorialThe Six Degrees of Kevin
Bacon exampleTo discuss this plug-in or get help using it, visit the
forum on the HPCC System's portal at:http://hpccsystems.com/bb/viewforum.php?f=33&sid=adddbd537294bf32e2c46c1d7d16134e