Non-IBM Disclaimer

The postings on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.

Thursday, January 31, 2019

Running ERTool on MacOS

Updates

Sep 17,2019 - the updated Git package includes full MacOS support. To launch the GUI use the following command:
java -XstartOnFirstThread -jar ErrorReport.jar -gui

The original post

ERTool is a java utility that helps with DataPower error report analysis. I had some issues getting it working on my Mac, so sharing from experience for other people that might benefit from it.

Once downloaded the ERTool project from Git, I've run the build and it failed with compilation errors related to the MacOS environment. This was addressed by changing the build.xml file and MacOS related jar files.

Adding JAR files

Add the following files to the framework/lib folder:
  1. org.eclipse.swt-3.1.jar
  2. org.eclipse.swt-3.1.jar.zip

Changing the build.xml file

First, add a MacOS environmental property for further references:
<condition property="isMac">
    <os family="mac">
</condition>

Next, reference that property while selecting relevant libraries for the build process:
<include if:set="isMac" name="org.eclipse.swt-3.1.jar"/>
<include if:set="isMac" name="org.eclipse.swt-3.1.jar.zip"/>

Save the file and rerun the build command. It should complete successfully.

Running the ERTool from command line

Example CLI to run the utility from command line:
java -jar ErrorReport.jar \
  -analyticsfile Analytics.xml \
  -format HTML \
  -outfile output.html \
  -file error-report.txt

Bibliography

  1. https://www.ibm.com/support/knowledgecenter/en/SS9H2Y_7.7.0/com.ibm.dp.doc/ertool.html
  2. https://www.ibm.com/developerworks/community/blogs/de2b7f3e-30c5-4172-be0f-2640ebb55d13/entry/ERTool_Analyze_your_configuration_against_best_practices?lang=en 
  3. https://github.com/ibm-datapower/ertool

No comments:

Post a Comment