[I'm posting this commit message again here because people on this
list need this info and probably do not get the svn commit
messages...]
ian
WARNING: This checkin changes the database format! If you have data in
an ogoglio server
WARNING: that you want to preserve, be sure to make a backup before
attempting to switch
WARNING: to this version of the server! Better yet, perhaps wait
until this change has
WARNING: been verified to work in your configuration on the
ogoglio-developers mailing list.
WARNING: There is a new tool in this version:
com.ogogilo.persist.MigrateDB_TemplateTables
WARNING: which will attempt to migrate data between versions. This
program is a horrendous
WARNING: hack, but appears to work correctly for the "development
configuration" of
WARNING: hsqldb + FileStore for media. Instructions for using that
migrate a set of data
WARNING: between versions is in that file, but be sure to make a
backup because that
WARNING: hasn't been tested in all configurations.
WARNING: This is *known* to not work with the WebStore. That change
shoud be forthcoming
WARNING: shortly. If you are using Web-based storage of your media
files, do not upgrade
WARNING: to this version.
This is significant, but "behind the scenes" change; it should not be
visible to users.
The objective of this change was to support a more complex type of
TemplateDocument
that looks like this (note the new child elements):
<template ownerusername="susan" templateid="3" displayname="Test Cube">
<supportfile filename="TestCube.gif" lastmodifiedUTC="Sunday, July
22, 2007 5:09:55 PM PDT"/>
<scriptfile lastmodifiedUTC="Sunday, July 22, 2007 5:09:55 PM PDT"/>
<geometry levelofdetail="0" lastmodifiedUTC="Sunday, July 22, 2007
5:09:55 PM PDT"/>
<supportfile filename="TestCube.mtl" lastmodifiedUTC="Sunday, July
22, 2007 5:09:55 PM PDT"/>
</template>
These new elements allow any user of template documents to know about
the other files related to the
template and when they were last modified. Eventually, this will be
used to support a client-side
program that can keep a set of templates "synchronized" with the
server so that one can do editing
on a local machine of a set of templates for some application, and the
synchronization tool does all
necessary updating of the server. This is much more convenient than
the current situation, which
requires the use of many web pages. The beginnings of that tool--not
yet completed--are in
com.ogoglio.templatesync but this should not be used yet as it is
under active development.
A side-effect of this change was to do enough bookkeeping in the
database to be able to generate these
templates without needing to ask the media server each time a template
is downloaded. As part of
this effort, we now use Hibernate much more extensively to maintain
these associations between templates
and their support files. If this continues work well, all associations
may eventually be converted to
using Hibernate to maintain them; this is being put in place as a test
of this functionality.
------- OTHER CHANGES ---------
A change has been started in WebAPIClient to move all of the actual
code that touches the HTTP protocol
itself (the wire) into WebAPIClientWire in an effort to eventually
allow WebAPIClient to be free
of network code and (one day) be able to run without a network using a
mock. For now, the code
that is involved with templates has been converted and the new style
can be checked out if one is
interested. WebAPIClientWire, for now, contains *copies* of the
networking code in WebAPIClient
so that existing code can be left undisturbed in WebAPIClient.
ClientTests has been revamped to make understanding what tests are
being performed easier to understand.
The process of removing the inter-test dependencies has been started.
New tests have been added to
insure that the new template support files and last modified times are
working properly.
Fixed a bug in Thing.reload() where the shapes table was not being
cleared. This had not been frequently
observed to the use of a hash table which was masking the problem for
most users.
MediaStore has been changed to support the listing of all files. This
API call is not yet rolled all
the way through to WebStore, thus we know the migration tool cannot
work because the migration tool needs
this call to function properly to work at all.
Many changes were needed in the com.ogoglio.persist package to support
the new types of data that we
are now storing. These changes were mostly in the TemplateRecord and
in the TemplateSupportFileRecord
classes. Some (all?) of the Hibernate test setup code has now been
factored out in an effort
to make writing Hibernate tests easier. A problem with dependencies
in ClientTests led to much work
on the PossessionRecord in an effort to be sure that Space deletion
functioned properly. Nothing
was broken, but in the debugging process new constants were added
PossessionRecord to indicate
the lack of a Space, lack of a Thing, etc. This change should
probably be rolled into all the places
we currently use -1 as a signal value, as these different constants
make the code more clear and
easier to debug.
|