mirror of https://github.com/apache/activemq.git
AMQ-6057: Add performance patch to JDBC statements definition
This commit is contained in:
parent
2a56c6037d
commit
8bc3ee29cd
|
@ -95,7 +95,7 @@ public class Statements {
|
|||
if (createSchemaStatements == null) {
|
||||
createSchemaStatements = new String[] {
|
||||
"CREATE TABLE " + getFullMessageTableName() + "(" + "ID " + sequenceDataType + " NOT NULL"
|
||||
+ ", CONTAINER " + containerNameDataType + ", MSGID_PROD " + msgIdDataType + ", MSGID_SEQ "
|
||||
+ ", CONTAINER " + containerNameDataType + " NOT NULL, MSGID_PROD " + msgIdDataType + ", MSGID_SEQ "
|
||||
+ sequenceDataType + ", EXPIRATION " + longDataType + ", MSG "
|
||||
+ (useExternalMessageReferences ? stringIdDataType : binaryDataType)
|
||||
+ ", PRIMARY KEY ( ID ) )",
|
||||
|
@ -390,7 +390,7 @@ public class Statements {
|
|||
public String getFindAllDestinationsStatement() {
|
||||
if (findAllDestinationsStatement == null) {
|
||||
findAllDestinationsStatement = "SELECT DISTINCT CONTAINER FROM " + getFullMessageTableName()
|
||||
+ " UNION SELECT DISTINCT CONTAINER FROM " + getFullAckTableName();
|
||||
+ " WHERE CONTAINER IS NOT NULL UNION SELECT DISTINCT CONTAINER FROM " + getFullAckTableName();
|
||||
}
|
||||
return findAllDestinationsStatement;
|
||||
}
|
||||
|
@ -991,4 +991,4 @@ public class Statements {
|
|||
public void setLeaseOwnerStatement(String leaseOwnerStatement) {
|
||||
this.leaseOwnerStatement = leaseOwnerStatement;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue