Skip to end of metadata
Go to start of metadata
Beacon Navigation

Screencast

 

I encourage you to watch the screencast in fullscreen mode, with the video set to 720p or 1080p, it was recorded natively at 1080p.

Checkout the OpenFlowJ and Beacon source

  • git clone https://bitbucket.org/openflowj/openflowj.git
  • git clone git://gitosis.stanford.edu/beacon.git

For guide purposes we will assume these are checked out to ~/git/beacon and ~/git/openflowj

Develop and build using Eclipse

Prerequisites

Setup

Create a new Eclipse workspace if you are not starting from a fresh Eclipse install

  • File ? Switch Workspace ? Other, pick a new folder to host the workspace

Set Eclipse's compliance level to 1.6

  • Window ? Preferences ? Java ? Compiler then under JDK Compliance, change Compiler compliance level to 1.6.

Import the OpenFlowJ project

  • File ? Import ? General ? Existing Projects into Workspace, Select ~/git/openflowj as the root directory, click ok, then select all the projects, ensure copy projects into workspace is not checked and click finish.

Import the Beacon Eclipse projects

  • File ? Import ? General ? Existing Projects into Workspace, Select ~/git/beacon as the root directory, click ok, then select all the projects, ensure copy projects into workspace is not checked and click finish.

Set the target (runtime libraries)

  • Open the Beacon Main Target project, double click the main.target file.
  • Once opened, down in the right hand corner of Eclipse you should see a message saying Resolving Target Definition, wait for this to complete before proceeding.
  • After the target has been resolved, click Set as Target Platform in the top right corner of the main.target window. (Note if you click before it has been resolved, you will receive an error). At this point all compilation errors should be gone.

Import the Beacon code style settings

  • Click Window ? Preferences. Then in the left column click Java ? Code Style ? Formatter, then click the Import button, and select ~/git/beacon/beacon_style_settings.xml and hit ok, then ensure the Active profile is Beacon.

Running

Launch Beacon in debug mode

  • Run ? Debug Configurations
  • Look for the OSGi Framework on the left, expand its children and select beacon, then click Debug

Develop with your own editor and build using Maven

Please note, Maven resolves, downloads, and caches all libraries needed for building at runtime, so the first build must download many libraries and its runtime is not representative of what you would see in your daily workflow.

Prerequisites

Building OpenFlowJ

Expected build time: ~3.5 seconds

Building Beacon

Expected build time: ~1 minute 10 seconds (full build, including tests)

Jars for each bundle are available under the bundle's target/ folder. Per-platform runnable instances of Beacon are available under beacon/net.beaconcontroller.product/target/products

Next Steps

  • No labels

1 Comment

  1. thanks for sharing that