mlab-lattice / lattice

Apache License 2.0
1 stars 3 forks source link

initialize ServiceBuild.Sidecars in mock #219

Closed robcarlan-mlab closed 5 years ago

robcarlan-mlab commented 5 years ago

https://github.com/mlab-lattice/lattice/blob/ccf20e4c268e29316086685e74d3221adc001346/pkg/backend/kubernetes/api/server/backend/build.go#L274-L278

It looks like the backend api initialises ServiceBuild.Sidecars, whereas this is null in the mock. Also removed a duplicate assignment.

abdulito commented 5 years ago

Looks good mate. Just wondering about the dup init of sidecards

robcarlan-mlab commented 5 years ago

Ah yeah, you are right - I removed that extra one.

kevindrosendahl commented 5 years ago

i think i would actually rather do the opposite - have it be the expected behavior of the api to omit the sidecars map if it would be empty.

this will be the case 99% of the time and will improve readability

kevindrosendahl commented 5 years ago

note what i've described above is implemented in https://github.com/mlab-lattice/lattice/pull/220

robcarlan-mlab commented 5 years ago

Sweet, that works