onosproject / onos-config

Configuration subsystem for ONOS (µONOS Architecture)
45 stars 55 forks source link

Pass a Context explicitly to each function - use receiver type functions #172

Closed adibrastegarnia closed 5 years ago

adibrastegarnia commented 5 years ago

I think gnmi southbound client manager needs the following changes:

  1. According to the Go documents: Do not store Contexts inside a struct type; instead, pass a Context explicitly to each function that needs it. So in the clientmanager implementation the context should be passed to the functions which need it.

  2. We should use the receiver pointer and value functions to avoid sending target as an argument to the functions.

tomikazi commented 5 years ago

I'd retitle to be more specific (to give a better idea from the issue's list)

Andrea-Campanella commented 5 years ago

@adibrastegarnia I think you had a patch for this on the previous enos-config repo living under opennetworkinglab. Coudl you move it over to hear ? thanks!

adibrastegarnia commented 5 years ago

@Andrea-Campanella Yes. My plan is to open a pull request soon and you can review it from there.

adibrastegarnia commented 5 years ago

closed #183