This commit add object cleanup to be consistent with similar code in
the kubernetes plugin.
It also does a clone of the EndpointSlice labels so that it's not erased by
the function `EndpointSliceToEndpoints` from the kubernetes plugin fixing an
important bug in the multicluster code as it was previously not able to
retrieve any labels which essentially prevented any interaction with headless
services.
Signed-off-by: Arthur Outhenin-Chalandre <arthur@cri.epita.fr>
* Add go.mod
Signed-off-by: Arthur Outhenin-Chalandre <arthur@cri.epita.fr>
* Refactor the object to share kubernetes plugin objects
It also removed the unused watch endpointslicev1beta1 functions,
make sure everything is gofmt-ed and rewrite the import for consistency
across the plugin code.
Signed-off-by: Arthur Outhenin-Chalandre <arthur@cri.epita.fr>
* Add clusterId check in endpointsEquivalent
Signed-off-by: Arthur Outhenin-Chalandre <arthur@cri.epita.fr>
---------
Signed-off-by: Arthur Outhenin-Chalandre <arthur@cri.epita.fr>