Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » [CDO] Storing multivalue-attributes
[CDO] Storing multivalue-attributes [message #119508] Tue, 22 April 2008 12:43 Go to next message
Stefan Winkler is currently offline Stefan WinklerFriend
Messages: 307
Registered: July 2009
Location: Germany
Senior Member
Hi Eike,

I have reached a point in development, where I'd like to store an
EAttribute with upperBound = -1.
If the EAttribute type is String, EMF generates getMyAttribute() :
EList<String>
What reaches MySQLAdapter.appendValue() is a MoveableArrayList<String>.
As nobody in the DBAdapter - DBField chain knows how to deal with
MoveableArrayLists, this results in a failing SQL statement.

=> filed Bug 228190 <https://bugs.eclipse.org/bugs/show_bug.cgi?id=228190>

Other than with the Date type, which I patched (see Bug 217255
<https://bugs.eclipse.org/bugs/show_bug.cgi?id=217255>), and for which
deserialization works out of the box, with this case, I do not really
know, what to do.

I guess to be able to achieve serialization, the DBField, DBAdapter and
maybe something in cdo.server.internal.db.* have to be extended. So one
could think of a way to serialize such an attribute as a Blob, but then,
the natural way would be to create an own table.

Do you have an idea, how this can be handled, or can you provide a
quickfix for that issue?

How is the CDO-Teneo-Hibernate-Mapping getting along? When will it be
useable as an alternative in order to work around the problems with the
MySQL database support?

Cheers,
Stefan
Re: [CDO] Storing multivalue-attributes [message #119548 is a reply to message #119508] Tue, 22 April 2008 14:56 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6690
Registered: July 2009
Senior Member
Hi Stefan,

I knew this would become an issue some day. And I'm pretty sure that there
is no simple quick fix appropriate ;-( I've noticed that you filed a
Bugzilla and that's generally a good idea. I could imagine that I come to
this issue when I redesign the DBStore to use more prepared statements (to
fix problems like the date handling one). But chances are not good that
this will be very soon because there's a lot of higher priority work to be
done for the ganymede release.

The HibernateStore should be ready for a while to be used in CDO
repositories. I'm currently working with Nick (planned for this week) to
integrate it into the automated build. If you work with the HEAD sources
in your workspace, I recommend that you just test that and report your
experiences. From a mapping point of view I guess that Hibernate will rest
unmatched ;-)

Cheers
/Eike



Stefan Winkler wrote:

> Hi Eike,

> I have reached a point in development, where I'd like to store an
> EAttribute with upperBound = -1.
> If the EAttribute type is String, EMF generates getMyAttribute() :
> EList<String>
> What reaches MySQLAdapter.appendValue() is a MoveableArrayList<String>.
> As nobody in the DBAdapter - DBField chain knows how to deal with
> MoveableArrayLists, this results in a failing SQL statement.

> => filed Bug 228190 <https://bugs.eclipse.org/bugs/show_bug.cgi?id=228190>

> Other than with the Date type, which I patched (see Bug 217255
> <https://bugs.eclipse.org/bugs/show_bug.cgi?id=217255>), and for which
> deserialization works out of the box, with this case, I do not really
> know, what to do.

> I guess to be able to achieve serialization, the DBField, DBAdapter and
> maybe something in cdo.server.internal.db.* have to be extended. So one
> could think of a way to serialize such an attribute as a Blob, but then,
> the natural way would be to create an own table.

> Do you have an idea, how this can be handled, or can you provide a
> quickfix for that issue?

> How is the CDO-Teneo-Hibernate-Mapping getting along? When will it be
> useable as an alternative in order to work around the problems with the
> MySQL database support?

> Cheers,
> Stefan


Re: [CDO] Storing multivalue-attributes [message #617876 is a reply to message #119508] Tue, 22 April 2008 14:56 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6690
Registered: July 2009
Senior Member
Hi Stefan,

I knew this would become an issue some day. And I'm pretty sure that there
is no simple quick fix appropriate ;-( I've noticed that you filed a
Bugzilla and that's generally a good idea. I could imagine that I come to
this issue when I redesign the DBStore to use more prepared statements (to
fix problems like the date handling one). But chances are not good that
this will be very soon because there's a lot of higher priority work to be
done for the ganymede release.

The HibernateStore should be ready for a while to be used in CDO
repositories. I'm currently working with Nick (planned for this week) to
integrate it into the automated build. If you work with the HEAD sources
in your workspace, I recommend that you just test that and report your
experiences. From a mapping point of view I guess that Hibernate will rest
unmatched ;-)

Cheers
/Eike



Stefan Winkler wrote:

> Hi Eike,

> I have reached a point in development, where I'd like to store an
> EAttribute with upperBound = -1.
> If the EAttribute type is String, EMF generates getMyAttribute() :
> EList<String>
> What reaches MySQLAdapter.appendValue() is a MoveableArrayList<String>.
> As nobody in the DBAdapter - DBField chain knows how to deal with
> MoveableArrayLists, this results in a failing SQL statement.

> => filed Bug 228190 <https://bugs.eclipse.org/bugs/show_bug.cgi?id=228190>

> Other than with the Date type, which I patched (see Bug 217255
> <https://bugs.eclipse.org/bugs/show_bug.cgi?id=217255>), and for which
> deserialization works out of the box, with this case, I do not really
> know, what to do.

> I guess to be able to achieve serialization, the DBField, DBAdapter and
> maybe something in cdo.server.internal.db.* have to be extended. So one
> could think of a way to serialize such an attribute as a Blob, but then,
> the natural way would be to create an own table.

> Do you have an idea, how this can be handled, or can you provide a
> quickfix for that issue?

> How is the CDO-Teneo-Hibernate-Mapping getting along? When will it be
> useable as an alternative in order to work around the problems with the
> MySQL database support?

> Cheers,
> Stefan


Previous Topic:[CDO] Storing multivalue-attributes
Next Topic:Not able to start CDO Server
Goto Forum:
  


Current Time: Sat Nov 09 02:40:52 GMT 2024

Powered by FUDForum. Page generated in 0.02633 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top