From fe606ab64824c39be821892c937f87cf4088f5f4 Mon Sep 17 00:00:00 2001
From: NThakur4 <nthakur4@slb.com>
Date: Tue, 14 Feb 2023 14:59:28 -0600
Subject: [PATCH] attribution

---
 .../ISubscriberNotificationRequestLogger.java   | 17 ++++++++++++++++-
 .../service/NotificationHandler.java            |  2 +-
 .../SubscriberNotificationRequestLogger.java    | 14 ++++++++++++++
 3 files changed, 31 insertions(+), 2 deletions(-)

diff --git a/notification-core/src/main/java/org/opengroup/osdu/notification/provider/interfaces/ISubscriberNotificationRequestLogger.java b/notification-core/src/main/java/org/opengroup/osdu/notification/provider/interfaces/ISubscriberNotificationRequestLogger.java
index 698e349cf..15b03b7f1 100644
--- a/notification-core/src/main/java/org/opengroup/osdu/notification/provider/interfaces/ISubscriberNotificationRequestLogger.java
+++ b/notification-core/src/main/java/org/opengroup/osdu/notification/provider/interfaces/ISubscriberNotificationRequestLogger.java
@@ -1,9 +1,24 @@
+// Copyright © Schlumberger
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
 package org.opengroup.osdu.notification.provider.interfaces;
 
 import org.opengroup.osdu.core.common.http.HttpResponse;
+import org.opengroup.osdu.core.common.model.notification.Subscription;
 
 public interface ISubscriberNotificationRequestLogger {
 
-    default void log(String notificationId, String endpoint, HttpResponse response) {
+    default void log(String notificationId, Subscription subscription, HttpResponse response) {
     }
 }
diff --git a/notification-core/src/main/java/org/opengroup/osdu/notification/service/NotificationHandler.java b/notification-core/src/main/java/org/opengroup/osdu/notification/service/NotificationHandler.java
index bbda79e41..ea3c86e78 100644
--- a/notification-core/src/main/java/org/opengroup/osdu/notification/service/NotificationHandler.java
+++ b/notification-core/src/main/java/org/opengroup/osdu/notification/service/NotificationHandler.java
@@ -79,7 +79,7 @@ public class NotificationHandler {
         HttpRequest request = HttpRequest.post().url(pushUrl).headers(requestHeader).body(pubsubMessage).connectionTimeout(WAITING_TIME).build();
         this.LOGGER.debug("Sending out notification to endpoint: " + endpoint);
         HttpResponse response = httpClient.send(request);
-        subscriberNotificationRequestLogger.log(notificationId, endpoint, response);
+        subscriberNotificationRequestLogger.log(notificationId, subscription, response);
         return response;
     }
 }
\ No newline at end of file
diff --git a/provider/notification-azure/src/main/java/org/opengroup/osdu/notification/provider/azure/util/SubscriberNotificationRequestLogger.java b/provider/notification-azure/src/main/java/org/opengroup/osdu/notification/provider/azure/util/SubscriberNotificationRequestLogger.java
index e05e8f485..eb00756f7 100644
--- a/provider/notification-azure/src/main/java/org/opengroup/osdu/notification/provider/azure/util/SubscriberNotificationRequestLogger.java
+++ b/provider/notification-azure/src/main/java/org/opengroup/osdu/notification/provider/azure/util/SubscriberNotificationRequestLogger.java
@@ -1,3 +1,17 @@
+// Copyright © Schlumberger
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
 package org.opengroup.osdu.notification.provider.azure.util;
 
 import org.opengroup.osdu.azure.logging.DependencyLogger;
-- 
GitLab