[VOL-3649] Reading endpoint from config
Change-Id: I2e79e2d3a038ade5de89cca51f04004512f7718b
diff --git a/VERSION b/VERSION
index fa52388..097bb1e 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.1.14-dev141
+0.1.14-dev142
diff --git a/cmd/openonu-adapter/main.go b/cmd/openonu-adapter/main.go
index 59e9a0e..878e619 100644
--- a/cmd/openonu-adapter/main.go
+++ b/cmd/openonu-adapter/main.go
@@ -288,7 +288,7 @@
Version: version.VersionInfo.Version,
// TODO once we'll be ready to support multiple versions of the adapter
// the Endpoint will have to change to `brcm_openomci_onu_<currentReplica`>
- Endpoint: "brcm_openomci_onu",
+ Endpoint: a.config.Topic,
Type: "brcm_openomci_onu",
CurrentReplica: int32(a.config.CurrentReplica),
TotalReplicas: int32(a.config.TotalReplicas),
diff --git a/internal/pkg/onuadaptercore/omci_cc.go b/internal/pkg/onuadaptercore/omci_cc.go
index f53479f..33560d9 100644
--- a/internal/pkg/onuadaptercore/omci_cc.go
+++ b/internal/pkg/onuadaptercore/omci_cc.go
@@ -505,8 +505,8 @@
omciMsg := &ic.InterAdapterOmciMessage{Message: omciTxRequest.txFrame}
if sendErr := oo.adapterProxy.SendInterAdapterMessage(context.Background(), omciMsg,
ic.InterAdapterMessageType_OMCI_REQUEST,
- //fromType,toType,toDevId, ProxyDevId
- oo.pBaseDeviceHandler.DeviceType, oo.pBaseDeviceHandler.ProxyAddressType,
+ //fromTopic,toType,toDevId, ProxyDevId
+ oo.pOnuDeviceEntry.baseDeviceHandler.pOpenOnuAc.config.Topic, oo.pBaseDeviceHandler.ProxyAddressType,
oo.deviceID, oo.pBaseDeviceHandler.ProxyAddressID, ""); sendErr != nil {
logger.Errorw("send omci request error", log.Fields{"ChildId": oo.deviceID, "error": sendErr})
return sendErr