[VOL-1385] : Changes to support ONU delete
 Tested with,
1. ONU disable->delete
2. ONU delete
3. OLT delete

Change-Id: I8e6ff41a7ea8e94014700f274cb24fea73ac41f4
diff --git a/rw_core/core/adapter_proxy.go b/rw_core/core/adapter_proxy.go
index b7798ad..f6e9867 100755
--- a/rw_core/core/adapter_proxy.go
+++ b/rw_core/core/adapter_proxy.go
@@ -612,3 +612,33 @@
 	log.Debugw("enablePort-response", log.Fields{"device-id": device.Id, "port-no": port.PortNo, "success": success})
 	return unPackResponse(rpc, device.Id, success, result)
 }
+
+// ChildDeviceLost invokes Child device_lost rpc
+func (ap *AdapterProxy) ChildDeviceLost(ctx context.Context, deviceType string, pDeviceID string, pPortNo uint32, onuID uint32) error {
+	log.Debugw("ChildDeviceLost", log.Fields{"pDeviceId": pDeviceID, "pPortNo": pPortNo, "onuID": onuID})
+	rpc := "child_device_lost"
+	toTopic := ap.getAdapterTopic(deviceType)
+	dID := &ic.StrType{Val: pDeviceID}
+	PortNo := &ic.IntType{Val: int64(pPortNo)}
+	oID := &ic.IntType{Val: int64(onuID)}
+	args := []*kafka.KVArg{
+		{
+			Key:   "pDeviceId",
+			Value: dID,
+		},
+		{
+			Key:   "pPortNo",
+			Value: PortNo,
+		},
+		{
+			Key:   "onuID",
+			Value: oID,
+		}}
+
+	// Use a device specific topic as we are the only core handling requests for this device
+	replyToTopic := ap.getCoreTopic()
+	success, result := ap.kafkaICProxy.InvokeRPC(ctx, rpc, &toTopic, &replyToTopic, true, pDeviceID, args...)
+	log.Debugw("ChildDeviceLost-response", log.Fields{"pDeviceId": pDeviceID, "success": success})
+
+	return unPackResponse(rpc, pDeviceID, success, result)
+}