Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Legacy Server Code Bugs #174

Open
p-a-s-c-a-l opened this issue Jun 24, 2016 · 0 comments
Open

Legacy Server Code Bugs #174

p-a-s-c-a-l opened this issue Jun 24, 2016 · 0 comments
Assignees

Comments

@p-a-s-c-a-l
Copy link
Member

p-a-s-c-a-l commented Jun 24, 2016

Fix various related bugs in Legacy Server Code:

  • MetaClass.getEmptyInstance does not set JavaType  #166 MetaClass.getEmptyInstance does not set JavaType
    • fixed: resolve geometry type mismatch (see ClassCache.java#L400)
    • fixed: set java type from member attribute info in CidsBeanFactory'
    • fixed: set java class name from member attribute info in Sirius.serverlocalserver.object.ObjectFactory
      add ObjectAttribute.setClassKey in CidsBean.listElementAdded
  • Centralize Array Element Creation #171 Centralize Array Element Creation
    • not yet fixed
  • Inconsistent ObjectAttribute.getParentObject() behaviour #172 Inconsistent ObjectAttribute.getParentObject() behaviour
    • fixed: set parent object in addAttribute() of (Meta)Object)
    • fixed: set ReferencingObjectAttribute in setValue() of ObjectAttribute
  • Inconsitent ToStringConverter Behaviour #173 Inconsitent ToStringConverter Behaviour
    • fixed
  • CidsBeanJsonDeserializer IntraObjectCache Bugs #175 CidsBeanJsonDeserializer IntraObjectCache Bugs
  • Key in HashMap MetaObject().getAllClasses() is metaClass.getDomain()+metaClass.getId() (why !?!), but should be MetaClass.getKey()!
    • not fixed: inconsistency but no bug
  • MetaObject.getAttribute(String key) does not get an Attribute by its key (ObjectAttribute.getKey()) but by its name (not field name)!
    • fixed: change parameter name and javadoc
  • purpose of ObjectAttribute.substitute property unknown.
    • fixed: .isSubstitute() not used, mark as deprecated
  • NullPointerException in ObjectAttribute.getClassKey() if classKey and value are null.
    • fixed
  • boolean flag intraObjectCacheEnabled in CidsBean.createNewCidsBeanFromJSON() is not evaluated!
  • parent MetaObject ID is still -1 when array elements are added in CidsBeanJsonDeserializer
    • fixed
  • DUMMY / INTERMEDIATE Array Object inconsistencies cause standard meta object integrity unit tests to fails:
    • the class of the n-m dummy object is the intermediate array helper class but the class of the 1-n dummy object is the class of the parent meta object ("master")
    • the classKey and foreign key of the 1-n array attribute is the negative class id of the parent meta object ("master")
    • the array attributes of the dummy object are instances of the array attribute of the parent (master) class -> MemberAttributeInfos, classIds, etc. do not match in n-m dummy objects
    • objectIds of n-m and 1-n (?) dummy array attributes do not refer to the parent meta object but to the value meta object
    • workaround: exceptions in Unit Tests
  • wild MetaObject.STATUS guesses in Cids Bean. See CidsBeanJsonDeserializer.java#L301
  • workaround: exceptions in Unit Tests
  • property objectId of ObjectAttributes is not changed if ID of parent MetaObject changes
    • fixed in initAttributes, setID and addAttribute
  • Number of Attributes in CIdsBeans and MetaObjects with recursive structures (parent object contains itself as child object) are different: The Attribute that can cause a self-cycle is removed from the child MetaObject while the property that can cause a self-cycle is still present in CidsBean but set to null.
    • workaround: exceptions in Unit Tests
  • listElementReplaced not implemented in CidsBean! set(i) on BeanCollection not synchronised with MetaObject! -> could cause unwanted side effects when replacing array elements in CidsBean Collections!
    • not yet fixed
  • CidsBean.Collection Attribute id generation behaviour different from MetaObject Attribute id generation
    • not yet fixed
  • WARNING: 1-n Array element deleted when removed from CidsBean.java#L792: replacing 1-n array elements (as combination of delete and add!)
    • not yet fixed what is the expected behaviour?
  • WARNING: ObjectFactory.getInstance() broken! Does not support 1-n arrays, fails with NPE when trying to construct MetaObjects with 1-n array attribute (class with negative id not found)
    • not yet fixed
  • status flag MetaObject.TEMPLATE not supported anymore => delete
    • not yet fixed
@p-a-s-c-a-l p-a-s-c-a-l self-assigned this Jun 24, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 27, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 27, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 28, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 29, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 29, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 30, 2016
… its key (ObjectAttribute.getKey()) but by its name (not field name)!
p-a-s-c-a-l added a commit that referenced this issue Jun 30, 2016
p-a-s-c-a-l added a commit that referenced this issue Jun 30, 2016
p-a-s-c-a-l added a commit that referenced this issue Jul 1, 2016
p-a-s-c-a-l added a commit that referenced this issue Jul 5, 2016
p-a-s-c-a-l added a commit that referenced this issue Jul 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant