Best Practices and Pitfalls for Building Products out of OpenDaylight

Similar documents
YANG Modeling: The Good, The Bad, and The Ugly

Con$nuous Integra$on Development Environment. Kovács Gábor

What is version control? (discuss) Who has used version control? Favorite VCS? Uses of version control (read)

OpenDaylight: Introduction, Lithium and Beyond Colin Dixon

Con$nuous Deployment with Docker Andrew Aslinger. Oct

Version Control for the 2- Pizza Team: Merge Conflicts (ELLS 9.5) Armando Fox

Practical C Programming

MD-SAL APPLICATION AWARE DATA STORE (AADS)

NETCONF WG IETF 96 (Berlin)

Brief overview of the topic and myself the 7 VCS used so far (different one each time), still many unused Acts as a time-machine, and almost as

Lab 08. Command Line and Git

Version Control System GIT

KTH Royal Institute of Technology SEMINAR 2-29 March Simone Stefani -

Revision Control. How can 4. Slides #4 CMPT 276 Dr. B. Fraser. Local Topology Simplified. Git Basics. Revision Control:

Best Prac:ces + New Feature Overview for the Latest Version of Splunk Deployment Server

Review Version Control Concepts

Version control CSE 403

Sunil Shah SECURE, FLEXIBLE CONTINUOUS DELIVERY PIPELINES WITH GITLAB AND DC/OS Mesosphere, Inc. All Rights Reserved.

SECTION 1: CODE REASONING + VERSION CONTROL

SECTION 1: CODE REASONING + VERSION CONTROL

Scaling MongoDB: Avoiding Common Pitfalls. Jon Tobin Senior Systems

ONOS YANG Tools. Thomas Vachuska Open Networking Foundation

You Can t Move Forward Unless You Can Roll Back. By: Michael Black

Agenda. - Final Project Info. - All things Git. - Make sure to come to lab for Python next week

Mike McQuaid INCLUDES 66 TECHNIQUES. Foreword by Scott Chacon MANNING

From Continuous Integration To Continuous Delivery With Jenkins

Docker at Lyft Speeding up development Matthew #dockercon

Release for Lithium. George Zhao, Ed Warnicke, Colin Dixon, Mathieu Lemey, Robert Varga, An Ho.

Clustering in OpenDaylight

NFS 3/25/14. Overview. Intui>on. Disconnec>on. Challenges

Laboratorio di Programmazione. Prof. Marco Bertini


Intro Git Advices. Using Git. Matthieu Moy. Matthieu Moy Git 2016 < 1 / 11 >

The Embedded Linux Problem

NFS. CSE/ISE 311: Systems Administra5on

Version control CSE 403

CSE 331 Software Design & Implementation

Versioning with git. Moritz August Git/Bash/Python-Course for MPE. Moritz August Versioning with Git

Continuous Integration. Johannes Seitz

Working in Teams CS 520 Theory and Practice of Software Engineering Fall 2018

Welcome to this IBM podcast, Realizing More. Value from Your IMS Compiler Upgrade. I'm Kimberly Gist

Developing and Testing Java Microservices on Docker. Todd Fasullo Dir. Engineering

Object Oriented Design (OOD): The Concept

TCSS 360: SOFTWARE DEVELOPMENT AND QUALITY ASSURANCE

Where Should the Brain of Your Mobile Application Live?

October 5 th 2010 NANOG 50 Jason Zurawski Internet2

CS 390 Software Engineering Lecture 3 Configuration Management

Scala Days 2018 You Are a Scala Contributor

Introduction to OpenDaylight: Current Events and OpenStack Neutron Integration

Version Control. Second level Third level Fourth level Fifth level. - Software Development Project. January 17, 2018

Version control CSE 403

INFO/CS 4302 Web Informa6on Systems

a handful of Git workflows for the agilist steven harman twitter: stevenharman

The OpenDaylight Project

RAD, Rules, and Compatibility: What's Coming in Kuali Rice 2.0

Git Branching for Agile Teams

Apache Geronimo 3.0 Deep Dive

git-flow Documentation

GETTING STARTED WITH NUODB

Lab 01 How to Survive & Introduction to Git. Web Programming DataLab, CS, NTHU

Rewrite or Refactor. When to declare technical bankruptcy. Laura Thomson OSCON - July 22,

GIT TUTORIAL. Creative Software Architectures for Collaborative Projects CS 130 Donald J. Patterson

There Should be One Obvious Way to Bring Python into Production. Sebastian Neubauer

CrowdCode: A Platform for Crowd Development

Founda'ons of So,ware Engineering. Process: Agile Prac.ces Claire Le Goues

Introduction to OpenDaylight and Hydrogen, Learnings from the Year, and What s Next for OpenDaylight

OpenDaylight as a Platform for Network Programmability FOSDEM, 3 February Charles Eckel, Cisco DevNet

LINUX KERNEL UPDATES FOR AUTOMOTIVE: LESSONS LEARNED

Splunk & Git. The joys and pitfalls of managing your Splunk deployment with Git. Copyright 2018

Enterprise Architecture CS 4720 Web & Mobile Systems

