README.md 4.8 KB
Newer Older
1 2 3
# ozone


K
ktzoumas 已提交
4 5 6
This is the source code repository of the Stratosphere research project. 

See www.stratosphere.eu for project details, publications, etc
7

K
ktzoumas 已提交
8
ozone is the codename of the latest Stratosphere distribution.
R
Robert Metzger 已提交
9

K
ktzoumas 已提交
10 11 12


Build Status: [![Build Status](https://travis-ci.org/dimalabs/ozone.png)](https://travis-ci.org/dimalabs/ozone)
13 14

## Getting Started
K
ktzoumas 已提交
15
Below are three short tutorials that guide you through the first steps: Building, running and developing.
16 17 18

###  Build From Source

K
ktzoumas 已提交
19
This tutorial shows how to build Stratosphere on your own system. Please open a bug report if you have any troubles!
20 21 22 23 24 25 26 27 28 29 30 31 32

#### Requirements
* Unix-like environment (We use Linux, Mac OS X, it should run with cygwin)
* git
* maven
* Java 6 or 7

.

	git clone https://github.com/dimalabs/ozone.git
	cd ozone
	mvn -DskipTests clean package # this will take up to 5 minutes

K
ktzoumas 已提交
33 34
Stratosphere is now installed in `stratosphere-dist/target`
If you’re a Debian/Ubuntu user, you’ll find a .deb package. We will continue with the generic case.
35 36 37 38 39 40 41

	cd stratosphere-dist/target/stratosphere-dist-0.2-ozone-bin/stratosphere-0.2-ozone/

Note: The directory structure here looks like the contents of the official release distribution.

### Run your first program

K
ktzoumas 已提交
42 43
We will run a simple “Word Count” example. 
The easiest way to start Stratosphere on your local machine is so-called "local-mode":
44 45 46 47 48 49 50 51 52

	./bin/start-local.sh

Get some test data:

	 wget -O hamlet.txt http://www.gutenberg.org/cache/epub/1787/pg1787.txt

Start the job:

K
ktzoumas 已提交
53
	./bin/pact-client.sh run --jarfile ./examples/pact/pact-examples-0.2-ozone-WordCount.jar --arguments 1 file://`pwd`/hamlet.txt file://`pwd`/wordcount-result.txt
54

K
ktzoumas 已提交
55
You will find a file called `wordcount-result.txt` in your current directory.
56

K
ktzoumas 已提交
57 58
#### Alternative Method: Use the PACT web interface
(And get a nice execution plan overview for free!)
59 60 61 62 63 64 65

	./bin/start-local.sh
	./bin/pact-webfrontend.sh start

Get some test data:
	 wget -O ~/hamlet.txt http://www.gutenberg.org/cache/epub/1787/pg1787.txt

K
ktzoumas 已提交
66
* Point your browser to to http://localhost:8080/launch.html. Upload the WordCount.jar using the upload form in the lower right box. The jar is located in `./examples/pact/pact-examples-0.2-ozone-WordCount.jar`.
67 68 69 70 71 72 73 74
* Select the WordCount jar from the list of available jars (upper left).
* Enter the argument line in the lower-left box: `1 file://<path to>/hamlet.txt file://<wherever you want the>/wordcount-result.txt`

* Hit “Run Job”


### Eclipse Setup and Debugging

K
ktzoumas 已提交
75
To contribute back to the project or develop your own jobs for Stratosphere, you need a working development environment. We use Eclipse and IntelliJ for development. Here we focus on Eclipse.
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120

Import the Stratosphere source code using Maven's Import tool:
  * Select "Import" from the "File"-menu.
  * Expand "Maven" node, select "Existing Maven Projects", and click "next" button
  * Select the root directory by clicking on the "Browse" button and navigate to the top folder of the cloned Stratosphere Git repository.
  * Ensure that all projects are selected and click the "Finish" button.

Create a new Eclipse Project that requires Stratosphere in its Build Path!

Use this skeleton as an entry point for your own Jobs: It allows you to hit the “Run as” -> “Java Application” feature of Eclipse. (You have to stop the application manually, because only one instance can run at a time)

```java
public class Tutorial implements PlanAssembler, PlanAssemblerDescription {

	public static void execute(Plan toExecute) throws Exception {
		LocalExecutor executor = new LocalExecutor();
		executor.start();
		long runtime = executor.executePlan(toExecute);
		System.out.println("runtime:  " + runtime);
		executor.stop();
	}

	@Override
	public Plan getPlan(String... args) {
		// your Plan goes here
	}

	@Override
	public String getDescription() {
		return "Usage: …. "; // TODO
	}

	public static void main(String[] args) throws Exception {
		Tutorial tut = new Tutorial();
		Plan toExecute = tut.getPlan( /* Arguments */);
		execute(toExecute);
	}
}

```

## Support
Don’t hesitate to ask!
We have a mailing list for our users: https://lists.tu-berlin.de/mailman/listinfo/stratosphere-dev

K
ktzoumas 已提交
121
Open an issue on github, if you need our hel:p https://github.com/dimalabs/ozone/issues/new
122 123 124 125 126 127 128 129

## Documentation


## Fork and Contribute

This is an active open-source project. We are always open to people who want to use the system or contribute to it. 

K
ktzoumas 已提交
130
The development community lives on github and our mailing list: https://lists.tu-berlin.de/mailman/listinfo/stratosphere-dev (But we prefer github)
131 132 133 134 135 136 137

We use the github Pull Request system for the development of Stratosphere. Just open a request if you want to contribute.

### What to contribute
* Bug reports
* Bug fixes
* Documentation
K
ktzoumas 已提交
138 139
* Tools that ease the use and development of Stratosphere
* Well-written Stratosphere jobs
140 141


K
ktzoumas 已提交
142
Let us know if you have created a system that uses Stratosphere, so that we can link to you.
143 144 145 146 147 148 149