activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Tully <gary.tu...@gmail.com>
Subject Re: Enabling JDBC Master/Slave
Date Wed, 19 Oct 2011 22:43:48 GMT
can you try a current 5.6-SNAPSHOT

There is a know issue with SQLServer tying to modify existing tables,
you can use createTablesOnStartup="false" to stop the modifications.

https://issues.apache.org/jira/browse/AMQ-3075

On 17 October 2011 23:08,  <shaun.t.erickson@accenture.com> wrote:
>>I wrote:
>>
>>... the log reports:
>>
>>Could not get JDBC connection: Cannot load JDBC driver class 'com.microsoft.sqlserver.jdbc.SQLServerDriver'
>>Does this class not come with AMQ? Do I need to obtain this class from someplace and
install it under AMQ somewhere?
>
> Okay. I got the sqljdbc4_2008.jar file we use to talk to our database and dropped it
in AMQ's lib/optional directory. Then I found it couldn't login to our DB because it was empty
and had no user account defined. I had our DB guy make an account and then AMQ was able to
login to the DB.
>
> It created the tables, and they appear to basically match the table descriptions given
in 'ActiveMQ in Action' (which is already out of date), but there were two warnings and then
a repeated error, in the logs:
>
> INFO   | jvm 1    | 2011/10/17 17:22:18 |  WARN | Could not create JDBC tables; they
could already exist. Failure was: ALTER TABLE ACTIVEMQ_ACKS DROP PRIMARY KEY Message: Incorrect
syntax near the keyword 'PRIMARY'. SQLState: S0001 Vendor code: 156
> INFO   | jvm 1    | 2011/10/17 17:22:18 |  WARN | Failure details: Incorrect syntax
near the keyword 'PRIMARY'.
>
> ...
>
> INFO   | jvm 1    | 2011/10/17 17:22:19 |  WARN | Could not create JDBC tables; they
could already exist. Failure was: ALTER TABLE ACTIVEMQ_ACKS ADD PRIMARY KEY (CONTAINER, CLIENT_ID,
SUB_NAME, PRIORITY) Message: Table 'ACTIVEMQ_ACKS' already has a primary key defined on it.
SQLState: S0000 Vendor code: 1779
> INFO   | jvm 1    | 2011/10/17 17:22:19 |  WARN | Failure details: Table 'ACTIVEMQ_ACKS'
already has a primary key defined on it.
> INFO   | jvm 1    | 2011/10/17 17:22:19 | com.microsoft.sqlserver.jdbc.SQLServerException:
Table 'ACTIVEMQ_ACKS' already has a primary key defined on it.
>
> ...
>
> INFO   | jvm 1    | 2011/10/17 17:22:20 |  INFO | Database lock driver override recognized
for : [microsoft_sql_server_jdbc_driver_3_0] - adapter: class org.apache.activemq.store.jdbc.adapter.TransactDatabaseLocker
> INFO   | jvm 1    | 2011/10/17 17:22:20 |  INFO | Attempting to acquire the exclusive
lock to become the Master broker
> INFO   | jvm 1    | 2011/10/17 17:22:20 | ERROR | Failed to acquire lock: com.microsoft.sqlserver.jdbc.SQLServerException:
A processing error "Line 1: FOR UPDATE clause allowed only for DECLARE CURSOR." has occurred.
> INFO   | jvm 1    | 2011/10/17 17:22:20 | com.microsoft.sqlserver.jdbc.SQLServerException:
A processing error "Line 1: FOR UPDATE clause allowed only for DECLARE CURSOR." has occurred.
>
> My DB guy says that it looks to him like AMQ is sending Oracle SQL, not SQL Server SQL.
I don't know how to tell AMQ what syntax it should be using. I do know that until AMQ can
obtan that lock, this is never going to work.
>
> Suggestions?
>
> Thanks, in advance, for you time and consideration.
>
> -ste
>
> This message is for the designated recipient only and may contain privileged, proprietary,
or otherwise private information.  If you have received it in error, please notify the sender
immediately and delete the original.  Any other use of the email by you is prohibited.
>



-- 
http://fusesource.com
http://blog.garytully.com

Mime
View raw message