DEEP DIVE INTO THE ROCKS Background Community development A - - PowerPoint PPT Presentation

deep dive into the rocks background community development
SMART_READER_LITE
LIVE PREVIEW

DEEP DIVE INTO THE ROCKS Background Community development A - - PowerPoint PPT Presentation

CCC 2014 DENVER DEEP DIVE INTO THE ROCKS Background Community development A technical problem Lessons I should have learned CCC 2014 DENVER ABOUT ME Work @ Schuberg Philis since 1.8 years Hobby: triathlon http:/


slide-1
SLIDE 1

CCC 2014 DENVER

Background Community development A technical problem Lessons I should have learned DEEP DIVE INTO THE ROCKS

slide-2
SLIDE 2

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: dahn@apache.org Twitter: SambalTriathlon (don’t use) Facebook: +/- 3 accounts (lurked@best) plus.google: DaanHoogland (hardly used) ABOUT ME

slide-3
SLIDE 3

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

slide-4
SLIDE 4

CCC 2014 DENVER

HOW TO GET INVOLVED

slide-5
SLIDE 5

CCC 2014 DENVER

HOW GETTING A PATCH ACCEPTED IN THE COMMUNITY IS SIMILAR TO GETTING YOU ACCEPTED

slide-6
SLIDE 6

CCC 2014 DENVER

HOW NOT TO GET INVOLVED

slide-7
SLIDE 7

CCC 2014 DENVER

PICK A GREAT REFACTORING JOB THAT IS EXTENDING INTO THE ENTIRE SYSTEM AND TRY TO TELL PEOPLE HOW TO DO IT

slide-8
SLIDE 8

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

.

slide-9
SLIDE 9

CCC 2014 DENVER

IMPORTANT THINGS TO CONTRIBUTE WHEN GETTING INVOLVED

slide-10
SLIDE 10

CCC 2014 DENVER

# C O D E # M A I L T H E L I S T # C O D E # I N T E R A C T I O N T H R O U G H T H E R E V I E W B O A R D # F S O N T H E W I K I ( F S B U T A L S O T S ! ) # G O O D C O D E # R A T C H E C K S T Y L E F I N D B U G S # C O D E # J I R A # D O C S # ( S E L F D O C U M E N T I N G ) C O D E .

slide-11
SLIDE 11

CCC 2014 DENVER

# C O D E # M A I L T H E L I S T # C O D E # I N T E R A C T I O N T H R O U G H T H E R E V I E W B O A R D # F S O N T H E W I K I ( F S B U T A L S O T S ! ) # G O O D C O D E # R A T C H E C K S T Y L E F I N D B U G S # C O D E # J I R A # D O C S # ( S E L F D O C U M E N T I N G ) C O D E

slide-12
SLIDE 12

CCC 2014 DENVER

# C O D E # M A I L T H E L I S T # C O D E # I N T E R A C T I O N T H R O U G H T H E R E V I E W B O A R D # F S O N T H E W I K I ( F S B U T A L S O T S ! ) # G O O D C O D E # R A T C H E C K S T Y L E F I N D B U G S # C O D E # J I R A # D O C S # ( S E L F D O C U M E N T I N G ) C O D E

slide-13
SLIDE 13

CCC 2014 DENVER

THE CUSTOMER PROBLEM

slide-14
SLIDE 14

CCC 2014 DENVER

THE CUSTOMER REQUEST

Add the possibility to leverage the new Nicira NVP functionality to hook the private-gateway

  • f VPC routers on to each other
slide-15
SLIDE 15

CCC 2014 DENVER

THE ENVISIONED SOLUTION

slide-16
SLIDE 16

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

slide-17
SLIDE 17

CCC 2014 DENVER

A cross cutting concern: vlan and vlanid are encoded all over and used interchangably

  • riginally only numbers but also as uri

123 equals vlan:/ /123 PROBLEM ANAL YSIS

slide-18
SLIDE 18

CCC 2014 DENVER

SOLUTIONS enum versus registration of types

slide-19
SLIDE 19

CCC 2014 DENVER

no uuid à id mapping available

A THOUGHT

slide-20
SLIDE 20

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

slide-21
SLIDE 21

CCC 2014 DENVER

stt (nicira nvp) networks where added next came midonet then a whole lot more how they did it

slide-22
SLIDE 22

CCC 2014 DENVER

Lswitch("lswitch", String.clas class) { ) { @Override public <T> URI public <T> URI toUri

  • Uri(T v

(T value alue) { ) { try { try { return ne eturn new URI(" w URI("ls lswit witch ch", ", value alue.toS

  • String

tring(), null, null); (), null, null); } ca catch ( ch (URIS URISyntaxEx yntaxException eption e e) { ) { thr throw ne new w CloudRuntimeEx CloudRuntimeException eption(" ("Unable Unable t to

  • con
  • nvert

ert t to

  • br

broadcas

  • adcast URI: " + v

URI: " + value alue); ); } } /** * gets scheme specific part instead of host */ @Override

slide-23
SLIDE 23

CCC 2014 DENVER

vlan vlanid vlannumber vlanuri broadcastDomainUri broadcastDomainId

slide-24
SLIDE 24

CCC 2014 DENVER

  • public String getVlanId() {
  • return vlanId;

+ public String getBroadcastUri() { + return broadcastUri;

slide-25
SLIDE 25

CCC 2014 DENVER

BroadcastDomainType Vs IsolationType

slide-26
SLIDE 26

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()));

slide-27
SLIDE 27

CCC 2014 DENVER

long vnetId = Long.parseLong(BroadcastDomainType.getValue(uri)); long long vlan vlan = = Long.parseL

  • ng.parseLong
  • ng(br

broadcas

  • adcastUri.

tUri.getHos getHost()); ()); long long vlan vlan = = Long.

  • ng.parseL

parseLong

  • ng(Br

Broadcas

  • adcastDomainT

tDomainType ype.getV getValue alue(uri uri)); ));

slide-28
SLIDE 28

CCC 2014 DENVER

HOW TO PROCEED NEXT make uuid à id mapping? register uri types including format instead of enum

slide-29
SLIDE 29

CCC 2014 DENVER

WORK TO BE DONE the result of this work is not ideal, so I am hoping to get feedback

  • n possible improvements
slide-30
SLIDE 30

CCC 2014 DENVER

CONCLUSIONS

slide-31
SLIDE 31

CCC 2014 DENVER

slide-32
SLIDE 32

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

slide-33
SLIDE 33

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

slide-34
SLIDE 34

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