Merge "NONRTRIC - Implement DMaaP mediator producer service in Java"
diff --git a/dmaap-adaptor-java/src/main/java/org/oran/dmaapadapter/controllers/ProducerCallbacksController.java b/dmaap-adaptor-java/src/main/java/org/oran/dmaapadapter/controllers/ProducerCallbacksController.java
index 4d99c58..d4fe95c 100644
--- a/dmaap-adaptor-java/src/main/java/org/oran/dmaapadapter/controllers/ProducerCallbacksController.java
+++ b/dmaap-adaptor-java/src/main/java/org/oran/dmaapadapter/controllers/ProducerCallbacksController.java
@@ -95,13 +95,10 @@
     })
     public ResponseEntity<Object> jobDeletedCallback( //
             @PathVariable("infoJobId") String infoJobId) {
-        try {
-            logger.info("Job deleted callback {}", infoJobId);
-            this.jobs.remove(infoJobId);
-            return new ResponseEntity<>(HttpStatus.OK);
-        } catch (Exception e) {
-            return ErrorResponse.create(e, HttpStatus.NOT_FOUND);
-        }
+
+        logger.info("Job deleted callback {}", infoJobId);
+        this.jobs.remove(infoJobId);
+        return new ResponseEntity<>(HttpStatus.OK);
     }
 
     @GetMapping(path = SUPERVISION_URL, produces = MediaType.APPLICATION_JSON_VALUE)
diff --git a/dmaap-adaptor-java/src/test/java/org/oran/dmaapadapter/ApplicationTest.java b/dmaap-adaptor-java/src/test/java/org/oran/dmaapadapter/ApplicationTest.java
index aa300c5..cbaa59f 100644
--- a/dmaap-adaptor-java/src/test/java/org/oran/dmaapadapter/ApplicationTest.java
+++ b/dmaap-adaptor-java/src/test/java/org/oran/dmaapadapter/ApplicationTest.java
@@ -22,6 +22,7 @@
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.awaitility.Awaitility.await;
+import static org.junit.jupiter.api.Assertions.assertTrue;
 
 import com.google.gson.JsonParser;
 
@@ -42,7 +43,9 @@
 import org.oran.dmaapadapter.configuration.ImmutableWebClientConfig;
 import org.oran.dmaapadapter.configuration.WebClientConfig;
 import org.oran.dmaapadapter.configuration.WebClientConfig.HttpProxyConfig;
+import org.oran.dmaapadapter.controllers.ProducerCallbacksController;
 import org.oran.dmaapadapter.r1.ConsumerJobInfo;
+import org.oran.dmaapadapter.r1.ProducerJobInfo;
 import org.oran.dmaapadapter.repository.InfoType;
 import org.oran.dmaapadapter.repository.InfoTypes;
 import org.oran.dmaapadapter.repository.Jobs;
@@ -56,9 +59,14 @@
 import org.springframework.boot.web.servlet.server.ServletWebServerFactory;
 import org.springframework.context.annotation.Bean;
 import org.springframework.http.HttpStatus;
+import org.springframework.http.MediaType;
 import org.springframework.http.ResponseEntity;
 import org.springframework.test.context.TestPropertySource;
 import org.springframework.test.context.junit.jupiter.SpringExtension;
+import org.springframework.web.reactive.function.client.WebClientResponseException;
+
+import reactor.core.publisher.Mono;
+import reactor.test.StepVerifier;
 
 @ExtendWith(SpringExtension.class)
 @SpringBootTest(webEnvironment = WebEnvironment.DEFINED_PORT)
@@ -87,6 +95,8 @@
     @Autowired
     private EcsSimulatorController ecsSimulatorController;
 
+    private com.google.gson.Gson gson = new com.google.gson.GsonBuilder().create();
+
     @LocalServerPort
     int localServerHttpPort;
 
@@ -211,6 +221,21 @@
     }
 
     @Test
