)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"564b736286dfffdf82d5c1a34cb320f50d705eca","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This commit reimplements the kuryr-cni, that is the actual CNI plugin"},{"line_number":10,"context_line":"that gets called by kubelet and passes the request to kuryr-daemon, in"},{"line_number":11,"context_line":"golang. This means that it can injected as a binary without any"},{"line_number":12,"context_line":"dependencies, instead of using a bash script that looks for ID of"},{"line_number":13,"context_line":"kuryr-daemon container and does `docker exec` to run Python kuryr-cni"},{"line_number":14,"context_line":"inside. The obvious advantage of that is removing a constraint of"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"9fb8cfa7_76fe876c","line":11,"range":{"start_line":11,"start_character":31,"end_line":11,"end_character":39},"updated":"2019-06-18 09:26:34.000000000","message":"be injected","commit_id":"245eb078f40def87d37fb64a8101edf538200383"}],"cni.Dockerfile":[{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"7e4923d8c4b9f47e80d5d14a3336f2bc12efc6b2","unresolved":false,"context_lines":[{"line_number":1,"context_line":"FROM golang:1.11 AS builder"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"WORKDIR /go/src/opendev.com/kuryr-kubernetes"},{"line_number":4,"context_line":"COPY . ."}],"source_content_type":"text/x-dockerfile","patch_set":2,"id":"9fb8cfa7_6148e7cb","line":1,"updated":"2019-06-04 23:20:45.000000000","message":"Any reason for going with 1.11 instead of 1.12? Are the cni golang libraries compatible with 1.12\u0027s go module management?\n\nSome context: https://github.com/golang/dep/issues/1959\n\nI think it would really make sense to use 1.11 or 1.12\u0027s go modules.","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"bc8d7f47dc8d768d7878429d962260f134b9fb0e","unresolved":false,"context_lines":[{"line_number":1,"context_line":"FROM golang:1.11 AS builder"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"WORKDIR /go/src/opendev.com/kuryr-kubernetes"},{"line_number":4,"context_line":"COPY . ."}],"source_content_type":"text/x-dockerfile","patch_set":2,"id":"9fb8cfa7_327236e5","line":1,"in_reply_to":"9fb8cfa7_2fcc1160","updated":"2019-06-05 10:01:24.000000000","message":"Great","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"069b42ab32fcbee3c7541498e75df00ccd4a60c2","unresolved":false,"context_lines":[{"line_number":1,"context_line":"FROM golang:1.11 AS builder"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"WORKDIR /go/src/opendev.com/kuryr-kubernetes"},{"line_number":4,"context_line":"COPY . ."}],"source_content_type":"text/x-dockerfile","patch_set":2,"id":"9fb8cfa7_6fea09ad","line":1,"in_reply_to":"9fb8cfa7_4fb625fd","updated":"2019-06-05 08:47:10.000000000","message":"Okay, I see, 1.11 requires setting GO111MODULE\u003don (surprisingly GO111MODULE\u003dauto doesn\u0027t work on 1.12?).\n\nThe switch seems to be just:\n\n go mod init\n rm -rf vendor Gopkg.*\n\nI think we can easily make the switch later on, once we\u0027ll make sure it\u0027ll work in every channel Kuryr is built in.","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"eee916149ad1aa77790b79f2a70039ac3bcb576c","unresolved":false,"context_lines":[{"line_number":1,"context_line":"FROM golang:1.11 AS builder"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"WORKDIR /go/src/opendev.com/kuryr-kubernetes"},{"line_number":4,"context_line":"COPY . ."}],"source_content_type":"text/x-dockerfile","patch_set":2,"id":"9fb8cfa7_4fb625fd","line":1,"in_reply_to":"9fb8cfa7_6148e7cb","updated":"2019-06-05 08:36:14.000000000","message":"OpenShift currently builds from 1.10 by default, I think 1.11 is also available. I can try switching from dep to go modules. Are there any incompatibilities in this matter in terms of 1.11 and 1.12?","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"de49925fd2f51e3d1939cbb12365aa1abf932ac8","unresolved":false,"context_lines":[{"line_number":1,"context_line":"FROM golang:1.11 AS builder"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"WORKDIR /go/src/opendev.com/kuryr-kubernetes"},{"line_number":4,"context_line":"COPY . ."}],"source_content_type":"text/x-dockerfile","patch_set":2,"id":"9fb8cfa7_2fcc1160","line":1,"in_reply_to":"9fb8cfa7_6fea09ad","updated":"2019-06-05 08:47:43.000000000","message":"Ah, and I tested switching to modules locally with 1.12 and it worked.","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"}],"kuryr_cni/main.go":[{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"7e4923d8c4b9f47e80d5d14a3336f2bc12efc6b2","unresolved":false,"context_lines":[{"line_number":50,"context_line":"\t\t\t\t\t\t\t\tIps struct {"},{"line_number":51,"context_line":"\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":52,"context_line":"\t\t\t\t\t\t\t\t\t\tObjects []struct {"},{"line_number":53,"context_line":"\t\t\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":54,"context_line":"\t\t\t\t\t\t\t\t\t\t\t\tAddress string `json:\"address\"`"},{"line_number":55,"context_line":"\t\t\t\t\t\t\t\t\t\t\t} `json:\"versioned_object.data\"`"},{"line_number":56,"context_line":"\t\t\t\t\t\t\t\t\t\t} `json:\"objects\"`"}],"source_content_type":"text/x-go","patch_set":2,"id":"9fb8cfa7_c1699325","line":53,"updated":"2019-06-04 23:20:45.000000000","message":"This is deeper than the Marian trench. I wonder if at some point we could somehow code generate this struct.","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"7a828adcb27d0e7aae7b8d5014101e7943f1cc81","unresolved":false,"context_lines":[{"line_number":50,"context_line":"\t\t\t\t\t\t\t\tIps struct {"},{"line_number":51,"context_line":"\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":52,"context_line":"\t\t\t\t\t\t\t\t\t\tObjects []struct {"},{"line_number":53,"context_line":"\t\t\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":54,"context_line":"\t\t\t\t\t\t\t\t\t\t\t\tAddress string `json:\"address\"`"},{"line_number":55,"context_line":"\t\t\t\t\t\t\t\t\t\t\t} `json:\"versioned_object.data\"`"},{"line_number":56,"context_line":"\t\t\t\t\t\t\t\t\t\t} `json:\"objects\"`"}],"source_content_type":"text/x-go","patch_set":2,"id":"9fb8cfa7_afe462ad","line":53,"in_reply_to":"9fb8cfa7_1277f2d6","updated":"2019-06-06 14:30:59.000000000","message":"You\u0027ve sent me down to the golang reflection API, but I was able to flatten it a bit, see ovo.go in new patch.","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"bc8d7f47dc8d768d7878429d962260f134b9fb0e","unresolved":false,"context_lines":[{"line_number":50,"context_line":"\t\t\t\t\t\t\t\tIps struct {"},{"line_number":51,"context_line":"\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":52,"context_line":"\t\t\t\t\t\t\t\t\t\tObjects []struct {"},{"line_number":53,"context_line":"\t\t\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":54,"context_line":"\t\t\t\t\t\t\t\t\t\t\t\tAddress string `json:\"address\"`"},{"line_number":55,"context_line":"\t\t\t\t\t\t\t\t\t\t\t} `json:\"versioned_object.data\"`"},{"line_number":56,"context_line":"\t\t\t\t\t\t\t\t\t\t} `json:\"objects\"`"}],"source_content_type":"text/x-go","patch_set":2,"id":"9fb8cfa7_1277f2d6","line":53,"in_reply_to":"9fb8cfa7_a33b3f36","updated":"2019-06-05 10:01:24.000000000","message":"maybe with the custom unmarshalling. This article has good coverage: https://blog.gopheracademy.com/advent-2016/advanced-encoding-decoding/\n\nI was thinking about the \"Custom types for specific fields\" approach","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"eee916149ad1aa77790b79f2a70039ac3bcb576c","unresolved":false,"context_lines":[{"line_number":50,"context_line":"\t\t\t\t\t\t\t\tIps struct {"},{"line_number":51,"context_line":"\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":52,"context_line":"\t\t\t\t\t\t\t\t\t\tObjects []struct {"},{"line_number":53,"context_line":"\t\t\t\t\t\t\t\t\t\t\tVersionedObjectData struct {"},{"line_number":54,"context_line":"\t\t\t\t\t\t\t\t\t\t\t\tAddress string `json:\"address\"`"},{"line_number":55,"context_line":"\t\t\t\t\t\t\t\t\t\t\t} `json:\"versioned_object.data\"`"},{"line_number":56,"context_line":"\t\t\t\t\t\t\t\t\t\t} `json:\"objects\"`"}],"source_content_type":"text/x-go","patch_set":2,"id":"9fb8cfa7_a33b3f36","line":53,"in_reply_to":"9fb8cfa7_c1699325","updated":"2019-06-05 08:36:14.000000000","message":"I don\u0027t like it as well. I think I should be able to \"flatten\" it by removing all the VersionedObjectData stuff, though I\u0027m not really sure how difficult that is to write with golang as typed language.","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"7e4923d8c4b9f47e80d5d14a3336f2bc12efc6b2","unresolved":false,"context_lines":[{"line_number":109,"context_line":""},{"line_number":110,"context_line":"\t// FIXME(dulek): We don\u0027t really have a good way to fetch current URL:port binding here."},{"line_number":111,"context_line":"\t//               I\u0027m hardcoding it for now, but in the future we should probably put it in"},{"line_number":112,"context_line":"\t//               the JSON config in 10-kuryr.conf file that we will get passed on stdin."},{"line_number":113,"context_line":"\turlBase :\u003d \"http://localhost:50036/\""},{"line_number":114,"context_line":"\turl :\u003d urlBase + \"addNetwork\""},{"line_number":115,"context_line":"\tif data.Command \u003d\u003d \"DEL\" {"}],"source_content_type":"text/x-go","patch_set":2,"id":"9fb8cfa7_e19e1706","line":112,"updated":"2019-06-04 23:20:45.000000000","message":"Putting it in cni config sounds good","commit_id":"c099a4e473eadd758e32fc881354216386e60aa6"},{"author":{"_account_id":23567,"name":"Luis Tomas Bolivar","email":"ltomasbo@redhat.com","username":"ltomasbo"},"change_message_id":"a982a6b615f9100eb915bd72e16922ead93631f4","unresolved":false,"context_lines":[{"line_number":64,"context_line":"\t//               I\u0027m hardcoding it for now, but in the future we should probably put it in"},{"line_number":65,"context_line":"\t//               the JSON config in 10-kuryr.conf file that we will get passed on stdin."},{"line_number":66,"context_line":"\turlBase :\u003d \"http://localhost:5036/\""},{"line_number":67,"context_line":"\turl :\u003d urlBase + \"addNetwork\""},{"line_number":68,"context_line":"\tif data.Command \u003d\u003d \"DEL\" {"},{"line_number":69,"context_line":"\t\turl \u003d urlBase + \"delNetwork\""},{"line_number":70,"context_line":"\t}"},{"line_number":71,"context_line":"\tresp, err :\u003d http.Post(url, \"application/json\", bytes.NewBuffer(b))"},{"line_number":72,"context_line":"\tif err !\u003d nil {"},{"line_number":73,"context_line":"\t\treturn []byte{}, errors.Wrapf(err, \"Looks like %s cannot be reached. Is kuryr-daemon running?\", url)"}],"source_content_type":"text/x-go","patch_set":5,"id":"9fb8cfa7_d6cee5b2","line":70,"range":{"start_line":67,"start_character":0,"end_line":70,"end_character":2},"updated":"2019-06-10 07:02:25.000000000","message":"unlike python, go have switch command. Should we use it here instead of assuming that if command is not DEL it must be ADD? Perhaps in the future something extra may be added and better to be explicit about ADD/DEL","commit_id":"ac9ae18cf237cea2f37dbbcdc08a492eff06a1a1"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"2934a5568efa9ab21d525ebc845825e6e3ac1977","unresolved":false,"context_lines":[{"line_number":64,"context_line":"\t//               I\u0027m hardcoding it for now, but in the future we should probably put it in"},{"line_number":65,"context_line":"\t//               the JSON config in 10-kuryr.conf file that we will get passed on stdin."},{"line_number":66,"context_line":"\turlBase :\u003d \"http://localhost:5036/\""},{"line_number":67,"context_line":"\turl :\u003d urlBase + \"addNetwork\""},{"line_number":68,"context_line":"\tif data.Command \u003d\u003d \"DEL\" {"},{"line_number":69,"context_line":"\t\turl \u003d urlBase + \"delNetwork\""},{"line_number":70,"context_line":"\t}"},{"line_number":71,"context_line":"\tresp, err :\u003d http.Post(url, \"application/json\", bytes.NewBuffer(b))"},{"line_number":72,"context_line":"\tif err !\u003d nil {"},{"line_number":73,"context_line":"\t\treturn []byte{}, errors.Wrapf(err, \"Looks like %s cannot be reached. Is kuryr-daemon running?\", url)"}],"source_content_type":"text/x-go","patch_set":5,"id":"9fb8cfa7_561675f3","line":70,"range":{"start_line":67,"start_character":0,"end_line":70,"end_character":2},"in_reply_to":"9fb8cfa7_d6cee5b2","updated":"2019-06-10 07:20:59.000000000","message":"Fair point.","commit_id":"ac9ae18cf237cea2f37dbbcdc08a492eff06a1a1"},{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"7a7e05f7e7f7d05b0b11973b5595ddb88f1b50f4","unresolved":false,"context_lines":[{"line_number":167,"context_line":"\t\t\troutes \u003d append(routes, \u0026types.Route{Dst: *dst, GW: gw})"},{"line_number":168,"context_line":"\t\t}"},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"\t\tdns.Nameservers \u003d append(dns.Nameservers, subnet.DNS...)"},{"line_number":171,"context_line":"\t}"},{"line_number":172,"context_line":""},{"line_number":173,"context_line":"\tres :\u003d \u0026current.Result{"}],"source_content_type":"text/x-go","patch_set":6,"id":"9fb8cfa7_16cf8656","line":170,"updated":"2019-06-11 08:23:16.000000000","message":"How comes the loop is gone?","commit_id":"8dc7862ee14636ee82ff7428a618c7a2d5eb51bb"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"21478be6991ce13e05ebf5c9c943d08b44d4c8fd","unresolved":false,"context_lines":[{"line_number":167,"context_line":"\t\t\troutes \u003d append(routes, \u0026types.Route{Dst: *dst, GW: gw})"},{"line_number":168,"context_line":"\t\t}"},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"\t\tdns.Nameservers \u003d append(dns.Nameservers, subnet.DNS...)"},{"line_number":171,"context_line":"\t}"},{"line_number":172,"context_line":""},{"line_number":173,"context_line":"\tres :\u003d \u0026current.Result{"}],"source_content_type":"text/x-go","patch_set":6,"id":"9fb8cfa7_70532f3a","line":170,"in_reply_to":"9fb8cfa7_16cf8656","updated":"2019-06-13 16:16:14.000000000","message":"I misunderstood the structure, it turns out subnet.DNS is ListOfIPAddressField, which will be translated into a simple string[].","commit_id":"8dc7862ee14636ee82ff7428a618c7a2d5eb51bb"}],"kuryr_cni/ovo.go":[{"author":{"_account_id":14352,"name":"Antoni Segura Puimedon","email":"celebdor@gmail.com","username":"toni"},"change_message_id":"7a7e05f7e7f7d05b0b11973b5595ddb88f1b50f4","unresolved":false,"context_lines":[{"line_number":75,"context_line":"\t\t\t\tbreak"},{"line_number":76,"context_line":"\t\t\t}"},{"line_number":77,"context_line":"\t\t\t// If we have a slice and d[key] is just a simple list, then struct\u0027s approach will work fine, that\u0027s"},{"line_number":78,"context_line":"\t\t\t// why there\u0027s this fallthrough."},{"line_number":79,"context_line":"\t\t\tfallthrough"},{"line_number":80,"context_line":"\t\tcase reflect.Struct:"},{"line_number":81,"context_line":"\t\t\t// Treat it as struct"}],"source_content_type":"text/x-go","patch_set":6,"id":"9fb8cfa7_1626a616","line":78,"updated":"2019-06-11 08:23:16.000000000","message":"Does this deal with multi level OVOs? I would have expected some recursion to be necessary.","commit_id":"8dc7862ee14636ee82ff7428a618c7a2d5eb51bb"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"21478be6991ce13e05ebf5c9c943d08b44d4c8fd","unresolved":false,"context_lines":[{"line_number":75,"context_line":"\t\t\t\tbreak"},{"line_number":76,"context_line":"\t\t\t}"},{"line_number":77,"context_line":"\t\t\t// If we have a slice and d[key] is just a simple list, then struct\u0027s approach will work fine, that\u0027s"},{"line_number":78,"context_line":"\t\t\t// why there\u0027s this fallthrough."},{"line_number":79,"context_line":"\t\t\tfallthrough"},{"line_number":80,"context_line":"\t\tcase reflect.Struct:"},{"line_number":81,"context_line":"\t\t\t// Treat it as struct"}],"source_content_type":"text/x-go","patch_set":6,"id":"9fb8cfa7_907903c9","line":78,"in_reply_to":"9fb8cfa7_1626a616","updated":"2019-06-13 16:16:14.000000000","message":"Running json.Marshall() and json.Unmarshal() on the remaining payload in lines 87 and 93 serves as recursion. A bit weird, but I think that might be the only way to skip levels of JSON.","commit_id":"8dc7862ee14636ee82ff7428a618c7a2d5eb51bb"}]}
