deep dive into the rocks - events.static.linuxfound.org · a technical problem ! lessons i should...
TRANSCRIPT
![Page 1: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/1.jpg)
CCC 2014 DENVER
! Background
! Community development
! A technical problem
! Lessons I should have learned
DEEP DIVE INTO THE ROCKS
![Page 2: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/2.jpg)
CCC 2014 DENVER
! Work @ Schuberg Philis since 1.8 years
! Hobby: triathlon http://myfirstnorseman.onecht.net/ Also as a jury, coach and some others
! Email: [email protected] Twitter: SambalTriathlon (don’t use) Facebook: +/- 3 accounts (lurked@best) plus.google: DaanHoogland (hardly used)
ABOUT ME
![Page 3: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/3.jpg)
CCC 2014 DENVER
! This presentation is aimed at beginning open source or cloudstack developer whether proficient in programming or not.
! It might be interesting to cloudstack veterans that are looking to improve development process of the community, be it by improving their own way of contributing or adjusting the processes we use.
AUDIENCE
![Page 4: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/4.jpg)
CCC 2014 DENVER
HOW TO GET INVOLVED
![Page 5: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/5.jpg)
CCC 2014 DENVER
HOW GETTING A PATCH ACCEPTED IN THE COMMUNITY
IS SIMILAR TO GETTING YOU ACCEPTED
![Page 6: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/6.jpg)
CCC 2014 DENVER
HOW NOT TO GET INVOLVED
![Page 7: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/7.jpg)
CCC 2014 DENVER
PICK A GREAT REFACTORING JOB THAT IS EXTENDING
INTO THE ENTIRE SYSTEM AND TRY TO TELL PEOPLE
HOW TO DO IT
![Page 8: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/8.jpg)
CCC 2014 DENVER
\\EBI\DAAN:~> LS -LTRA DOWNLOADS/0001-SDN-HOSTED-VPC-GATEWAYS-USING-LSWITCH.PATCH -RW-R--R--@ 1 DAAN STAFF 347998 MAR 26 11:12 DOWNLOADS/0001-SDN-HOSTED-VPC-GATEWAYS-USING-
LSWITCH.PATCH .
![Page 9: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/9.jpg)
CCC 2014 DENVER
IMPORTANT THINGS TO CONTRIBUTE WHEN GETTING INVOLVED
![Page 10: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/10.jpg)
CCC 2014 DENVER
# CODE # MAIL THE LIST # CODE # INTERACTION THROUGH THE REVIEW BOARD # FS ON THE WIKI (FS BUT ALSO TS!) # GOOD CODE # RAT CHECKSTYLE FINDBUGS # CODE # JIRA # DOCS # (SELFDOCUMENTING) CODE.
![Page 11: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/11.jpg)
CCC 2014 DENVER
# CODE # MAIL THE LIST # CODE # INTERACTION THROUGH THE REVIEW BOARD # FS ON THE WIKI (FS BUT ALSO TS!) # GOOD CODE # RAT CHECKSTYLE FINDBUGS # CODE # JIRA # DOCS # (SELFDOCUMENTING) CODE
![Page 12: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/12.jpg)
CCC 2014 DENVER
# CODE # MAIL THE LIST # CODE # INTERACTION THROUGH THE REVIEW BOARD # FS ON THE WIKI (FS BUT ALSO TS!) # GOOD CODE # RAT CHECKSTYLE FINDBUGS # CODE # JIRA # DOCS # (SELFDOCUMENTING) CODE
![Page 13: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/13.jpg)
CCC 2014 DENVER
THE CUSTOMER PROBLEM
![Page 14: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/14.jpg)
CCC 2014 DENVER
THE CUSTOMER REQUEST
MENU
Add the possibility to leverage the new Nicira NVP functionality
to hook the private-gateway of VPC routers on to each other
![Page 15: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/15.jpg)
CCC 2014 DENVER
THE ENVISIONED SOLUTION
![Page 16: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/16.jpg)
CCC 2014 DENVER
THE CORE CODE
http://localhost:8080/client/api? command=createPrivateGateway &response=json &sessionkey=xxx &physicalnetworkid=c71e08e7-c01d-4840-bd74-ffab517053fc &vpcid=be9acb3c-20eb-4e34-ab4c-3275185a9028 &ipaddress=10.10.10.2 &gateway=10.10.10.1 &netmask=255.255.255.0 &vlan=lswitch%3A%2F%2F3
![Page 17: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/17.jpg)
CCC 2014 DENVER
A cross cutting concern:
!vlan and vlanid are encoded all over and used interchangably
! originally only numbers but also as uri
! 123 equals vlan://123
PROBLEM ANALYSIS
![Page 18: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/18.jpg)
CCC 2014 DENVER
SOLUTIONS enum versus registration of types
![Page 19: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/19.jpg)
CCC 2014 DENVER
! no uuid à id mapping available
A THOUGHT
![Page 20: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/20.jpg)
CCC 2014 DENVER
WHY THIS IS A PROBLEM
isolation types/uris and broadcast types where designed into the system but there was no way to map a vlan on one of them and the
meaning of the two was lost so only BroadcastDomainType got my attention
![Page 21: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/21.jpg)
CCC 2014 DENVER
stt (nicira nvp) networks where added next came midonet
then a whole lot more how they did it
![Page 22: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/22.jpg)
CCC 2014 DENVER
Lswitch("lswitch", String.class) { @Override public <T> URI toUri(T value) { try { return new URI("lswitch", value.toString(), null, null); } catch (URISyntaxException e) { throw new CloudRuntimeException("Unable to convert to broadcast URI: " + value); } } /** * gets scheme specific part instead of host */ @Override public String getValueFrom(URI uri) { return uri.getSchemeSpecificPart(); } },
![Page 23: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/23.jpg)
CCC 2014 DENVER
vlan vlanid vlannumber vlanuri broadcastDomainUri broadcastDomainId
![Page 24: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/24.jpg)
CCC 2014 DENVER
- public String getVlanId() { - return vlanId; + public String getBroadcastUri() { + return broadcastUri;
![Page 25: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/25.jpg)
CCC 2014 DENVER
BroadcastDomainType Vs
IsolationType
![Page 26: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/26.jpg)
CCC 2014 DENVER
- nic.setIsolationUri(IsolationType.Vlan.toUri(ip.getVlanTag())); - nic.setBroadcastUri(IsolationType.Vlan.toUri(ip.getVlanTag())); + nic.setIsolationUri(IsolationType.Vlan.toUri(ip.getBroadcastUri())); + nic.setBroadcastUri(IsolationType.Vlan.toUri(ip.getBroadcastUri()));
![Page 27: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/27.jpg)
CCC 2014 DENVER
long vnetId = Long.parseLong(BroadcastDomainType.getValue(uri)); long vlan = Long.parseLong(broadcastUri.getHost()); long vlan = Long.parseLong(BroadcastDomainType.getValue(uri));
![Page 28: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/28.jpg)
CCC 2014 DENVER
HOW TO PROCEED NEXT make uuid à id mapping?
register uri types including format instead of enum
![Page 29: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/29.jpg)
CCC 2014 DENVER
WORK TO BE DONE the result of this work is not ideal, so I am hoping to get feedback
on possible improvements
![Page 30: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/30.jpg)
CCC 2014 DENVER
CONCLUSIONS
![Page 31: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/31.jpg)
CCC 2014 DENVER
![Page 32: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/32.jpg)
CCC 2014 DENVER
introduce yourself by proving you can do one thing good at a time
introduce your change by making the small
preliminaries that pave the way
![Page 33: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/33.jpg)
CCC 2014 DENVER
work on a branch and do it publicly
submit a lot of parts to master
ACS should find a way to make this possible for non committers in a gerrit or github way
![Page 34: DEEP DIVE INTO THE ROCKS - events.static.linuxfound.org · A technical problem ! Lessons I should have learned DEEP DIVE INTO THE ROCKS ... where designed into the system but there](https://reader033.vdocuments.site/reader033/viewer/2022042810/5f9b698601f45117da7da124/html5/thumbnails/34.jpg)
CCC 2014 DENVER
SIMILARITIES
PATCH PERSON small changes that build on each other
bring one thing to a good conclusion before you start another
communicate both the immediate and the end goal
be true to your ideals but pragmatic about the work to be done
not everybody that doesn’t say it is a good idea hates it
in general: you are accepted unless.. not if..
don’t break other code you’re right. that doesn’t mean others are wrong