SlideShare a Scribd company logo
Contribute to OpenNMS
DEV JAM 2019 

June 24, 2019 to June 28, 2019

Markus von Rüden
who | what | where | how
Who Am I
Involved with OpenNMS since end of 2012


Full time contributor for The OpenNMS
Project since March 2013
Stuttgart, DE
https://dev.marskuh.de

mvr@opennms.com

https://github.com/mvrueden
Joined ~2013
mvrueden // mvr

Markus von Rüden
Most Recent Contributions 

Bootstrap 4 Migration
Ulf Login Screen
Geocoder Config UI
Grafana Endpoint UI
Reporting UI (WIP)
Who contributes to the
OpenNMS project?
The OpenNMS Group (TOG)
Order of The Green Polo (OGP)
OpenNMS Community
What to contribute?
Documentation
Code
Configs
Report templates
Bug Reports
Knowledge
Features
Stories
Ideas
Games
Comics
Songs
Where to Contribute?
Chat GITHUB JIRADiscourse
Configuration, documentation, patches,
features
Knowledge
blogyoutube
Contribution Workflow
Create Issue
Checkout / Create
Branch
Make Changes
Create Pull
Request
Contributor
Member of TOG
ReviewBuild Pipeline
Merge to target
branch
Next Release*
* Horizon Releases are every 3rd Thursday
Create Issue // Important fields
Feature?
Bug?
Configuration?
Story
Bug
Configuration
Issue TypeIs it a
Don’t worry about the fields too much

we will fill them in for you
Summary
Affected Version
Description
Required fields
@ issues.opennms.org
Issue Workflow
OPEN
IN PROGRESS
IN REVIEW
RESOLVED/
CLOSED
Issue Created
Working on
Issue
Pull Request
created
Pull Request
merged
Set up your environment
latest JDK 8

Maven >= 3.5

PostgreSQL Server >= 9.5

makensis

Pearl

git
MAC OS Users 

https://opennms.discourse.group/t/set-up-local-development-environment-macos/485

Docker Build Image

https://hub.docker.com/r/opennms/build-env
jicmp, jicmp6 (optional)

https://github.com/OpenNMS/jicmp6

https://github.com/OpenNMS/jicmp
Git & Github
Create account @ https://github.com/join
Generate SSH Key

https://help.github.com/en/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent
Add SSH Key to your Account

https://help.github.com/en/enterprise/2.15/user/articles/adding-a-new-ssh-key-to-your-github-account
Optionally add GPG Key to your Account

https://help.github.com/en/articles/adding-a-new-gpg-key-to-your-github-account
Install git either via desktop.github.com or git command o/
Git Settings
Ensure git config —global
user.name and user.email are set
properly
Optionally sign the commits
The user.email should match any github user account email address
Please use real user name and email
address as it shows up in the
commit history
1
2
1
2
Code base // Github
• Code is hosted at GitHub

