Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [SOLVED][CDO] - Migrating from 4.6 to 4.10 - IllegalStateException type mapping EFeatureMapEntry
[SOLVED][CDO] - Migrating from 4.6 to 4.10 - IllegalStateException type mapping EFeatureMapEntry [message #1835980] Thu, 17 December 2020 16:23 Go to next message
Philippe EUGENE is currently offline Philippe EUGENEFriend
Messages: 58
Registered: January 2011
Member
In my EMF model i have an EAttribute with type EFeatureMapEntry

In 4.6, the mapping is correct.
CDO created a db table as is :
Quote:

CDO_SOURCE BIGINT
CDO_VERSION INTEGER
CDO_IDX INTEGER
CDO_FEATURE BIGINT
CDO_VALUE_SMALLINT SMALLINT
CDO_VALUE_BIGINT BIGINT
CDO_VALUE_LONGVARCHAR VARCHAR
CDO_VALUE_VARCHAR VARCHAR
CDO_VALUE_CLOB CLOB
CDO_VALUE_BOOLEAN BOOLEAN
CDO_VALUE_BLOB BLOB
CDO_VALUE_DATE DATE
CDO_VALUE_VARBINARY BLOB
CDO_VALUE_CHAR CHAR
CDO_VALUE_FLOAT REAL
CDO_VALUE_TIMESTAMP TIMESTAMP
CDO_VALUE_INTEGER INTEGER
CDO_VALUE_TIME TIME
CDO_VALUE_DOUBLE DOUBLE


In CDO 4.10, the EAttribute is passed in the method TypeMappingRegistry#createTypeMapping().

In this method an exception occured :
Quote:

java.lang.IllegalStateException: No type mapping factory found for DocumentRoot.mixed: ecore.EFeatureMapEntry --> DBType.VARCHAR


In version 4.6, the same EAttribute is nerver passed to TypeMappingRegistry#createTypeMapping().

Thanks for reply,
--
Philippe

[Updated on: Fri, 18 December 2020 09:19]

Report message to a moderator

Re: [CDO] - Migrating from 4.6 to 4.10 - IllegalStateException on type mapping for EFeatureMapEntry [message #1836008 is a reply to message #1835980] Fri, 18 December 2020 08:09 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6682
Registered: July 2009
Senior Member
Feature maps were never properly supported in CDO. Even though the database mappings may have been created, there evolved more and more places in the code where feature maps were not considered/handled. After years of deprecation all remaining code for feature map handling was removed this May: https://bugs.eclipse.org/bugs/show_bug.cgi?id=562011

Re: [CDO] - Migrating from 4.6 to 4.10 - IllegalStateException on type mapping for EFeatureMapEntry [message #1836012 is a reply to message #1836008] Fri, 18 December 2020 08:48 Go to previous messageGo to next message
Philippe EUGENE is currently offline Philippe EUGENEFriend
Messages: 58
Registered: January 2011
Member
Ok, thanks Eike. We will consider an alternative to MapEntry
Re: [CDO] - Migrating from 4.6 to 4.10 - IllegalStateException on type mapping for EFeatureMapEntry [message #1836013 is a reply to message #1836012] Fri, 18 December 2020 08:58 Go to previous messageGo to next message
Philippe EUGENE is currently offline Philippe EUGENEFriend
Messages: 58
Registered: January 2011
Member

It has been a while since we had to modify this part of the model (rest of an old model), the migration to CDO 4.10 will be an opportunity to refactoring
Re: [CDO] - Migrating from 4.6 to 4.10 - IllegalStateException on type mapping for EFeatureMapEntry [message #1836016 is a reply to message #1836013] Fri, 18 December 2020 09:48 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6682
Registered: July 2009
Senior Member
I'm glad to hear that. Good luck ;-)

Re: [CDO] - Migrating from 4.6 to 4.10 - IllegalStateException on type mapping for EFeatureMapEntry [message #1841760 is a reply to message #1836016] Fri, 28 May 2021 00:14 Go to previous message
Warwick Burrows is currently offline Warwick BurrowsFriend
Messages: 132
Registered: July 2009
Location: Austin, TX
Senior Member
FYI, I had a similar issue with the CDO server 4.12 and two core data types Blob and EBoolean. I had to define typeMapping DBStore annotations for them because the tuple lookup for these types wasn't working. And it wasn't clear looking at the code in the debugger why the lookup didn't work because the tuple being passed matched the key needed to get the type for the Blob at least. For EBoolean though the DBType lookup wasn't returning a valid type for the EBoolean.
Previous Topic:EMF ecore and genmodel editors and documentation for them
Next Topic:[CDO] CDOModelUtil lookup for coreTypes varies between server startup and client call
Goto Forum:
  


Current Time: Tue Apr 16 05:19:09 GMT 2024

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

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

Back to the top