[VOL-3187]Pass Context down the execution call hierarchy across ofagent codebase
Change-Id: Ia5f2fa1509beefe0ddc427b83e39d2702782db8f
diff --git a/internal/pkg/openflow/feature.go b/internal/pkg/openflow/feature.go
index d897958..7f3b557 100644
--- a/internal/pkg/openflow/feature.go
+++ b/internal/pkg/openflow/feature.go
@@ -25,10 +25,10 @@
"github.com/opencord/voltha-protos/v3/go/common"
)
-func (ofc *OFConnection) handleFeatureRequest(request *ofp.FeaturesRequest) error {
+func (ofc *OFConnection) handleFeatureRequest(ctx context.Context, request *ofp.FeaturesRequest) error {
if logger.V(log.DebugLevel) {
js, _ := json.Marshal(request)
- logger.Debugw("handleFeatureRequest called",
+ logger.Debugw(ctx, "handleFeatureRequest called",
log.Fields{
"device-id": ofc.DeviceID,
"request": js})
@@ -55,11 +55,11 @@
if logger.V(log.DebugLevel) {
js, _ := json.Marshal(reply)
- logger.Debugw("handleFeatureRequestReturn",
+ logger.Debugw(ctx, "handleFeatureRequestReturn",
log.Fields{
"device-id": ofc.DeviceID,
"reply": js})
}
- err = ofc.SendMessage(reply)
+ err = ofc.SendMessage(ctx, reply)
return err
}