+    void testResponseCodes() throws Exception {
+        String supervisionUrl = baseUrl() + ProducerCallbacksController.SUPERVISION_URL;
+        ResponseEntity<String> resp = restClient().getForEntity(supervisionUrl).block();
+        assertThat(resp.getStatusCode()).isEqualTo(HttpStatus.OK);
+
+        String jobUrl = baseUrl() + ProducerCallbacksController.JOB_URL;
+        resp = restClient().deleteForEntity(jobUrl + "/junk").block();
+        assertThat(resp.getStatusCode()).isEqualTo(HttpStatus.OK);
+
+        ProducerJobInfo info = new ProducerJobInfo(null, "id", "typeId", "targetUri", "owner", "lastUpdated");
+        String body = gson.toJson(info);
+        testErrorCode(restClient().post(jobUrl, body), HttpStatus.NOT_FOUND, "Could not find type");
+    }
+
+    @Test
     void testWholeChain() throws Exception {
         final String JOB_ID = "ID";
 
@@ -234,4 +259,29 @@
         await().untilAsserted(() -> assertThat(this.jobs.size()).isZero());
     }
 
+    private void testErrorCode(Mono<?> request, HttpStatus expStatus, String responseContains) {
+        testErrorCode(request, expStatus, responseContains, true);
+    }
+
+    private void testErrorCode(Mono<?> request, HttpStatus expStatus, String responseContains,
+            boolean expectApplicationProblemJsonMediaType) {
+        StepVerifier.create(request) //
+                .expectSubscription() //
+                .expectErrorMatches(
+                        t -> checkWebClientError(t, expStatus, responseContains, expectApplicationProblemJsonMediaType)) //
+                .verify();
+    }
+
+    private boolean checkWebClientError(Throwable throwable, HttpStatus expStatus, String responseContains,
+            boolean expectApplicationProblemJsonMediaType) {
+        assertTrue(throwable instanceof WebClientResponseException);
+        WebClientResponseException responseException = (WebClientResponseException) throwable;
+        assertThat(responseException.getStatusCode()).isEqualTo(expStatus);
+        assertThat(responseException.getResponseBodyAsString()).contains(responseContains);
+        if (expectApplicationProblemJsonMediaType) {
+            assertThat(responseException.getHeaders().getContentType()).isEqualTo(MediaType.APPLICATION_PROBLEM_JSON);
+        }
+        return true;
+    }
+
 }
diff --git a/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java b/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java
index 5292d90..4d64ef6 100644
--- a/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java
+++ b/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java
@@ -253,7 +253,7 @@
     @Test
     void a1eGetEiJobsIds() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         final String JOB_ID_JSON = "[\"jobId\"]";
         String url = A1eConsts.API_ROOT + "/eijobs?infoTypeId=typeId";
         String rsp = restClient().get(url).block();
@@ -283,7 +283,7 @@
     @Test
     void consumerGetInformationJobsIds() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         final String JOB_ID_JSON = "[\"jobId\"]";
         String url = ConsumerConsts.API_ROOT + "/info-jobs?infoTypeId=typeId";
         String rsp = restClient().get(url).block();
@@ -313,7 +313,7 @@
     @Test
     void a1eGetEiJob() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         String url = A1eConsts.API_ROOT + "/eijobs/jobId";
         String rsp = restClient().get(url).block();
         A1eEiJobInfo info = gson.fromJson(rsp, A1eEiJobInfo.class);
@@ -324,7 +324,7 @@
     @Test
     void consumerGetEiJob() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         String url = ConsumerConsts.API_ROOT + "/info-jobs/jobId";
         String rsp = restClient().get(url).block();
         ConsumerJobInfo info = gson.fromJson(rsp, ConsumerJobInfo.class);
@@ -349,15 +349,15 @@
     @Test
     void a1eGetEiJobStatus() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
 
         verifyJobStatus("jobId", "ENABLED");
     }
 
     @Test
