Match decompress argument of DR API 97/84397/1
authordglFromAtt <dgl@research.att.com>
Fri, 5 Apr 2019 20:55:52 +0000 (16:55 -0400)
committerdglFromAtt <dgl@research.att.com>
Fri, 5 Apr 2019 20:56:00 +0000 (16:56 -0400)
Change-Id: Idbd2edaa90df2b0145284751566588f2151f35fe
Signed-off-by: dglFromAtt <dgl@research.att.com>
Issue-ID: DMAAP-1059

src/main/java/org/onap/dmaap/dbcapi/model/DR_Sub.java
src/main/resources/schema_12.sql
src/test/java/org/onap/dmaap/dbcapi/model/DRSubTest.java

index 8ac0880..90da956 100644 (file)
@@ -45,7 +45,7 @@ public class DR_Sub extends DmaapObject {
        private boolean guaranteedDelivery;
        private boolean guaranteedSequence;
        private boolean privilegedSubscriber;
-       private boolean decompressData;
+       private boolean decompress;
 
        // NOTE: the following fields are optional in the API but not stored in the DB
 
@@ -116,9 +116,9 @@ public class DR_Sub extends DmaapObject {
                        this.setPrivilegedSubscriber(false);
                }
                try {
-                       this.setDecompressData((boolean) jsonObj.get("decompressData"));
+                       this.setDecompress((boolean) jsonObj.get("decompress"));
                } catch( NullPointerException npe ) {
-                       this.setDecompressData(false);
+                       this.setDecompress(false);
                }
 
                JSONObject del = (JSONObject) jsonObj.get("delivery");
@@ -239,12 +239,12 @@ public class DR_Sub extends DmaapObject {
                this.privilegedSubscriber = privilegedSubscriber;
        }
 
-       public boolean isDecompressData() {
-               return decompressData;
+       public boolean isDecompress() {
+               return decompress;
        }
 
-       public void setDecompressData(boolean decompressData) {
-               this.decompressData = decompressData;
+       public void setDecompress(boolean decompressData) {
+               this.decompress = decompressData;
        }
 
        public String getFeedName() {
@@ -286,7 +286,7 @@ public class DR_Sub extends DmaapObject {
                                ,"0"
                                ,"true"
                                ,this.isPrivilegedSubscriber()
-                               ,this.isDecompressData()
+                               ,this.isDecompress()
                        );
 
                logger.info( postJSON );
index 22f0559..c4cef5f 100644 (file)
@@ -24,7 +24,7 @@
     add column  guaranteed_delivery     boolean,
     add column  guaranteed_sequence     boolean,
     add column  privileged_subscriber    boolean,
-    add column  decompress_data          boolean
+    add column  decompress                      boolean
 ;
 
 
index 59a4023..95cf9c9 100644 (file)
@@ -69,7 +69,7 @@ public class DRSubTest {
                assertTrue( t.isGuaranteedDelivery() == false );
                assertTrue( t.isGuaranteedSequence() == false );
                assertTrue( t.isPrivilegedSubscriber() == false );
-               assertTrue( t.isDecompressData() == false );
+               assertTrue( t.isDecompress() == false );
        }
 
        @Test
@@ -113,8 +113,8 @@ public class DRSubTest {
                assertTrue( t.isGuaranteedSequence() == v );
                t.setPrivilegedSubscriber(v);
                assertTrue( t.isPrivilegedSubscriber() == v );
-               t.setDecompressData(v);
-               assertTrue( t.isDecompressData() == v );
+               t.setDecompress(v);
+               assertTrue( t.isDecompress() == v );
        }
 
        @Test