[EMFStore] How to resolve checksum errors? [message #1735065] |
Wed, 15 June 2016 08:05 |
Phil Beauvoir Messages: 62 Registered: October 2012 |
Member |
|
|
Hi,
I am experimenting with EMFStore with our modelling tool, Archi (http://www.archimatetool.com). I'm using Eclipse 4.6 RC4a and EMFStore 1.8 (latest version).
I've adapted the "helloworld" example to commit, update and checkout an Ecore model from our Archi app. Mostly it works, but I am seeing many checksum errors when committing the model:
"Update cancelled by checksum error handler due to invalid checksum."
I registered a ChecksumErrorHandler to return true so as to ignore the errors, and it seems that the commits are taking place, but obviously something is wrong.
My model code is very customised and I don't use proxies on EReferences.
Is there some guidance on what makes a model "well behaved" to work with EMFStore so as to avoid checksum errors?
[Updated on: Wed, 15 June 2016 08:44] Report message to a moderator
|
|
|
Re: How to resolve checksum errors? [message #1735367 is a reply to message #1735065] |
Fri, 17 June 2016 16:21 |
Edgar Mueller Messages: 17 Registered: March 2016 |
Junior Member |
|
|
Hi Phil,
there is some general advise, which is, that, if possible, customizing
EMF generated code should be avoided. This is not just true for
EMFStore, but also for other EMF-based frameworks.
The reasons in case of EMFStore are, that getters are called during the
serialization and setters are called during the de-serialization phase.
Both should have no side-effects, e.g. model changes in getters should
be avoided.
Also, you should not change any of the initialization of default values
within the generated factories, again, because possible side-effects
could occur.
So, to sum up, avoid customizing generated EMF code and in case this is
not possible, pay extra attention to not cause any side-effects that
could alter the behaviour during serialization/de-serialization.
HTH
Cheers,
Edgar
> Hi,
>
> I am experimenting with EMFStore with our modelling tool, Archi
> (http://www.archimatetool.com). I'm using Eclipse 4.6 RC4a and EMFStore
> 1.8 (latest version).
>
> I've adapted the "helloworld" example to commit, update and checkout an
> Ecore model from our Archi app. Mostly it works, but I am seeing many
> checksum errors when committing the model:
>
> "Update cancelled by checksum error handler due to invalid checksum."
>
> I registered a ChecksumErrorHandler to return true so as to ignore the
> errors, and it seems that the commits are taking place, but obviously
> something is wrong.
>
> My model code is very customised and I don't use proxies on EReferences.
>
> Is there some guidance on what makes a model "well behaved" to work with
> EMFStore so as to avoid checksum errors?
--
Edgar Mueller
Get Professional Eclipse Support:
http://eclipsesource.com/en/services/developer-support/
--
Edgar Mueller
Get professional Eclipse developer support:
http://eclipsesource.com/en/services/developer-support/
|
|
|
|
Powered by
FUDForum. Page generated in 0.04994 seconds