Getting Started
Last updated
Last updated
In this chapter, we will build a simple Pronghorn app. The goals are the following:
Create a schema that defines passing of a "Hello World, $NAME" message.
Write a stage that produces the input, and another stage that receives it and displays it.
Get familiarized with Pronghorn basics and syntax.
We can then visualize our data flow:
(Of course, any real application would be a lot more complex than this simple example).
Before we do anything else, we need to actually create the message format, but before this, let's set up an actual Pronghorn project.
As instructed on the previous page, you need Maven installed. We use Maven Archetypes to generate a template for you to get started.
First, create a directory called PronghornProjects
:
Next, run the following command:
You will then be prompted to fill out some information:
Hit "Y" to generate the HelloWorldPronghorn project.
Next, open the project in your favorite IDE. You can safely delete the following files (which will not be used in this simple tutorial):
SchemaOneSchema.java
SchemaTest.java
SchemaOne.xml
HelloWorldPronghornTest.java
Delete all the content in HelloWorldPronghorn.java and replace it with the following:
In the next chapters, we will edit this file to create our HelloWorld example.