-    void consumerGetEiJobStatus() throws Exception {
+    void consumerGetInfoJobStatus() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
 
         String url = ConsumerConsts.API_ROOT + "/info-jobs/jobId/status";
         String rsp = restClient().get(url).block();
@@ -372,7 +372,7 @@
     @Test
     void a1eDeleteEiJob() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         assertThat(this.infoJobs.size()).isEqualTo(1);
         String url = A1eConsts.API_ROOT + "/eijobs/jobId";
         restClient().delete(url).block();
@@ -386,7 +386,7 @@
     @Test
     void consumerDeleteEiJob() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         assertThat(this.infoJobs.size()).isEqualTo(1);
         String url = ConsumerConsts.API_ROOT + "/info-jobs/jobId";
         restClient().delete(url).block();
@@ -395,6 +395,8 @@
         ProducerSimulatorController.TestResults simulatorResults = this.producerSimulator.getTestResults();
         await().untilAsserted(() -> assertThat(simulatorResults.jobsStopped.size()).isEqualTo(1));
         assertThat(simulatorResults.jobsStopped.get(0)).isEqualTo("jobId");
+
+        testErrorCode(restClient().delete(url), HttpStatus.NOT_FOUND, "Could not find Information job: jobId");
     }
 
     @Test
@@ -415,7 +417,7 @@
     void a1ePutEiJob() throws Exception {
         // Test that one producer accepting a job is enough
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
+        putInfoProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
 
         String url = A1eConsts.API_ROOT + "/eijobs/jobId";
         String body = gson.toJson(infoJobInfo());
@@ -520,7 +522,7 @@
     void a1eChangingEiTypeGetRejected() throws Exception {
         putInfoProducerWithOneType("producer1", "typeId1");
         putInfoProducerWithOneType("producer2", "typeId2");
-        putEiJob("typeId1", "jobId");
+        putInfoJob("typeId1", "jobId");
 
         String url = A1eConsts.API_ROOT + "/eijobs/jobId";
         String body = gson.toJson(infoJobInfo("typeId2", "jobId"));
@@ -532,7 +534,7 @@
     void consumerChangingInfoTypeGetRejected() throws Exception {
         putInfoProducerWithOneType("producer1", "typeId1");
         putInfoProducerWithOneType("producer2", "typeId2");
-        putEiJob("typeId1", "jobId");
+        putInfoJob("typeId1", "jobId");
 
         String url = ConsumerConsts.API_ROOT + "/info-jobs/jobId";
         String body = gson.toJson(consumerJobInfo("typeId2", "jobId"));
@@ -555,8 +557,8 @@
     @Test
     void producerDeleteEiType() throws Exception {
         putInfoType(TYPE_ID);
-        this.putEiJob(TYPE_ID, "job1");
-        this.putEiJob(TYPE_ID, "job2");
+        this.putInfoJob(TYPE_ID, "job1");
+        this.putInfoJob(TYPE_ID, "job2");
         deleteInfoType(TYPE_ID);
 
         assertThat(this.infoTypes.size()).isZero();
@@ -578,7 +580,7 @@
     @Test
     void producerPutProducerWithOneType_rejecting()
         throws JsonMappingException, JsonProcessingException, ServiceException {
-        putEiProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
+        putInfoProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
         String url = A1eConsts.API_ROOT + "/eijobs/" + EI_JOB_ID;
         String body = gson.toJson(infoJobInfo());
         restClient().put(url, body).block();
@@ -592,12 +594,12 @@
     }
 
     @Test
-    void producerGetEiProducerTypes() throws Exception {
+    void producerGetInfoProducerTypes() throws Exception {
         final String EI_TYPE_ID_2 = TYPE_ID + "_2";
         putInfoProducerWithOneType("producer1", TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         putInfoProducerWithOneType("producer2", EI_TYPE_ID_2);
-        putEiJob(EI_TYPE_ID_2, "jobId2");
+        putInfoJob(EI_TYPE_ID_2, "jobId2");
         String url = ProducerConsts.API_ROOT + "/info-types";
 
         ResponseEntity<String> resp = restClient().getForEntity(url).block();
@@ -607,7 +609,7 @@
     }
 
     @Test
-    void producerPutEiProducer() throws Exception {
+    void producerPutInfoProducer() throws Exception {
         this.putInfoType(TYPE_ID);
         String url = ProducerConsts.API_ROOT + "/info-producers/infoProducerId";
         String body = gson.toJson(producerInfoRegistratioInfo(TYPE_ID));
@@ -624,15 +626,18 @@
         resp = restClient().putForEntity(url, body).block();
         assertThat(resp.getStatusCode()).isEqualTo(HttpStatus.OK);
 
+        // GET info producer
         resp = restClient().getForEntity(url).block();
         assertThat(resp.getStatusCode()).isEqualTo(HttpStatus.OK);
         assertThat(resp.getBody()).isEqualTo(body);
+
+        testErrorCode(restClient().get(url + "junk"), HttpStatus.NOT_FOUND, "Could not find Information Producer");
     }
 
     @Test
-    void producerPutEiProducerExistingJob() throws Exception {
+    void producerPutInfoProducerExistingJob() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         String url = ProducerConsts.API_ROOT + "/info-producers/infoProducerId";
         String body = gson.toJson(producerInfoRegistratioInfo(TYPE_ID));
         restClient().putForEntity(url, body).block();
@@ -644,14 +649,14 @@
     }
 
     @Test
-    void testPutEiProducer_noType() throws Exception {
+    void testPutInfoProducer_noType() throws Exception {
         String url = ProducerConsts.API_ROOT + "/info-producers/infoProducerId";
         String body = gson.toJson(producerInfoRegistratioInfo(TYPE_ID));
         testErrorCode(restClient().put(url, body), HttpStatus.NOT_FOUND, "Information type not found");
     }
 
     @Test
-    void producerPutProducerAndEiJob() throws Exception {
+    void producerPutProducerAndInfoJob() throws Exception {
         this.putInfoType(TYPE_ID);
         String url = ProducerConsts.API_ROOT + "/info-producers/infoProducerId";
         String body = gson.toJson(producerInfoRegistratioInfo(TYPE_ID));
@@ -670,10 +675,10 @@
     }
 
     @Test
-    void producerGetEiJobsForProducer() throws JsonMappingException, JsonProcessingException, ServiceException {
+    void producerGetInfoJobsForProducer() throws JsonMappingException, JsonProcessingException, ServiceException {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId1");
-        putEiJob(TYPE_ID, "jobId2");
+        putInfoJob(TYPE_ID, "jobId1");
+        putInfoJob(TYPE_ID, "jobId2");
 
         // PUT a consumerRestApiTestBase.java
         String url = ProducerConsts.API_ROOT + "/info-producers/infoProducerId";
@@ -690,7 +695,7 @@
     }
 
     @Test
-    void producerDeleteEiProducer() throws Exception {
+    void producerDeleteInfoProducer() throws Exception {
         putInfoProducerWithOneType("infoProducerId", TYPE_ID);
         putInfoProducerWithOneType("infoProducerId2", TYPE_ID);
 
@@ -698,18 +703,21 @@
         InfoType type = this.infoTypes.getType(TYPE_ID);
         assertThat(this.infoProducers.getProducerIdsForType(type.getId())).contains("infoProducerId");
         assertThat(this.infoProducers.getProducerIdsForType(type.getId())).contains("infoProducerId2");
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         assertThat(this.infoJobs.size()).isEqualTo(1);
 
-        deleteEiProducer("infoProducerId");
+        deleteInfoProducer("infoProducerId");
         assertThat(this.infoProducers.size()).isEqualTo(1);
         assertThat(this.infoProducers.getProducerIdsForType(TYPE_ID)).doesNotContain("infoProducerId");
         verifyJobStatus("jobId", "ENABLED");
 
-        deleteEiProducer("infoProducerId2");
+        deleteInfoProducer("infoProducerId2");
         assertThat(this.infoProducers.size()).isZero();
         assertThat(this.infoTypes.size()).isEqualTo(1);
         verifyJobStatus("jobId", "DISABLED");
+
+        String url = ProducerConsts.API_ROOT + "/info-producers/" + "junk";
+        testErrorCode(restClient().delete(url), HttpStatus.NOT_FOUND, "Could not find Information Producer");
     }
 
     @Test
@@ -718,13 +726,13 @@
         ProducerSimulatorController.TestResults producerCalls = this.producerSimulator.getTestResults();
 
         putInfoProducerWithOneType("infoProducerId", TYPE_ID);
-        putEiJob(TYPE_ID, "jobId");
+        putInfoJob(TYPE_ID, "jobId");
         putInfoProducerWithOneType("infoProducerId2", TYPE_ID);
         await().untilAsserted(() -> assertThat(producerCalls.jobsStarted.size()).isEqualTo(2));
 
-        deleteEiProducer("infoProducerId2");
+        deleteInfoProducer("infoProducerId2");
         assertThat(this.infoTypes.size()).isEqualTo(1); // The type remains, one producer left
-        deleteEiProducer("infoProducerId");
+        deleteInfoProducer("infoProducerId");
         assertThat(this.infoTypes.size()).isEqualTo(1); // The type remains
         assertThat(this.infoJobs.size()).isEqualTo(1); // The job remains
         await().untilAsserted(() -> assertThat(consumerCalls.eiJobStatusCallbacks.size()).isEqualTo(1));
@@ -742,7 +750,7 @@
 
         // Create a job
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, EI_JOB_ID);
+        putInfoJob(TYPE_ID, EI_JOB_ID);
 
         // change the type for the producer, the job shall be disabled
         putInfoProducerWithOneType(PRODUCER_ID, "junk");
@@ -759,13 +767,15 @@
     }
 
     @Test
-    void producerGetProducerEiType() throws JsonMappingException, JsonProcessingException, ServiceException {
+    void producerGetProducerInfoType() throws JsonMappingException, JsonProcessingException, ServiceException {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
         String url = ProducerConsts.API_ROOT + "/info-types/" + TYPE_ID;
         ResponseEntity<String> resp = restClient().getForEntity(url).block();
         ProducerInfoTypeInfo info = gson.fromJson(resp.getBody(), ProducerInfoTypeInfo.class);
         assertThat(info.jobDataSchema).isNotNull();
         assertThat(info.typeSpecificInformation).isNotNull();
+
+        testErrorCode(restClient().get(url + "junk"), HttpStatus.NOT_FOUND, "Information type not found");
     }
 
     @Test
@@ -788,14 +798,14 @@
     void producerSupervision() throws JsonMappingException, JsonProcessingException, ServiceException {
 
         ConsumerSimulatorController.TestResults consumerResults = this.consumerSimulator.getTestResults();
-        putEiProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
+        putInfoProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
 
         {
             // Create a job
             putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-            putEiJob(TYPE_ID, EI_JOB_ID);
+            putInfoJob(TYPE_ID, EI_JOB_ID);
             verifyJobStatus(EI_JOB_ID, "ENABLED");
-            deleteEiProducer(PRODUCER_ID);
+            deleteInfoProducer(PRODUCER_ID);
             // A Job disabled status notification shall now be received
             await().untilAsserted(() -> assertThat(consumerResults.eiJobStatusCallbacks.size()).isEqualTo(1));
             assertThat(consumerResults.eiJobStatusCallbacks.get(0).state)
@@ -834,7 +844,7 @@
         // suceeded
 
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, EI_JOB_ID);
+        putInfoJob(TYPE_ID, EI_JOB_ID);
 
         InfoProducer producer = this.infoProducers.getProducer(PRODUCER_ID);
         InfoJob job = this.infoJobs.getJob(EI_JOB_ID);
@@ -855,8 +865,8 @@
 
     @Test
     void testGetStatus() throws JsonMappingException, JsonProcessingException, ServiceException {
-        putEiProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
-        putEiProducerWithOneTypeRejecting("simulateProducerError2", TYPE_ID);
+        putInfoProducerWithOneTypeRejecting("simulateProducerError", TYPE_ID);
+        putInfoProducerWithOneTypeRejecting("simulateProducerError2", TYPE_ID);
 
         String url = "/status";
         ResponseEntity<String> resp = restClient().getForEntity(url).block();
@@ -866,8 +876,8 @@
     @Test
     void testEiJobDatabase() throws Exception {
         putInfoProducerWithOneType(PRODUCER_ID, TYPE_ID);
-        putEiJob(TYPE_ID, "jobId1");
-        putEiJob(TYPE_ID, "jobId2");
+        putInfoJob(TYPE_ID, "jobId1");
+        putInfoJob(TYPE_ID, "jobId2");
 
         assertThat(this.infoJobs.size()).isEqualTo(2);
 
@@ -926,6 +936,7 @@
     void testConsumerTypeSubscriptionDatabase() {
         final String callbackUrl = baseUrl() + ConsumerSimulatorController.getTypeStatusCallbackUrl();
         final ConsumerTypeSubscriptionInfo info = new ConsumerTypeSubscriptionInfo(callbackUrl, "owner");
+
         // PUT a subscription
         String body = gson.toJson(info);
         restClient().putForEntity(typeSubscriptionUrl() + "/subscriptionId", body).block();
@@ -947,6 +958,12 @@
         final String callbackUrl = baseUrl() + ConsumerSimulatorController.getTypeStatusCallbackUrl();
         final ConsumerTypeSubscriptionInfo info = new ConsumerTypeSubscriptionInfo(callbackUrl, "owner");
 
+        testErrorCode(restClient().get(typeSubscriptionUrl() + "/junk"), HttpStatus.NOT_FOUND,
+            "Could not find Information subscription: junk");
+
+        testErrorCode(restClient().delete(typeSubscriptionUrl() + "/junk"), HttpStatus.NOT_FOUND,
+            "Could not find Information subscription: junk");
+
         {
             // PUT a subscription
             String body = gson.toJson(info);
@@ -1031,7 +1048,7 @@
         return ConsumerConsts.API_ROOT + "/info-type-subscription";
     }
 
-    private void deleteEiProducer(String infoProducerId) {
+    private void deleteInfoProducer(String infoProducerId) {
         String url = ProducerConsts.API_ROOT + "/info-producers/" + infoProducerId;
         restClient().deleteForEntity(url).block();
     }
@@ -1050,7 +1067,7 @@
         assertThat(statusInfo.opState).isEqualTo(expectedOperationalState);
     }
 
-    ProducerInfoTypeInfo producerEiTypeRegistrationInfo(String typeId)
+    ProducerInfoTypeInfo ProducerInfoTypeRegistrationInfo(String typeId)
         throws JsonMappingException, JsonProcessingException {
         return new ProducerInfoTypeInfo(jsonSchemaObject(), typeSpecifcInfoObject());
     }
@@ -1120,7 +1137,7 @@
         return jsonObject("{ " + EI_JOB_PROPERTY + " : \"value\" }");
     }
 
-    private InfoJob putEiJob(String infoTypeId, String jobId)
+    private InfoJob putInfoJob(String infoTypeId, String jobId)
         throws JsonMappingException, JsonProcessingException, ServiceException {
 
         String url = A1eConsts.API_ROOT + "/eijobs/" + jobId;
@@ -1133,7 +1150,7 @@
     private HttpStatus putInfoType(String infoTypeId)
         throws JsonMappingException, JsonProcessingException, ServiceException {
         String url = ProducerConsts.API_ROOT + "/info-types/" + infoTypeId;
-        String body = gson.toJson(producerEiTypeRegistrationInfo(infoTypeId));
+        String body = gson.toJson(ProducerInfoTypeRegistrationInfo(infoTypeId));
 
         ResponseEntity<String> resp = restClient().putForEntity(url, body).block();
         this.infoTypes.getType(infoTypeId);
@@ -1148,7 +1165,7 @@
         restClient().delete(deleteInfoTypeUrl(typeId)).block();
     }
 
-    private InfoType putEiProducerWithOneTypeRejecting(String producerId, String infoTypeId)
+    private InfoType putInfoProducerWithOneTypeRejecting(String producerId, String infoTypeId)
         throws JsonMappingException, JsonProcessingException, ServiceException {
         this.putInfoType(infoTypeId);
         String url = ProducerConsts.API_ROOT + "/info-producers/" + producerId;