Fix test failures

4.x.x
Pahansith Gunathilake 3 years ago
parent 4691b1d7bd
commit 10b8e0de53

@ -50,7 +50,6 @@ public class CommandOperationDAOImpl extends GenericOperationDAOImpl {
stmt = connection.prepareStatement(sql, new String[]{"id"}); stmt = connection.prepareStatement(sql, new String[]{"id"});
stmt.setString(1, operation.getType().toString()); stmt.setString(1, operation.getType().toString());
stmt.setLong(2, DeviceManagementDAOUtil.getCurrentUTCTime()); stmt.setLong(2, DeviceManagementDAOUtil.getCurrentUTCTime());
log.info("------Time----- " + DeviceManagementDAOUtil.getCurrentUTCTime());
stmt.setLong(3, 0); stmt.setLong(3, 0);
stmt.setString(4, operation.getCode()); stmt.setString(4, operation.getCode());
stmt.setString(5, operation.getInitiatedBy()); stmt.setString(5, operation.getInitiatedBy());

@ -75,8 +75,8 @@ CREATE TABLE IF NOT EXISTS DM_DEVICE_GROUP_MAP (
CREATE TABLE IF NOT EXISTS DM_OPERATION ( CREATE TABLE IF NOT EXISTS DM_OPERATION (
ID INTEGER AUTO_INCREMENT NOT NULL, ID INTEGER AUTO_INCREMENT NOT NULL,
TYPE VARCHAR(50) NOT NULL, TYPE VARCHAR(50) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR(1000) NOT NULL, OPERATION_CODE VARCHAR(1000) NOT NULL,
INITIATED_BY VARCHAR(100) NULL, INITIATED_BY VARCHAR(100) NULL,
OPERATION_DETAILS BLOB DEFAULT NULL, OPERATION_DETAILS BLOB DEFAULT NULL,

@ -65,8 +65,8 @@ CREATE TABLE IF NOT EXISTS DM_DEVICE_GROUP_MAP (
CREATE TABLE IF NOT EXISTS DM_OPERATION ( CREATE TABLE IF NOT EXISTS DM_OPERATION (
ID INTEGER AUTO_INCREMENT NOT NULL, ID INTEGER AUTO_INCREMENT NOT NULL,
TYPE VARCHAR(50) NOT NULL, TYPE VARCHAR(50) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR(1000) NOT NULL, OPERATION_CODE VARCHAR(1000) NOT NULL,
PRIMARY KEY (ID) PRIMARY KEY (ID)
); );

@ -83,8 +83,8 @@ DROP TABLE IF EXISTS DM_OPERATION;
CREATE TABLE IF NOT EXISTS DM_OPERATION ( CREATE TABLE IF NOT EXISTS DM_OPERATION (
ID INTEGER AUTO_INCREMENT NOT NULL, ID INTEGER AUTO_INCREMENT NOT NULL,
TYPE VARCHAR(50) NOT NULL, TYPE VARCHAR(50) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR(1000) NOT NULL, OPERATION_CODE VARCHAR(1000) NOT NULL,
INITIATED_BY VARCHAR(100) NULL, INITIATED_BY VARCHAR(100) NULL,
OPERATION_DETAILS BLOB DEFAULT NULL, OPERATION_DETAILS BLOB DEFAULT NULL,

@ -79,7 +79,7 @@ CREATE TABLE IF NOT EXISTS AP_APP_LIFECYCLE_STATE(
PREVIOUS_STATE VARCHAR(45) NOT NULL, PREVIOUS_STATE VARCHAR(45) NOT NULL,
TENANT_ID INTEGER NOT NULL, TENANT_ID INTEGER NOT NULL,
UPDATED_BY VARCHAR(100) NOT NULL, UPDATED_BY VARCHAR(100) NOT NULL,
UPDATED_AT TIMESTAMP NOT NULL, UPDATED_AT BIGINT NOT NULL,
AP_APP_RELEASE_ID INTEGER NOT NULL, AP_APP_RELEASE_ID INTEGER NOT NULL,
REASON TEXT DEFAULT NULL, REASON TEXT DEFAULT NULL,
PRIMARY KEY (ID), PRIMARY KEY (ID),

@ -80,7 +80,7 @@ CREATE TABLE AP_APP_LIFECYCLE_STATE(
PREVIOUS_STATE VARCHAR(45) NOT NULL, PREVIOUS_STATE VARCHAR(45) NOT NULL,
TENANT_ID INTEGER NOT NULL, TENANT_ID INTEGER NOT NULL,
UPDATED_BY VARCHAR(100) NOT NULL, UPDATED_BY VARCHAR(100) NOT NULL,
UPDATED_AT DATETIME2(0) NOT NULL, UPDATED_AT BIGINT NOT NULL,
AP_APP_RELEASE_ID INTEGER NOT NULL, AP_APP_RELEASE_ID INTEGER NOT NULL,
REASON VARCHAR(max) DEFAULT NULL, REASON VARCHAR(max) DEFAULT NULL,
PRIMARY KEY (ID), PRIMARY KEY (ID),

@ -87,7 +87,7 @@ CREATE TABLE IF NOT EXISTS AP_APP_LIFECYCLE_STATE(
PREVIOUS_STATE VARCHAR(45) NOT NULL, PREVIOUS_STATE VARCHAR(45) NOT NULL,
TENANT_ID INTEGER NOT NULL, TENANT_ID INTEGER NOT NULL,
UPDATED_BY VARCHAR(100) NOT NULL, UPDATED_BY VARCHAR(100) NOT NULL,
UPDATED_AT TIMESTAMP(0) NOT NULL, UPDATED_AT BIGINT NOT NULL,
AP_APP_RELEASE_ID INTEGER NOT NULL, AP_APP_RELEASE_ID INTEGER NOT NULL,
REASON TEXT DEFAULT NULL, REASON TEXT DEFAULT NULL,
PRIMARY KEY (ID), PRIMARY KEY (ID),

@ -2,8 +2,8 @@
CREATE TABLE IF NOT EXISTS DM_OPERATION_ARCH ( CREATE TABLE IF NOT EXISTS DM_OPERATION_ARCH (
ID INTEGER NOT NULL, ID INTEGER NOT NULL,
TYPE VARCHAR(20) NOT NULL, TYPE VARCHAR(20) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR(50) NOT NULL, OPERATION_CODE VARCHAR(50) NOT NULL,
INITIATED_BY VARCHAR(100) NULL, INITIATED_BY VARCHAR(100) NULL,
OPERATION_DETAILS BLOB DEFAULT NULL, OPERATION_DETAILS BLOB DEFAULT NULL,

@ -84,8 +84,8 @@ CREATE TABLE IF NOT EXISTS DM_DEVICE_GROUP_MAP (
CREATE TABLE IF NOT EXISTS DM_OPERATION ( CREATE TABLE IF NOT EXISTS DM_OPERATION (
ID INTEGER AUTO_INCREMENT NOT NULL, ID INTEGER AUTO_INCREMENT NOT NULL,
TYPE VARCHAR(50) NOT NULL, TYPE VARCHAR(50) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR(1000) NOT NULL, OPERATION_CODE VARCHAR(1000) NOT NULL,
INITIATED_BY VARCHAR(100) NULL, INITIATED_BY VARCHAR(100) NULL,
OPERATION_DETAILS BLOB DEFAULT NULL, OPERATION_DETAILS BLOB DEFAULT NULL,

@ -111,8 +111,8 @@ IF NOT EXISTS (SELECT * FROM SYS.OBJECTS WHERE OBJECT_ID = OBJECT_ID(N'[DBO].[D
CREATE TABLE DM_OPERATION ( CREATE TABLE DM_OPERATION (
ID INTEGER IDENTITY(1,1) NOT NULL, ID INTEGER IDENTITY(1,1) NOT NULL,
TYPE VARCHAR(20) NOT NULL, TYPE VARCHAR(20) NOT NULL,
CREATED_TIMESTAMP DATETIME2 NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP DATETIME2 NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR(50) NOT NULL, OPERATION_CODE VARCHAR(50) NOT NULL,
INITIATED_BY VARCHAR(100) NULL, INITIATED_BY VARCHAR(100) NULL,
OPERATION_DETAILS VARBINARY(MAX) DEFAULT NULL, OPERATION_DETAILS VARBINARY(MAX) DEFAULT NULL,

@ -173,8 +173,8 @@ WHEN (NEW.ID IS NULL)
CREATE TABLE DM_OPERATION ( CREATE TABLE DM_OPERATION (
ID NUMBER(10) NOT NULL, ID NUMBER(10) NOT NULL,
TYPE VARCHAR2(50) NOT NULL, TYPE VARCHAR2(50) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP(0) NOT NULL, CREATED_TIMESTAMP BIGINT NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP(0) NULL, RECEIVED_TIMESTAMP BIGINT NULL,
OPERATION_CODE VARCHAR2(1000) NOT NULL, OPERATION_CODE VARCHAR2(1000) NOT NULL,
INITIATED_BY VARCHAR2(100) NULL, INITIATED_BY VARCHAR2(100) NULL,
ENABLED NUMBER(10) DEFAULT 0 NOT NULL, ENABLED NUMBER(10) DEFAULT 0 NOT NULL,

@ -93,7 +93,7 @@ CREATE SEQUENCE DM_OPERATION_seq;
CREATE TABLE IF NOT EXISTS DM_OPERATION ( CREATE TABLE IF NOT EXISTS DM_OPERATION (
ID INTEGER DEFAULT NEXTVAL ('DM_OPERATION_seq') NOT NULL, ID INTEGER DEFAULT NEXTVAL ('DM_OPERATION_seq') NOT NULL,
TYPE VARCHAR(20) NOT NULL, TYPE VARCHAR(20) NOT NULL,
CREATED_TIMESTAMP TIMESTAMP(0) NOT NULL, CREATED_TIMESTAMP NOT NULL,
RECEIVED_TIMESTAMP TIMESTAMP(0) NULL, RECEIVED_TIMESTAMP TIMESTAMP(0) NULL,
OPERATION_CODE VARCHAR(50) NOT NULL, OPERATION_CODE VARCHAR(50) NOT NULL,
INITIATED_BY VARCHAR(100) NULL, INITIATED_BY VARCHAR(100) NULL,

Loading…
Cancel
Save