Sonatype CLM - Release Notes. Sonatype CLM - Release Notes

Revision control. INF5750/ Lecture 2 (Part I)

A Func'onal Introduc'on. COS 326 David Walker Princeton University

Using Git and GitLab: Your first steps. Maurício

Visualizing Git Workflows. A visual guide to 539 workflows

Lecture 6 Remotes. Sign in on the attendance sheet!

GUIDE TO MAKE A REAL CONTRIBUTION TO AN OPEN SOURCE PROJECT 1. 1

Sonatype CLM - IDE User Guide. Sonatype CLM - IDE User Guide

Version Control with Git ME 461 Fall 2018

Tutorial 2 GitHub Tutorial

Better Stories, Better Languages

Rights Cloud Connector Package Quick Install Guide

Linux System Management with Puppet, Gitlab, and R10k. Scott Nolin, SSEC Technical Computing 22 June 2017

CS 520: VCS and Git. Intermediate Topics Ben Kushigian

Baggy bounds checking. Periklis Akri5dis, Manuel Costa, Miguel Castro, Steven Hand

csc444h: so(ware engineering I matt medland

The Actual Real World at EclipseCon/ALM

Git and Gerrit Workflows. Enforcing Manual & Automated Review

CPSC 491. Lecture 19 & 20: Source Code Version Control. VCS = Version Control Software SCM = Source Code Management

A L A TEX-oriented intro to Git

Software configuration management

Software Development I

Using GitHub to Share with SparkFun a

Oracle VM Workshop Applica>on Driven Virtualiza>on

Microservices with Red Hat. JBoss Fuse

OpenEmbedded in the Real World

COSC 310: So*ware Engineering. Dr. Bowen Hui University of Bri>sh Columbia Okanagan

Tracking FreeBSD in a Commercial Environment

CLOUD SERVICES. Cloud Value Assessment.

New World BGP. Geoff Huston January2010 APNIC

Transcription:

Best Practices and Pitfalls for Building Products out of OpenDaylight Colin Dixon, TSC Chair, OpenDaylight Principal Software Engineer, Brocade Devin Avery, Sr Staff Software Engineer, Brocade

Agenda Agenda / Introduc5on Common Pi8alls Best Prac5ces Future Considera5ons Ques5ons

Our experience productizing OpenDaylight Brocade has released mul5ple versions of a controller for Brocade So far, based on Helium- SR1, Helium- SR2, and Helium- SR3 Rapidly approaching first Lithium- based release Running in produc5on with real customers We ve been successful in doing this even when incorpora5ng upstream changes Share our experiences - - pi8alls and successes

Common Pitfalls

wrong One way to build a release based on OpenDaylight Clone the OpenDaylight code (its public arer all!) Modify the code to customize / brand Add new code into the exis5ng projects for your proprietary logic Run the build Test, Ship and Sell it! Great, that was easy This is the first thing nearly everyone does

How (not) to build a custom fabric app and host tracker MyFabric App Flow Programming Host Tracking + MyFabric Δs Topology

This doesn t work! merely By cloning OpenDaylight code you have essen7ally forked the code! Synchronizing code with upstream can be difficult Your changes may not be accepted upstream (and you may not want them upstream) Pulling changes from upstream is likely to result in constant merge conflicts To avoid this pain, sync with upstream less oren => increases pain => even less oren Results in lower interac5on in community since code base is out of sync Don t get bug fixes, security patches, etc. OpenDaylight source code is licensed under EPL may put your proprietary changes at risk* *Note: we are not lawyers. Be sure to discuss any legal / licensing issues with your legal team

In Practice, this forking results in permanent divergence from upstream OpenDaylight That is, you no longer have an OpenDaylight-based product in most of the ways you and your customers care about.

Best Practices

Treat OpenDaylight as a Third-party Don t Download the OpenDaylight Source Code! Treat OpenDaylight as a collec5on read- only third- party ar5facts Reference ODL ar5facts, don t build them Leverage maven to access, maintain and manage your third- party dependencies for you For example: We don t recompile the basic java.u5l.arraylist Java class, we reference/use it We certainly don t modify the java.u5l.arraylist source code locally and build it

But OpenDaylight might not be a Third-party If you have modify OpenDaylight source code Push the changes upstream Wait for the next release major or stability Fold the changes in when bump your upstream versions What about cri5cal bugfixes/patches? Push the change upstream cherry-pick the patches into a locally- created clone of the upstream repo Build and release your own version of the relevant bundle(s) Note: this is complex and has risk, avoid it when possible.

Make changes to OpenDaylight upstream! We need OpenDaylight s core func5onality to succeed Otherwise our extensions, apps, etc. don t mamer You should Provide bug fixes Discuss new requirements Share implementa5ons, interfaces, extension points, etc. You will benefit from working more closely with upstream Get patches/fixes faster More likely have to have core OpenDaylight meet your needs faster Dave Neary on Swimming Upstream: hmp://www.slideshare.net/nearyd/swimming- upstream- 45666354

Leverage ODL Modularity / Isolate Proprietary Code Keep your proprietary code isolated to your own repositories, bundles, and Karaf features Leverage OSGi/Karaf/Maven to combine your code with OpenDaylight Leverage YANG/MD- SAL/Config system modularity to load proprietary implementa5ons into the modeling system OSGi is generally friendly with the EPL license* Exis5ng OpenDaylight Bundles Karaf MyFabric *Note: we are not lawyers. Be sure to discuss any legal / licensing issues with your legal team

Extension Example: Apps OpenDaylight Code/Bundles Your Proprietary Code/Bundles MyFabric App Flow Programming Host Tracking Topology

Extension Example: Replacing a Service Write an OSGi bundle that populates the Host Tracker YANG model OtherFabric App Exis5ng apps/services (either ODL or proprietary) will use the new implementa5on Flow Programming MyHostTracker Topology

Extension Example: Modifying an Existing Service OFVendorExt YANG OFVendorExt Java Flow Programming OtherFabric App Host Tracking Topology Augment exis5ng YANG models with new informa5on Provide Java code to extend behavior Requires Java extension points This is possible, but complex, needs thought and work Slides from ONS talk: hmp://colindixon.com/wp- content/uploads/2014/05/ YANG- good- bad- ugly- ONS- 2015.pdf

Stabilize Development Environment No to Snapshots! Don t build using OpenDaylight snapshots! We don t compile against beta versions of the JRE, we compile against released versions! Snapshots are vola5le, and change constantly. Harder to determine if failures are related to your code, or snapshot change Customers want stable ar5facts (won t run on snapshots) If you use snapshots, then your release is 5ed directly to OpenDaylight release If you have 5me, you can compile dev versions of your code against dev versions of OpenDaylight to scope out poten5al issues

Stabilize Development Environment No to Snapshots! Ex: Mul5ple Proprietary Releases T = 0 T = 1 T = 2 T = 3 T = 4 Your Company s Ar5facts C- 1 C- 2 C- 3 C- 4 C- 5 Released OpenDaylight Ar5facts (Stable) He He- 1 He- 2 He- 3 He- 4 Ac5ve OpenDaylight Development (Vola5le) He- 1 Dev He- 2 Dev He- 3 Dev He- 4 Dev He- 5 Dev

The Result A product which references OpenDaylight ar5facts Proprietary code is isolated, and can be updated without affec5ng OpenDaylight code Also poten5ally avoid legal/licensing pain (ASK YOUR LAWYERS!) Changing versions of OpenDaylight code is just an update to a version in a pom file and some tes5ng Allows for a stable OpenDaylight controller on which to build proprietary implementa5ons

Future Considerations

Focus more on our users Core Developer App/Bus Log Dev REST API Dev Administrator Operator User Interface REST API App/Business Logic MD- SAL/YANG South Bound Business Logic Meta- tasks, e.g., install & upgrade

Focus more on our users Core Developer App/Bus Log Dev REST API Dev Administrator Operator User Interface REST API App/Business Logic MD- SAL/YANG South Bound Business Logic Meta- tasks, e.g., install & upgrade

Example: Easy Upgrades for Users Upgrades are a MUST! Customers will not accept a reinstall/reconfigure story Upgrades in OpenDaylight are an ajerthought Upgrades need to be a requirement No tes7ng in OpenDaylight today! Some problem areas / considera5ons Configura5on & Implementa5on stored together We have configura5on op5ons and implementa5ons (classes, etc) defined in the same file. Out- of- the- box and customer configura5ons stored together If customer change behavior then we can no longer safely upgrade (replace) the file. Need to merge! expensive Upgrades not always backwards compa5ble with previous version

Example: Minimizing risk of updates Currently everything needs to stay in one major monolithic release Helium- SR1 vs Helium- SR2 Interoperability / co- existence is not tested We find security vulnerability in OpenFlow Patch OpenFlow Rebuild everything Release Helium- SR2 with the fix We ve also pulled in poten5ally changes to everything else and changed all versions Exis5ng OpenDaylight Bundles (He- SR1) MD- SAL (He- SR1) Karaf (All SR1) OF (He- SR1) Exis5ng OpenDaylight Bundles (He- SR2) MD- SAL (He- SR2) Karaf (All SR2) OF (He- SR2) MyFabric w/he- SR1 MyFabric w/he- SR2

Example: Minimizing risk of updates We would like to to be able to upgrade only what changed Fix the OF vulnerability, release it, don t have to worry about changes in everything This would allow Faster delivery of fixes and features Lower risk to adop5ng fixes and features Some complexity in tes5ng, compa5bility matrices, avoiding huge versions skew, etc. Karaf (All SR1) MD- SAL (He- SR1) OF (He- SR1) Karaf (SR1 + OF fix) MD- SAL (He- SR1) OF (He- SR1+fix) This is all that changed!! MyFabric w/he- SR1 MyFabric w/he- SR1

Conclusions Treat OpenDaylight as a third-party (don t fork it!) Leverage Karaf, Maven, OSGi, YANG, Config system for modularity We still need to do better at user focus Where user is core developer, app developer, REST API developer, operator, administrator, etc. Easy upgrades, more modularity, version compa5bility, etc.