• Everything (https://github.com/OpenNMS)

• OpenNMS (https://github.com/OpenNMS/opennms)

• Patches, Config files, Documentation typo fixes, new documentation

• Only members of The OpenNMS Group and The Order of the Green Polo have
direct commit access

• There is a way for contribution —> Fork Project

• Questions: https://chat.opennms.org @ OpenNMS Development Channel
1. Go to the OpenNMS repository @ https://github.com/OpenNMS/opennms
3. Go to your fork of OpenNMS 

@ https://github.com/mvrueden/opennms
2. Fork OpenNMS
Forking the OpenNMS Project
Github Desktop Application works for Mac and Windows users
Download from https://desktop.github.com/
Clone your OpenNMS Repository @ https://github.com/mvrueden/opennms
Alternative git clone command

o/
Manually create pull request at https://github.com/OpenNMS/opennms/pulls/create and
compare across forks
Pull Request Magic
Choose base fork/branch and head fork/branch
OCA not signed?
Fill out https://wiki.opennms.org/wiki/images/6/6b/ContributorAgreement.pdf
send to oca@opennms.org
Tools
Atom.io
Visual Studio Code
Vi, Emacs, …
IntelliJ
Eclipse
yEd - Graph Editor
DataGrip - Database Tool
Development Single File / Documentation Others
Which base branch to use?
Meridian Horizon Branch
M2015 H14 foundation
bug fixes
M2016 H17 foundation-2016
M2017 H19 foundation-2017
M2018 H21 foundation-2018
M2019 TBA, most likely H25
foundation-2019
(not yet available)
- H24.1.1 release-24.1.1
next major release develop new features
Branch naming conventions
most branches jira/<issue-number> jira/NMS-1000
feature branches features/ features/graph-service
test branches <user-prefix>/ mvr/navbar-rework
Coding Conventions
• Always create JIRA issue first

• Only change what is in the focus of the issue

• No whitespace changes

• No re-arranging of imports

• Don’t comment obvious things

• Always provide test coveraged

• No issue required for small changes, such as typos or minor
documentation changes

• Always prefix commits with issue number

• No TODOs
Useful git commands
Git Cheat Sheet

https://opennms.discourse.group/t/git-cheat-sheet/602
General Build Steps
./clean.pl Deletes all target directory for root and
assembly projects
./compile.pl -DskipTests compiles project
./assemble.pl -p dir -DskipTests [-Dopennms.home=/opt/opennms] produces tar.gz distribution
time (./clean.pl && ./compile.pl -DskipTests && ./assemble.pl -Dopennms.home=/opt/opennms -
DskipTests); say "OpenNMS may be ready for deployment”
Takes roughly 15-20 Minutes if .m2 already
populated, otherwise hours
Run Individual Tests
Do a full build 

cd features/<my-feature>
mvn clean install -DskipTests
mvn test 

For the whole module, will not run ITs

mvn verify -DskipITs=false 

Runs Unit and Integration Tests



mvn clean test -Dtest=<myTest> -Dmaven.surefire.debug

mvn clean verify -DskipITs=false -Dit.test=<myIT> -Dmaven.failsafe.debug

This will also run all Unit Tests and the specified IT
Run Smoke Test
Always only run a single test. Never the whole suite!

Requires Firefox 45.0.2. Alternatively use Chrome, which requires chromedriver

Do a full build 

(or use mvn clean install -DskipTests --also-make)

cd smoke-test
mvn clean install -DskipTests 

(make sure it compiles)

mvn clean verify -Dsmoke=true -DskipITs=false -Dit.test=<myTest> [-Dmaven.failsafe.debug]
mvn clean verify -Dorg.opennms.smoketest.webdriver.use-chrome -D"chrome.path=/
Applications/Google Chrome.app/Contents/MacOS/Google Chrome" -DskipITs=false -
Dit.test=AngularLoginRedirectIT [-Dmaven.failsafe.debug]

(Run with Chrome instead of Firefox)
Run System Test
Always only run a single system test, never the whole suite

System Tests require the OpenNMS Docker Test images

Bamboo must have build them, otherwise this is going to be more tricky

Checkout repository 

https://github.com/OpenNMS/opennms-system-test-api

Modify accordingly

https://github.com/mvrueden/scripts/blob/master/opennms/system-tests.sh

Downloads the RPMs from Bamboo and builds the Docker Images

./system-tests.sh https://bamboo.opennms.org/browse/OPENNMS-OPENNMS57-2
mvn clean verify -Dorg.opennms.smoketest.docker=true -Dsmoke=true [-
Dorg.opennms.smoketest.docker.skipTearDown=true] -DskipITs=false -Dit.test=HealthCheckIT -
Dorg.opennms.advertised-host-address=192.168.2.158
• OpenNMS in Debug mode

$OPENNM_HOME/bin/opennms -t start

• If Docker Image, ensure Debug Port 8001 is
exposed

• Maven with debug options will open a port
on 5005

• Add a remote debug connection from your
IDE using port 8001 or 5005
bundle:watch *
• OpenNMS is most likely run as root

• link <root-home>/.m2/repository to <your-user>/.m2/
repository 

• ssh into OpenNMS’ Karaf Shell: ssh admin@localhost -p 8101

• bundle:watch *
• now do a mvn clean install -DskipTests of your maven module
(must be a bundle) and it will automatically be refreshed no rebuild
required
Only assemble.pl
Check all the root modules which have been changed

git status

Manually build each non bundle maven module (i.e. opennms-webapp)

mvn clean install -DskipTests
Stop OpenNMS, delete target and rerun 

./assemble.pl -p dir -DskipTests

Even faster

If only one jar changed, you can copy it to target/opennms-<version>/lib and
restart OpenNMS
UI Work
Most UI Work can be done without restarting or rebuilding 

(except Java changes or new Javascript Modules)

Java-Script changes

• Link jetty-webapps/opennms/assets to core/web-assets

•echo "org.opennms.web.assets.minified=false" > ${OPENNMS_HOME}/etc/
opennms.properties.d/assets.properties
• yarn build in core/web-assets on each change or yarn watch

JSP-Changes in opennms-webapp

rsync -auv src/main/webapp/ /Users/mvrueden/dev/opennms/drift2/target/
opennms-25.0.0-SNAPSHOT/jetty-webapps/opennms
Questions?
Where to go from here?
Developer Guide 

https://docs.opennms.org/opennms/branches/develop/guide-development/guide-
development.html

IntelliJ

https://wiki.opennms.org/wiki/IDEA_and_OpenNMS

Eclipse

https://wiki.opennms.org/wiki/Eclipse_and_OpenNMS

Issues

https://issues.opennms.org

Discourse

community.opennms.com

https://opennms.discourse.group/c/development

https://opennms.discourse.group/tags/devjam-2019

Chat

chat.opennms.com @ DEV JAM

Checkout the Github Repository

https://github.com/opennms/opennms
Git Cheat Sheet

https://opennms.discourse.group/t/git-cheat-sheet/602

More Related Content

What's hot

Github - Git Training Slides: Foundations
Github - Git Training Slides: FoundationsGithub - Git Training Slides: Foundations
Github - Git Training Slides: Foundations
Lee Hanxue
 
EclipseCon 2010 talk: Towards contributors heaven
EclipseCon 2010 talk: Towards contributors heavenEclipseCon 2010 talk: Towards contributors heaven
EclipseCon 2010 talk: Towards contributors heaven
msohn
 
Inside GitHub with Chris Wanstrath
Inside GitHub with Chris WanstrathInside GitHub with Chris Wanstrath
Inside GitHub with Chris Wanstrath
SV Ruby on Rails Meetup
 
git and github
git and githubgit and github
git and github
Darren Oakley
 
Resources For Floss Projects
Resources For Floss ProjectsResources For Floss Projects
Resources For Floss Projects
Jon Spriggs
 
Git and Github workshop
Git and Github workshopGit and Github workshop
Git and Github workshop
Otto Kekäläinen
 
Introduction to Git / Github
Introduction to Git / GithubIntroduction to Git / Github
Introduction to Git / Github
Paige Bailey
 
Git 101 for Beginners
Git 101 for Beginners Git 101 for Beginners
Git 101 for Beginners
Anurag Upadhaya
 
Git Introduction Tutorial
Git Introduction TutorialGit Introduction Tutorial
Git Introduction Tutorial
Thomas Rausch
 
Social Coding GitHub 2015
Social Coding GitHub 2015Social Coding GitHub 2015
Social Coding GitHub 2015
Kenu, GwangNam Heo
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
glen_a_smith
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github
Max Claus Nunes
 
Introduction to github using Egit
Introduction to github using EgitIntroduction to github using Egit
Introduction to github using Egit
matz_twt
 
Hello, Git!
Hello, Git!Hello, Git!
Introduction to Mercurial
Introduction to MercurialIntroduction to Mercurial
Introduction to Mercurial
digitalspaghetti
 
Builder and BuildKit
Builder and BuildKitBuilder and BuildKit
Builder and BuildKit
Moby Project
 
Git tutorial
Git tutorialGit tutorial
Git tutorial
Elli Kanal
 
Git training with Devaamo
Git training with DevaamoGit training with Devaamo
Git training with Devaamo
Otto Kekäläinen
 
Introduction to Git, DrupalCamp LA 2015
Introduction to Git, DrupalCamp LA 2015Introduction to Git, DrupalCamp LA 2015
Introduction to Git, DrupalCamp LA 2015
mwrather
 
Introduction to Version Control with GIT
Introduction to Version Control with GITIntroduction to Version Control with GIT
Introduction to Version Control with GIT
ismet özöztürk
 

What's hot (20)

Github - Git Training Slides: Foundations
Github - Git Training Slides: FoundationsGithub - Git Training Slides: Foundations
Github - Git Training Slides: Foundations
 
EclipseCon 2010 talk: Towards contributors heaven
EclipseCon 2010 talk: Towards contributors heavenEclipseCon 2010 talk: Towards contributors heaven
EclipseCon 2010 talk: Towards contributors heaven
 
Inside GitHub with Chris Wanstrath
Inside GitHub with Chris WanstrathInside GitHub with Chris Wanstrath
Inside GitHub with Chris Wanstrath
 
git and github
git and githubgit and github
git and github
 
Resources For Floss Projects
Resources For Floss ProjectsResources For Floss Projects
Resources For Floss Projects
 
Git and Github workshop
Git and Github workshopGit and Github workshop
Git and Github workshop
 
Introduction to Git / Github
Introduction to Git / GithubIntroduction to Git / Github
Introduction to Git / Github
 
Git 101 for Beginners
Git 101 for Beginners Git 101 for Beginners
Git 101 for Beginners
 
Git Introduction Tutorial
Git Introduction TutorialGit Introduction Tutorial
Git Introduction Tutorial
 
Social Coding GitHub 2015
Social Coding GitHub 2015Social Coding GitHub 2015
Social Coding GitHub 2015
 
Git One Day Training Notes
Git One Day Training NotesGit One Day Training Notes
Git One Day Training Notes
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github
 
Introduction to github using Egit
Introduction to github using EgitIntroduction to github using Egit
Introduction to github using Egit
 
Hello, Git!
Hello, Git!Hello, Git!
Hello, Git!
 
Introduction to Mercurial
Introduction to MercurialIntroduction to Mercurial
Introduction to Mercurial
 
Builder and BuildKit
Builder and BuildKitBuilder and BuildKit
Builder and BuildKit
 
Git tutorial
Git tutorialGit tutorial
Git tutorial
 
Git training with Devaamo
Git training with DevaamoGit training with Devaamo
Git training with Devaamo
 
Introduction to Git, DrupalCamp LA 2015
Introduction to Git, DrupalCamp LA 2015Introduction to Git, DrupalCamp LA 2015
Introduction to Git, DrupalCamp LA 2015
 
Introduction to Version Control with GIT
Introduction to Version Control with GITIntroduction to Version Control with GIT
Introduction to Version Control with GIT
 

Similar to Dev-Jam 2019 - Developing & Contributing to OpenNMS

NLUUG Spring 2012 - OpenShift Primer
NLUUG Spring 2012 - OpenShift PrimerNLUUG Spring 2012 - OpenShift Primer
NLUUG Spring 2012 - OpenShift Primer
Eric D. Schabell
 
OpenShift Primer - get your business into the Cloud today!
OpenShift Primer - get your business into the Cloud today!OpenShift Primer - get your business into the Cloud today!
OpenShift Primer - get your business into the Cloud today!
Eric D. Schabell
 
Write microservice in golang
Write microservice in golangWrite microservice in golang
Write microservice in golang
Bo-Yi Wu
 
Codemotion 2012 Rome - An OpenShift Primer
Codemotion 2012 Rome - An OpenShift PrimerCodemotion 2012 Rome - An OpenShift Primer
Codemotion 2012 Rome - An OpenShift Primer
Eric D. Schabell
 
Open source projects with python
Open source projects with pythonOpen source projects with python
Open source projects with python
roskakori
 
OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...
OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...
OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...
NETWAYS
 
Hacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginnersHacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginners
DeepikaRana30
 
CICD_1670665418.pdf
CICD_1670665418.pdfCICD_1670665418.pdf
CICD_1670665418.pdf
edsonJeancarloRuedaS
 
Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...
Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...
Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...
Nagios
 
Hackaton for health 2015 - Sharing the Code we Make
Hackaton for health 2015 - Sharing the Code we MakeHackaton for health 2015 - Sharing the Code we Make
Hackaton for health 2015 - Sharing the Code we Make
esben1962
 
Module 4_WorkinUnixLinuxCommandAndKeepDoing
Module 4_WorkinUnixLinuxCommandAndKeepDoingModule 4_WorkinUnixLinuxCommandAndKeepDoing
Module 4_WorkinUnixLinuxCommandAndKeepDoing
alhassanjawad1
 
Introduction To Docker
Introduction To DockerIntroduction To Docker
Introduction To Docker
Hamilton Turner
 
Magento Docker Setup.pdf
Magento Docker Setup.pdfMagento Docker Setup.pdf
Magento Docker Setup.pdf
Abid Malik
 
Git 101
Git 101Git 101
Bgoug 2019.11 building free, open-source, plsql products in cloud
Bgoug 2019.11   building free, open-source, plsql products in cloudBgoug 2019.11   building free, open-source, plsql products in cloud
Bgoug 2019.11 building free, open-source, plsql products in cloud
Jacek Gebal
 
Vagrant and puppet: Deployment made easy
Vagrant and puppet: Deployment made easyVagrant and puppet: Deployment made easy
Vagrant and puppet: Deployment made easy
Geronimo Orozco
 
Lean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and DrushLean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and Drush
Pantheon
 
VM vs Docker-Based Pipelines
VM vs Docker-Based PipelinesVM vs Docker-Based Pipelines
VM vs Docker-Based Pipelines
Codefresh
 
Luis atencio on_git
Luis atencio on_gitLuis atencio on_git
Luis atencio on_git
Luis Atencio
 
Open up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubOpen up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHub
Scott Graham
 

Similar to Dev-Jam 2019 - Developing & Contributing to OpenNMS (20)

NLUUG Spring 2012 - OpenShift Primer
NLUUG Spring 2012 - OpenShift PrimerNLUUG Spring 2012 - OpenShift Primer
NLUUG Spring 2012 - OpenShift Primer
 
OpenShift Primer - get your business into the Cloud today!
OpenShift Primer - get your business into the Cloud today!OpenShift Primer - get your business into the Cloud today!
OpenShift Primer - get your business into the Cloud today!
 
Write microservice in golang
Write microservice in golangWrite microservice in golang
Write microservice in golang
 
Codemotion 2012 Rome - An OpenShift Primer
Codemotion 2012 Rome - An OpenShift PrimerCodemotion 2012 Rome - An OpenShift Primer
Codemotion 2012 Rome - An OpenShift Primer
 
Open source projects with python
Open source projects with pythonOpen source projects with python
Open source projects with python
 
OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...
OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...
OSDC 2016 - Continous Integration in Data Centers - Further 3 Years later by ...
 
Hacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginnersHacktoberfest 2020 - Open source for beginners
Hacktoberfest 2020 - Open source for beginners
 
CICD_1670665418.pdf
CICD_1670665418.pdfCICD_1670665418.pdf
CICD_1670665418.pdf
 
Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...
Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...
Nagios Conference 2014 - Spenser Reinhardt - Detecting Security Breaches With...
 
Hackaton for health 2015 - Sharing the Code we Make
Hackaton for health 2015 - Sharing the Code we MakeHackaton for health 2015 - Sharing the Code we Make
Hackaton for health 2015 - Sharing the Code we Make
 
Module 4_WorkinUnixLinuxCommandAndKeepDoing
Module 4_WorkinUnixLinuxCommandAndKeepDoingModule 4_WorkinUnixLinuxCommandAndKeepDoing
Module 4_WorkinUnixLinuxCommandAndKeepDoing
 
Introduction To Docker
Introduction To DockerIntroduction To Docker
Introduction To Docker
 
Magento Docker Setup.pdf
Magento Docker Setup.pdfMagento Docker Setup.pdf
Magento Docker Setup.pdf
 
Git 101
Git 101Git 101
Git 101
 
Bgoug 2019.11 building free, open-source, plsql products in cloud
Bgoug 2019.11   building free, open-source, plsql products in cloudBgoug 2019.11   building free, open-source, plsql products in cloud
Bgoug 2019.11 building free, open-source, plsql products in cloud
 
Vagrant and puppet: Deployment made easy
Vagrant and puppet: Deployment made easyVagrant and puppet: Deployment made easy
Vagrant and puppet: Deployment made easy
 
Lean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and DrushLean Drupal Repositories with Composer and Drush
Lean Drupal Repositories with Composer and Drush
 
VM vs Docker-Based Pipelines
VM vs Docker-Based PipelinesVM vs Docker-Based Pipelines
VM vs Docker-Based Pipelines
 
Luis atencio on_git
Luis atencio on_gitLuis atencio on_git
Luis atencio on_git
 
Open up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubOpen up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHub
 

More from Ronny Trommer

DevJam 2019 - OpenNMS Integration API
DevJam 2019 - OpenNMS Integration APIDevJam 2019 - OpenNMS Integration API
DevJam 2019 - OpenNMS Integration API
Ronny Trommer
 
DevJam 2019 - Introduction to Kubernetes
DevJam 2019 - Introduction to KubernetesDevJam 2019 - Introduction to Kubernetes
DevJam 2019 - Introduction to Kubernetes
Ronny Trommer
 
Dev-Jam 2019 - New since Dev-Jam 2018
Dev-Jam 2019 - New since Dev-Jam 2018Dev-Jam 2019 - New since Dev-Jam 2018
Dev-Jam 2019 - New since Dev-Jam 2018
Ronny Trommer
 
Dev-Jam 2019 - Container & OpenNMS
Dev-Jam 2019 - Container & OpenNMSDev-Jam 2019 - Container & OpenNMS
Dev-Jam 2019 - Container & OpenNMS
Ronny Trommer
 
Dev-Jam 2019 - Developing OpenNMS on Apache Karaf
Dev-Jam 2019 - Developing OpenNMS on Apache KarafDev-Jam 2019 - Developing OpenNMS on Apache Karaf
Dev-Jam 2019 - Developing OpenNMS on Apache Karaf
Ronny Trommer
 
DevJam 2019 - Building an ALEC Time Engine
DevJam 2019 - Building an ALEC Time EngineDevJam 2019 - Building an ALEC Time Engine
DevJam 2019 - Building an ALEC Time Engine
Ronny Trommer
 
OUCE Reporting Enhancements in OpenNMS
OUCE Reporting Enhancements in OpenNMSOUCE Reporting Enhancements in OpenNMS
OUCE Reporting Enhancements in OpenNMS
Ronny Trommer
 
Who Pulls the Strings?
Who Pulls the Strings?Who Pulls the Strings?
Who Pulls the Strings?
Ronny Trommer
 
OSMC 2011 - Introduction to OpenNMS
OSMC 2011 - Introduction to OpenNMSOSMC 2011 - Introduction to OpenNMS
OSMC 2011 - Introduction to OpenNMS
Ronny Trommer
 

More from Ronny Trommer (9)

DevJam 2019 - OpenNMS Integration API
DevJam 2019 - OpenNMS Integration APIDevJam 2019 - OpenNMS Integration API
DevJam 2019 - OpenNMS Integration API
 
DevJam 2019 - Introduction to Kubernetes
DevJam 2019 - Introduction to KubernetesDevJam 2019 - Introduction to Kubernetes
DevJam 2019 - Introduction to Kubernetes
 
Dev-Jam 2019 - New since Dev-Jam 2018
Dev-Jam 2019 - New since Dev-Jam 2018Dev-Jam 2019 - New since Dev-Jam 2018
Dev-Jam 2019 - New since Dev-Jam 2018
 
Dev-Jam 2019 - Container & OpenNMS
Dev-Jam 2019 - Container & OpenNMSDev-Jam 2019 - Container & OpenNMS
Dev-Jam 2019 - Container & OpenNMS
 
Dev-Jam 2019 - Developing OpenNMS on Apache Karaf
Dev-Jam 2019 - Developing OpenNMS on Apache KarafDev-Jam 2019 - Developing OpenNMS on Apache Karaf
Dev-Jam 2019 - Developing OpenNMS on Apache Karaf
 
DevJam 2019 - Building an ALEC Time Engine
DevJam 2019 - Building an ALEC Time EngineDevJam 2019 - Building an ALEC Time Engine
DevJam 2019 - Building an ALEC Time Engine
 
OUCE Reporting Enhancements in OpenNMS
OUCE Reporting Enhancements in OpenNMSOUCE Reporting Enhancements in OpenNMS
OUCE Reporting Enhancements in OpenNMS
 
Who Pulls the Strings?
Who Pulls the Strings?Who Pulls the Strings?
Who Pulls the Strings?
 
OSMC 2011 - Introduction to OpenNMS
OSMC 2011 - Introduction to OpenNMSOSMC 2011 - Introduction to OpenNMS
OSMC 2011 - Introduction to OpenNMS
 

Recently uploaded

How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfHow to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
Chart Kalyan
 
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - HiikeSystem Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
Hiike
 
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStrDeep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
saastr
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
Zilliz
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
innovationoecd
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
Octavian Nadolu
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
alexjohnson7307
 
Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!
GDSC PJATK
 
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying AheadDigital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Wask
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
Tomaz Bratanic
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
Jakub Marek
 
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...
Tatiana Kojar
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
MichaelKnudsen27
 
Monitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdfMonitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdf
Tosin Akinosho
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Alpen-Adria-Universität
 
Skybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoptionSkybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoption
Tatiana Kojar
 
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Jeffrey Haguewood
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 

Recently uploaded (20)

How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfHow to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
 
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - HiikeSystem Design Case Study: Building a Scalable E-Commerce Platform - Hiike
System Design Case Study: Building a Scalable E-Commerce Platform - Hiike
 
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStrDeep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
 
Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!
 
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying AheadDigital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying Ahead
 
GraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracyGraphRAG for Life Science to increase LLM accuracy
GraphRAG for Life Science to increase LLM accuracy
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
 
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
 
Monitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdfMonitoring and Managing Anomaly Detection on OpenShift.pdf
Monitoring and Managing Anomaly Detection on OpenShift.pdf
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
 
Skybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoptionSkybuffer SAM4U tool for SAP license adoption
Skybuffer SAM4U tool for SAP license adoption
 
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 

Dev-Jam 2019 - Developing & Contributing to OpenNMS

  • 1. Contribute to OpenNMS DEV JAM 2019 
 June 24, 2019 to June 28, 2019 Markus von Rüden who | what | where | how
  • 2. Who Am I Involved with OpenNMS since end of 2012 
 Full time contributor for The OpenNMS Project since March 2013 Stuttgart, DE https://dev.marskuh.de
 mvr@opennms.com
 https://github.com/mvrueden Joined ~2013 mvrueden // mvr
 Markus von Rüden Most Recent Contributions 
 Bootstrap 4 Migration Ulf Login Screen Geocoder Config UI Grafana Endpoint UI Reporting UI (WIP)
  • 3. Who contributes to the OpenNMS project? The OpenNMS Group (TOG) Order of The Green Polo (OGP) OpenNMS Community
  • 4. What to contribute? Documentation Code Configs Report templates Bug Reports Knowledge Features Stories Ideas Games Comics Songs
  • 5. Where to Contribute? Chat GITHUB JIRADiscourse Configuration, documentation, patches, features Knowledge blogyoutube
  • 6. Contribution Workflow Create Issue Checkout / Create Branch Make Changes Create Pull Request Contributor Member of TOG ReviewBuild Pipeline Merge to target branch Next Release* * Horizon Releases are every 3rd Thursday
  • 7. Create Issue // Important fields Feature? Bug? Configuration? Story Bug Configuration Issue TypeIs it a Don’t worry about the fields too much
 we will fill them in for you Summary Affected Version Description Required fields @ issues.opennms.org
  • 8. Issue Workflow OPEN IN PROGRESS IN REVIEW RESOLVED/ CLOSED Issue Created Working on Issue Pull Request created Pull Request merged
  • 9. Set up your environment latest JDK 8 Maven >= 3.5 PostgreSQL Server >= 9.5 makensis Pearl git MAC OS Users 
 https://opennms.discourse.group/t/set-up-local-development-environment-macos/485
 Docker Build Image
 https://hub.docker.com/r/opennms/build-env jicmp, jicmp6 (optional)
 https://github.com/OpenNMS/jicmp6
 https://github.com/OpenNMS/jicmp
  • 10. Git & Github Create account @ https://github.com/join Generate SSH Key
 https://help.github.com/en/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent Add SSH Key to your Account
 https://help.github.com/en/enterprise/2.15/user/articles/adding-a-new-ssh-key-to-your-github-account Optionally add GPG Key to your Account
 https://help.github.com/en/articles/adding-a-new-gpg-key-to-your-github-account Install git either via desktop.github.com or git command o/
  • 11. Git Settings Ensure git config —global user.name and user.email are set properly Optionally sign the commits The user.email should match any github user account email address Please use real user name and email address as it shows up in the commit history 1 2 1 2
  • 12. Code base // Github • Code is hosted at GitHub • Everything (https://github.com/OpenNMS) • OpenNMS (https://github.com/OpenNMS/opennms) • Patches, Config files, Documentation typo fixes, new documentation • Only members of The OpenNMS Group and The Order of the Green Polo have direct commit access • There is a way for contribution —> Fork Project • Questions: https://chat.opennms.org @ OpenNMS Development Channel
  • 13. 1. Go to the OpenNMS repository @ https://github.com/OpenNMS/opennms 3. Go to your fork of OpenNMS 
 @ https://github.com/mvrueden/opennms 2. Fork OpenNMS Forking the OpenNMS Project
  • 14. Github Desktop Application works for Mac and Windows users Download from https://desktop.github.com/ Clone your OpenNMS Repository @ https://github.com/mvrueden/opennms Alternative git clone command
 o/
  • 15. Manually create pull request at https://github.com/OpenNMS/opennms/pulls/create and compare across forks Pull Request Magic Choose base fork/branch and head fork/branch
  • 16. OCA not signed? Fill out https://wiki.opennms.org/wiki/images/6/6b/ContributorAgreement.pdf send to oca@opennms.org
  • 17. Tools Atom.io Visual Studio Code Vi, Emacs, … IntelliJ Eclipse yEd - Graph Editor DataGrip - Database Tool Development Single File / Documentation Others
  • 18. Which base branch to use? Meridian Horizon Branch M2015 H14 foundation bug fixes M2016 H17 foundation-2016 M2017 H19 foundation-2017 M2018 H21 foundation-2018 M2019 TBA, most likely H25 foundation-2019 (not yet available) - H24.1.1 release-24.1.1 next major release develop new features
  • 19. Branch naming conventions most branches jira/<issue-number> jira/NMS-1000 feature branches features/ features/graph-service test branches <user-prefix>/ mvr/navbar-rework
  • 20. Coding Conventions • Always create JIRA issue first • Only change what is in the focus of the issue • No whitespace changes • No re-arranging of imports • Don’t comment obvious things • Always provide test coveraged • No issue required for small changes, such as typos or minor documentation changes • Always prefix commits with issue number • No TODOs
  • 21. Useful git commands Git Cheat Sheet
 https://opennms.discourse.group/t/git-cheat-sheet/602
  • 22. General Build Steps ./clean.pl Deletes all target directory for root and assembly projects ./compile.pl -DskipTests compiles project ./assemble.pl -p dir -DskipTests [-Dopennms.home=/opt/opennms] produces tar.gz distribution time (./clean.pl && ./compile.pl -DskipTests && ./assemble.pl -Dopennms.home=/opt/opennms - DskipTests); say "OpenNMS may be ready for deployment” Takes roughly 15-20 Minutes if .m2 already populated, otherwise hours
  • 23. Run Individual Tests Do a full build cd features/<my-feature> mvn clean install -DskipTests mvn test 
 For the whole module, will not run ITs mvn verify -DskipITs=false 
 Runs Unit and Integration Tests
 
 mvn clean test -Dtest=<myTest> -Dmaven.surefire.debug mvn clean verify -DskipITs=false -Dit.test=<myIT> -Dmaven.failsafe.debug
 This will also run all Unit Tests and the specified IT
  • 24. Run Smoke Test Always only run a single test. Never the whole suite! Requires Firefox 45.0.2. Alternatively use Chrome, which requires chromedriver Do a full build 
 (or use mvn clean install -DskipTests --also-make) cd smoke-test mvn clean install -DskipTests 
 (make sure it compiles) mvn clean verify -Dsmoke=true -DskipITs=false -Dit.test=<myTest> [-Dmaven.failsafe.debug] mvn clean verify -Dorg.opennms.smoketest.webdriver.use-chrome -D"chrome.path=/ Applications/Google Chrome.app/Contents/MacOS/Google Chrome" -DskipITs=false - Dit.test=AngularLoginRedirectIT [-Dmaven.failsafe.debug]
 (Run with Chrome instead of Firefox)
  • 25. Run System Test Always only run a single system test, never the whole suite System Tests require the OpenNMS Docker Test images Bamboo must have build them, otherwise this is going to be more tricky Checkout repository 
 https://github.com/OpenNMS/opennms-system-test-api Modify accordingly
 https://github.com/mvrueden/scripts/blob/master/opennms/system-tests.sh Downloads the RPMs from Bamboo and builds the Docker Images
 ./system-tests.sh https://bamboo.opennms.org/browse/OPENNMS-OPENNMS57-2 mvn clean verify -Dorg.opennms.smoketest.docker=true -Dsmoke=true [- Dorg.opennms.smoketest.docker.skipTearDown=true] -DskipITs=false -Dit.test=HealthCheckIT - Dorg.opennms.advertised-host-address=192.168.2.158
  • 26. • OpenNMS in Debug mode
 $OPENNM_HOME/bin/opennms -t start • If Docker Image, ensure Debug Port 8001 is exposed • Maven with debug options will open a port on 5005 • Add a remote debug connection from your IDE using port 8001 or 5005
  • 27. bundle:watch * • OpenNMS is most likely run as root • link <root-home>/.m2/repository to <your-user>/.m2/ repository • ssh into OpenNMS’ Karaf Shell: ssh admin@localhost -p 8101 • bundle:watch * • now do a mvn clean install -DskipTests of your maven module (must be a bundle) and it will automatically be refreshed no rebuild required
  • 28. Only assemble.pl Check all the root modules which have been changed
 git status Manually build each non bundle maven module (i.e. opennms-webapp)
 mvn clean install -DskipTests Stop OpenNMS, delete target and rerun 
 ./assemble.pl -p dir -DskipTests Even faster
 If only one jar changed, you can copy it to target/opennms-<version>/lib and restart OpenNMS
  • 29. UI Work Most UI Work can be done without restarting or rebuilding 
 (except Java changes or new Javascript Modules) Java-Script changes • Link jetty-webapps/opennms/assets to core/web-assets •echo "org.opennms.web.assets.minified=false" > ${OPENNMS_HOME}/etc/ opennms.properties.d/assets.properties • yarn build in core/web-assets on each change or yarn watch JSP-Changes in opennms-webapp
 rsync -auv src/main/webapp/ /Users/mvrueden/dev/opennms/drift2/target/ opennms-25.0.0-SNAPSHOT/jetty-webapps/opennms
  • 31. Where to go from here? Developer Guide 
 https://docs.opennms.org/opennms/branches/develop/guide-development/guide- development.html IntelliJ
 https://wiki.opennms.org/wiki/IDEA_and_OpenNMS Eclipse
 https://wiki.opennms.org/wiki/Eclipse_and_OpenNMS Issues
 https://issues.opennms.org Discourse
 community.opennms.com
 https://opennms.discourse.group/c/development
 https://opennms.discourse.group/tags/devjam-2019 Chat
 chat.opennms.com @ DEV JAM Checkout the Github Repository
 https://github.com/opennms/opennms Git Cheat Sheet
 https://opennms.discourse.group/t/git-cheat-sheet/602