Title: Orion and MySQL

I am trying to set up orion to use MySQL instead of HypersonicSQL.  I'm looking for some advice on how to properly setup Orion to use the MySQL database that I have installed.

So far I have used the MySQL admin tool to creat a database called oriondb.  I have also edited the "data-sources.xml" and added a "mysql.xml" file under the database-schemas directory.  Here is a piece of the "data-sources.xml" file and a piece of the "mysql.xml":

data-sources.xml
----------------
  <data-source
    class="com.evermind.sql.DriverManagerDataSource"
    name="MySQL"
    location="jdbc/DefaultCoreDS"
    xa-location="jdbc/xa/DefaultXADS"
    ejb-location="jdbc/DefaultDS"
    pooled-location="jdbc/DefaultPooledDS"
    connection-driver="org.gjt.mm.mysql.Driver"
    username="root"
    password="root"
    url="jdbc:mysql://localhost/mysql/data/oriondb"
    inactivity-timeout="30"
    schema="database-schemas/mysql.xml"
  />


mysql.xml
---------
  <database-schema name="MySQL" not-null="not null" null="" primary-key="primary key">
    <type-mapping type="java.lang.String" name="char (255)" />
    <type-mapping type="int" name="int" />
    <type-mapping type="long" name="int" />
    <type-mapping type="float" name="float" />
    <type-mapping type="double" name="double" />
    <type-mapping type="byte" name="smallint" />
    <type-mapping type="char" name="char" />
    <type-mapping type="short" name="short" />
    <type-mapping type="java.util.Date" name="timestamp" />
       
    <disallowed-field name="password" />
    <disallowed-field name="username" />
    <disallowed-field name="date" />
    <disallowed-field name="order" />
  </database-schema>


I was very unsure as to what I should use for the "location" tags in the data-sources file.  Also, with the "mysql.xml" file, I copied the Hypersonic schema file and removed the boolean type-mapping (I thought this might be my problem).

The error I get when I deply states "SQL error: Communication link failure: Bad handshake".  If anyone has successfully deployed MySQL with Orion, I would be very much interested in the contents of their xml files.

- CJD

Reply via email to