diff --git a/manifest.yml b/manifest.yml
index 5639293..31932cb 100644
--- a/manifest.yml
+++ b/manifest.yml
@@ -3,5 +3,5 @@ applications:
- name: axway-apim-service-broker
memory: 1G
random-route: true
- path: target/apim-service-broker-1.1.7.jar
+ path: target/apim-service-broker-1.1.8.jar
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 33cd230..7869f40 100644
--- a/pom.xml
+++ b/pom.xml
@@ -5,7 +5,7 @@
4.0.0
com.axway.apim
apim-service-broker
- 1.1.7
+ 1.1.8
jar
axway-apim-service-broker
Axway APIM Service Broker
diff --git a/src/main/java/com/axway/apim/servicebroker/AxwayServiceBrokerApplication.java b/src/main/java/com/axway/apim/servicebroker/AxwayServiceBrokerApplication.java
index 09e3906..16e61d8 100644
--- a/src/main/java/com/axway/apim/servicebroker/AxwayServiceBrokerApplication.java
+++ b/src/main/java/com/axway/apim/servicebroker/AxwayServiceBrokerApplication.java
@@ -1,12 +1,17 @@
package com.axway.apim.servicebroker;
+import com.axway.apim.servicebroker.service.Constants;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class AxwayServiceBrokerApplication {
+ private static final Logger logger = LoggerFactory.getLogger(AxwayServiceBrokerApplication.class);
- public static void main(String[] args) {
- SpringApplication.run(AxwayServiceBrokerApplication.class, args);
- }
+ public static void main(String[] args) {
+ logger.info("Version : {}", Constants.VERSION);
+ SpringApplication.run(AxwayServiceBrokerApplication.class, args);
+ }
}
diff --git a/src/main/java/com/axway/apim/servicebroker/model/APIOrganization.java b/src/main/java/com/axway/apim/servicebroker/model/APIOrganization.java
index 8fa5bda..9f6eca4 100644
--- a/src/main/java/com/axway/apim/servicebroker/model/APIOrganization.java
+++ b/src/main/java/com/axway/apim/servicebroker/model/APIOrganization.java
@@ -13,12 +13,9 @@ public class APIOrganization {
private String phone;
private boolean enabled = true;
private boolean development = true;
-
//custom attribute
private String service_instance_id;
-
-
-
+
public String getId() {
return id;
}
@@ -73,6 +70,4 @@ public String getService_instance_id() {
public void setService_instance_id(String service_instance_id) {
this.service_instance_id = service_instance_id;
}
-
-
}
diff --git a/src/main/java/com/axway/apim/servicebroker/model/APIOrganizationAccess.java b/src/main/java/com/axway/apim/servicebroker/model/APIOrganizationAccess.java
index b38be72..f5970a1 100644
--- a/src/main/java/com/axway/apim/servicebroker/model/APIOrganizationAccess.java
+++ b/src/main/java/com/axway/apim/servicebroker/model/APIOrganizationAccess.java
@@ -5,21 +5,22 @@
@JsonIgnoreProperties(ignoreUnknown = true)
public class APIOrganizationAccess {
- private String id;
- private String apiId;
- public String getId() {
- return id;
- }
- public void setId(String id) {
- this.id = id;
- }
- public String getApiId() {
- return apiId;
- }
- public void setApiId(String apiId) {
- this.apiId = apiId;
- }
-
-
+ private String id;
+ private String apiId;
+ public String getId() {
+ return id;
+ }
+
+ public void setId(String id) {
+ this.id = id;
+ }
+
+ public String getApiId() {
+ return apiId;
+ }
+
+ public void setApiId(String apiId) {
+ this.apiId = apiId;
+ }
}
diff --git a/src/main/java/com/axway/apim/servicebroker/model/APISecurity.java b/src/main/java/com/axway/apim/servicebroker/model/APISecurity.java
index 5ed1394..37421fa 100644
--- a/src/main/java/com/axway/apim/servicebroker/model/APISecurity.java
+++ b/src/main/java/com/axway/apim/servicebroker/model/APISecurity.java
@@ -7,8 +7,7 @@ public class APISecurity {
private String name = "Pass Through";
private String type = "passThrough";
private int order = 1;
-
-
+
private Properties properties;
public APISecurity(){
@@ -17,8 +16,7 @@ public APISecurity(){
properties.setProperty("removeCredentialsOnSuccess", "true");
}
-
-
+
public String getName() {
return name;
}
@@ -50,6 +48,4 @@ public Properties getProperties() {
public void setProperties(Properties properties) {
this.properties = properties;
}
-
-
}
diff --git a/src/main/java/com/axway/apim/servicebroker/model/APIUser.java b/src/main/java/com/axway/apim/servicebroker/model/APIUser.java
index b3c2d2d..1074f63 100644
--- a/src/main/java/com/axway/apim/servicebroker/model/APIUser.java
+++ b/src/main/java/com/axway/apim/servicebroker/model/APIUser.java
@@ -18,9 +18,7 @@ public class APIUser {
private long createdOn; //(integer, optional): Epoch/Unix time stamp when the organization was created ,
private String state = "approved"; //(string, optional): The current state of the account, one of: approved, pending ,
private String type = "internal"; //(string, optional): Indicates the type of user. Possible values: internal, external ,
-
-
-
+
public String getId() {
return id;
}
@@ -75,7 +73,6 @@ public String getRole() {
public void setRole(String role) {
this.role = role;
}
-
public boolean isEnabled() {
return enabled;
}
@@ -100,6 +97,4 @@ public String getType() {
public void setType(String type) {
this.type = type;
}
-
-
}
diff --git a/src/main/java/com/axway/apim/servicebroker/model/FrondendAPI.java b/src/main/java/com/axway/apim/servicebroker/model/FrontendAPI.java
similarity index 96%
rename from src/main/java/com/axway/apim/servicebroker/model/FrondendAPI.java
rename to src/main/java/com/axway/apim/servicebroker/model/FrontendAPI.java
index a8edb47..9efdd13 100644
--- a/src/main/java/com/axway/apim/servicebroker/model/FrondendAPI.java
+++ b/src/main/java/com/axway/apim/servicebroker/model/FrontendAPI.java
@@ -3,7 +3,7 @@
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
@JsonIgnoreProperties(ignoreUnknown = true)
-public class FrondendAPI {
+public class FrontendAPI {
private String id;
private String apiId;
diff --git a/src/main/java/com/axway/apim/servicebroker/model/Type.java b/src/main/java/com/axway/apim/servicebroker/model/Type.java
index 997109b..9bb6709 100644
--- a/src/main/java/com/axway/apim/servicebroker/model/Type.java
+++ b/src/main/java/com/axway/apim/servicebroker/model/Type.java
@@ -2,5 +2,4 @@
public enum Type {
SWAGGER, WSDL
-
}
diff --git a/src/main/java/com/axway/apim/servicebroker/service/AxwayAPIClient.java b/src/main/java/com/axway/apim/servicebroker/service/AxwayAPIClient.java
index 0b65eb2..9e1dd1f 100644
--- a/src/main/java/com/axway/apim/servicebroker/service/AxwayAPIClient.java
+++ b/src/main/java/com/axway/apim/servicebroker/service/AxwayAPIClient.java
@@ -1,224 +1,213 @@
package com.axway.apim.servicebroker.service;
-import java.io.IOException;
-import java.net.URI;
-import java.util.List;
-
+import com.axway.apim.servicebroker.model.APIOrganizationAccess;
+import com.axway.apim.servicebroker.model.APISecurity;
+import com.axway.apim.servicebroker.model.FrontendAPI;
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.node.ArrayNode;
+import com.fasterxml.jackson.databind.node.ObjectNode;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cloud.servicebroker.exception.ServiceBrokerException;
import org.springframework.core.ParameterizedTypeReference;
-import org.springframework.http.HttpEntity;
-import org.springframework.http.HttpHeaders;
-import org.springframework.http.HttpMethod;
-import org.springframework.http.MediaType;
-import org.springframework.http.RequestEntity;
-import org.springframework.http.ResponseEntity;
+import org.springframework.http.*;
import org.springframework.util.LinkedMultiValueMap;
import org.springframework.util.MultiValueMap;
import org.springframework.web.client.RestTemplate;
import org.springframework.web.util.UriComponentsBuilder;
-import com.axway.apim.servicebroker.model.APIOrganizationAccess;
-import com.axway.apim.servicebroker.model.APISecurity;
-import com.axway.apim.servicebroker.model.FrondendAPI;
-import com.fasterxml.jackson.core.JsonProcessingException;
-import com.fasterxml.jackson.databind.JsonNode;
-import com.fasterxml.jackson.databind.ObjectMapper;
-import com.fasterxml.jackson.databind.node.ArrayNode;
-import com.fasterxml.jackson.databind.node.ObjectNode;
+import java.io.IOException;
+import java.net.URI;
+import java.util.List;
public class AxwayAPIClient implements Constants {
- private static final Logger logger = LoggerFactory.getLogger(AxwayAPIClient.class.getName());
-
- @Autowired
- // @Qualifier("getRestTemplate")
- private RestTemplate restTemplate;
-
- @Autowired
- private String url;
-
- @Autowired
- private ObjectMapper mapper;
-
- public List listAPIs(String orgId) {
- // https://phx-107.demo.axway.com:8075/api/portal/v1.3/organizations/14df2c8b-c28c-4062-ba8b-31449524a611/apis/
- URI uri = UriComponentsBuilder.fromUriString(url).path(API_BASEPATH).path("/organizations/").path(orgId)
- .path("/apis").build().toUri();
- RequestEntity> requestEntity = new RequestEntity