diff options
author | Smokowski, Steve (ss835w) <ss835w@us.att.com> | 2019-05-02 09:42:55 -0400 |
---|---|---|
committer | Smokowski, Steve (ss835w) <ss835w@us.att.com> | 2019-05-07 10:02:17 -0400 |
commit | 3f9a0c3183480d150089c0d5a6e507c877f7d121 (patch) | |
tree | b3db04cbe2cef23f81503177a50edc5360ffa486 /heat-client | |
parent | e153f0adfbed711ce1e215748594a4d04fd1edaf (diff) |
Enhance Openstack Client
Update Openstack Client to support additional fields
Updat all formatting issues
Issue-ID: SO-1844
Change-Id: I1369e0c18cc25274db8df7e12855a020b8da38da
Signed-off-by: Smokowski, Steve (ss835w) <ss835w@us.att.com>
Diffstat (limited to 'heat-client')
6 files changed, 38 insertions, 36 deletions
diff --git a/heat-client/pom.xml b/heat-client/pom.xml index 1393249..ebfc8f8 100644 --- a/heat-client/pom.xml +++ b/heat-client/pom.xml @@ -1,4 +1,5 @@ -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>org.onap.so.libs</groupId> @@ -10,23 +11,23 @@ <name>OpenStack Heat Client</name> <description>OpenStack Heat Client</description> <dependencies> - <dependency> - <groupId>org.onap.so.libs.openstack-java-sdk</groupId> - <artifactId>openstack-client</artifactId> - <version>${project.version}</version> - </dependency> + <dependency> + <groupId>org.onap.so.libs.openstack-java-sdk</groupId> + <artifactId>openstack-client</artifactId> + <version>${project.version}</version> + </dependency> - <dependency> - <groupId>org.onap.so.libs.openstack-java-sdk</groupId> - <artifactId>heat-model</artifactId> - <version>${project.version}</version> - </dependency> - <dependency> - <groupId>junit</groupId> - <artifactId>junit</artifactId> - <version>4.12</version> - <scope>test</scope> - </dependency> + <dependency> + <groupId>org.onap.so.libs.openstack-java-sdk</groupId> + <artifactId>heat-model</artifactId> + <version>${project.version}</version> + </dependency> + <dependency> + <groupId>junit</groupId> + <artifactId>junit</artifactId> + <version>4.12</version> + <scope>test</scope> + </dependency> </dependencies> </project> diff --git a/heat-client/src/main/java/com/woorea/openstack/heat/Heat.java b/heat-client/src/main/java/com/woorea/openstack/heat/Heat.java index e12f9f7..76991e1 100644 --- a/heat-client/src/main/java/com/woorea/openstack/heat/Heat.java +++ b/heat-client/src/main/java/com/woorea/openstack/heat/Heat.java @@ -47,7 +47,7 @@ public class Heat extends OpenStackClient { public ResourcesResource getResources() { return resources; } - + public StackEvents getEvents() { return events; } diff --git a/heat-client/src/main/java/com/woorea/openstack/heat/StackEvents.java b/heat-client/src/main/java/com/woorea/openstack/heat/StackEvents.java index ca54d73..cf680b9 100644 --- a/heat-client/src/main/java/com/woorea/openstack/heat/StackEvents.java +++ b/heat-client/src/main/java/com/woorea/openstack/heat/StackEvents.java @@ -25,22 +25,22 @@ import com.woorea.openstack.heat.model.Events; * v1/{tenant_id}/stacks/{stack_name}/{stack_id}/events */ public class StackEvents { - private final OpenStackClient client; + private final OpenStackClient client; - public StackEvents(OpenStackClient client) { - this.client = client; - } + public StackEvents(OpenStackClient client) { + this.client = client; + } - public ListEvents listEvents(String name, String id) { - return new ListEvents(name, id); - } + public ListEvents listEvents(String name, String id) { + return new ListEvents(name, id); + } - /** - * v1/{tenant_id}/stacks/{stack_name}/resources - */ - public class ListEvents extends OpenStackRequest<Events> { - public ListEvents(String name, String id) { - super(client, HttpMethod.GET, "/stacks/" + name + "/" + id + "/events", null, Events.class); - } - } + /** + * v1/{tenant_id}/stacks/{stack_name}/resources + */ + public class ListEvents extends OpenStackRequest<Events> { + public ListEvents(String name, String id) { + super(client, HttpMethod.GET, "/stacks/" + name + "/" + id + "/events", null, Events.class); + } + } } diff --git a/heat-client/src/test/java/com/woorea/openstack/heat/HeatTest.java b/heat-client/src/test/java/com/woorea/openstack/heat/HeatTest.java index 9aff4cc..e0b1134 100644 --- a/heat-client/src/test/java/com/woorea/openstack/heat/HeatTest.java +++ b/heat-client/src/test/java/com/woorea/openstack/heat/HeatTest.java @@ -35,4 +35,4 @@ public class HeatTest { heat.getResources(); } -}
\ No newline at end of file +} diff --git a/heat-client/src/test/java/com/woorea/openstack/heat/ResourcesResourceTest.java b/heat-client/src/test/java/com/woorea/openstack/heat/ResourcesResourceTest.java index 380b016..7093c57 100644 --- a/heat-client/src/test/java/com/woorea/openstack/heat/ResourcesResourceTest.java +++ b/heat-client/src/test/java/com/woorea/openstack/heat/ResourcesResourceTest.java @@ -31,4 +31,4 @@ public class ResourcesResourceTest { resourcesResource.listResources("resource"); } -}
\ No newline at end of file +} diff --git a/heat-client/src/test/java/com/woorea/openstack/heat/StackResourceTest.java b/heat-client/src/test/java/com/woorea/openstack/heat/StackResourceTest.java index 8831c76..c280132 100644 --- a/heat-client/src/test/java/com/woorea/openstack/heat/StackResourceTest.java +++ b/heat-client/src/test/java/com/woorea/openstack/heat/StackResourceTest.java @@ -27,6 +27,7 @@ import org.junit.Test; public class StackResourceTest { StackResource stackResource = new StackResource(new OpenStackClient("os")); + @Test public void create() throws Exception { stackResource.create(new CreateStackParam()); @@ -52,4 +53,4 @@ public class StackResourceTest { stackResource.deleteByName("test"); } -}
\ No newline at end of file +} |