C9 ResourceStreamer & MySQL
C9 ResourceStreamer & MySQL
- Subject: C9 ResourceStreamer & MySQL
- From: David Chaney <email@hidden>
- Date: Wed, 23 Mar 2005 17:06:57 -0500
I'm having trouble setting up the C9 ResourceStreamerApp (included with
the C9 ResourceStreamer framework) example with MySQL. I realize that
the example is setup to be used with FrontBase, but I have adjusted the
"Properties" file in Resources and adjusted my EO file, but still not
able to get it to run correctly. The project builds fine, but when
attaching blobs it fails with following error in the console:
[2005-03-23 16:46:43 EST] <main> Opening application's URL in browser:
http://aws1:62579/cgi-bin/WebObjects/ResourceStreamerApp.woa
RSRequestHandler: registerWithApplication
[2005-03-23 16:46:43 EST] <main> Waiting for requests...
DelayedSaver: registering new session bfZMPD49q8rLAYu7WcKbk0
start streaming to filesystem at 1111614414556
finished streaming to filesystem, wrote 144889 which took 0 seconds
WOResourcesStreamer initializing...
WOResourcesStreamer initializing... finished
upps: table=BLOB_ENTITY_IMPL, column=DATA, pkName=ID, id=25,
file=/tmp/C9_RS39901.tmp, length=144889
could not delayed save blob to database, reason Syntax error or access
violation, message from server: "You have an error in your SQL syntax.
Check the manual that corresponds to your MySQL server version for the
right syntax to use near '"BLOB_ENTITY_IMPL" SET "DATA" =
'\377\330\377\340\0JFIF\0\0\0d\0d\0\0\377\354\\354\354
I tried several things with my properties file, but still no success.
It consists of the following:
# Properties for ResourceStreamer framework
# the JDBC driver classname
com.cluster9.resourcestreamer.jdbc-driver=com.mysql.jdbc.Driver
# the connection URL for the jdbc driver
com.cluster9.resourcestreamer.jdbc-url=jdbc:mysql:/127.0.0.1/
ResourceStreamerApp?capitalizeTypeNames=true
# the database user to use in the connection dictionary
com.cluster9.resourcestreamer.user=testuser
# the database password to use in the connection dictionary
com.cluster9.resourcestreamer.password=testpass
# the minimum number of JDBC connections to use
com.cluster9.resourcestreamer.min-connections=1
# the maximum number of JDBC connections to use
# keep in mind that each connection requires an open file
# this means your UNIX process which is running the JVM from
# your application must be able to use a lot of open files.
# see ulimit to understand how to change the default settings
# For each concurrect upload you must have one JDBC Connection
# available. Otherwise the system will wait until a JDBC Connection
# is free and will delay the saving of the Blob until then.
com.cluster9.resourcestreamer.max-connections=10
# path to the logfile for the JDBC connection pooling
com.cluster9.resourcestreamer.log-path=/tmp/dbbroker.log
# time how long a JDBC connection should be reused
com.cluster9.resourcestreamer.connection-recycle=1.0
# time in seconds how long a request may use a connection
# in this case a download may not take longer than 3 days
com.cluster9.resourcestreamer.max-checkout=259200
# debug level for the Connection Pooling, 0 - 3
com.cluster9.resourcestreamer.debug-level=3
# default number of days after which the media will expire
# is used for the WOResponses headers
com.cluster9.resourcestreamer.expireDays=100
# true if ResourceStreamer should save the binary data in the
# database, false if not. If not then the BlobEntity should
# have a valid value for getFilesystemPath !
com.cluster9.resourcestreamer.saveToDatabase=true
# if set to true and saveToDatabase is also true then
# a BlobEntity that was downloaded once is cached in the filesystem
# for better speed until it is modified.
# FIXME: we should compare the filelength and lastmodified timestamp
# each time the file is accessed and then refresh the cache if
# necessary
com.cluster9.resourcestreamer.cacheInFilesystem=false
com.cluster9.resourcestreamer.read_write_transaction_statement=set
transaction isolation level repeatable read;
com.cluster9.resourcestreamer.read_only_transaction_statement=set
transaction isolation level repeatable read;
It almost appears to be failing "DelayedSaver.java" object. Any help
greatly appreceated...
- David
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden