Topic
  • 4 replies
  • Latest Post - ‏2012-08-02T18:35:16Z by Dave Sanders
Pratz25
Pratz25
8 Posts

Pinned topic CMIS says the propertydef has a choice list when FEM says <NONE>

‏2012-07-27T10:17:28Z |
Hi all,
I am in learning phase of CMIS and filenet.

Making a webapplication using openCMIS and GWT.

While retriving the choice list of a propertyDefination , I got the choiceList but in FEM there is no choice List.

I already restarted my CE , webApplication many time.(neway i got this Problem yesterday so i guess no problem with cache list)

Attaching file with image ,code and Output.

public void getDocumentClass() {
// TODO Auto-generated method stub

System.out.println("checking " + session.getRepositoryInfo());
ItemIterable<ObjectType> v = session.getTypeChildren("cmis:document", true);
Iterator<ObjectType> i = v.iterator();

while(i.hasNext()){
ObjectType a = i.next();
if(a!=null){
System.out.println("Document Class Name - >" +a.getDisplayName());

Map<String, PropertyDefinition<?>> d = a.getPropertyDefinitions();

Iterator<String> itr = d.keySet().iterator();
while(itr.hasNext()){

String key = itr.next().toString();

if ((Boolean.FALSE.equals(d.get(key).isInherited())){
PropertyDefinition value = d.get(key);
System.out.println("Property Defination ->> " key" ***** " + " display name -> " +value.getDisplayName() );
List<Choice> ch = value.getChoices();
System.out.print("size of choice List " + ch.size());

for (Choice choice : ch) {

System.out.print(" choice list ->" +choice.getDisplayName())
}
System.out.println("");
System.out.println("");

}
}
}
}
}

OutPut :

Document Class Name - >Email
Property Defination ->> DocumentTitle ***** display name -> Document Title
size of choice List 0

Property Defination ->> From ***** display name -> From
size of choice List 0

Property Defination ->> To ***** display name -> To
size of choice List 0

Property Defination ->> CarbonCopy ***** display name -> Cc
size of choice List 2 choice list ->User choice list ->Site

Property Defination ->> EmailSubject ***** display name -> Subject
size of choice List 3 choice list ->document choice list ->folder choice list ->customobject

Property Defination ->> SentOn ***** display name -> Sent On
size of choice List 0

Property Defination ->> ReceivedOn ***** display name -> Received On
size of choice List 0

Document Class Name - >Record
Property Defination ->> DocumentTitle ***** display name -> Document Title
size of choice List 0

Property Defination ->> RecordedDocuments ***** display name -> RecordedDocuments
size of choice List 0

________________________________________________________________________________________________

Document Class Name - >training
Property Defination ->> DocumentTitle ***** display name -> Document Title
size of choice List 0

Property Defination ->> AnimationEnabled ***** display name -> Animation Enabled
size of choice List 0

Property Defination ->> ReceivedOn ***** display name -> Received On
size of choice List 0

Property Defination ->> EmailSubject ***** display name -> Subject
size of choice List 3 choice list ->document choice list ->folder choice list ->customobject

Property Defination ->> checking ***** display name -> checking
size of choice List 0

Property Defination ->> testingBoolean ***** display name -> testingBoolean
size of choice List 0

Property Defination ->> testingDate ***** display name -> testingDate
size of choice List 0

Property Defination ->> testString ***** display name -> testString
size of choice List 0

Plz tell me how to rectify this.

thanks
Updated on 2012-08-02T18:35:16Z at 2012-08-02T18:35:16Z by Dave Sanders
  • jay.brown
    jay.brown
    41 Posts

    Re: CMIS says the propertydef has a choice list when FEM says &lt;NONE&gt;

    ‏2012-07-27T20:56:06Z  
    It seems you may have stumbled onto a more advanced type of issue here. One that might be outside the scope of CMIS. I spoke to an internal expert about this. He did not know what the problem was but said “...I have a hunch whatever is going on might be related to there being a CVL defined on the underlying PropertyTemplate and not overridden at the PropertyDefinition level for one of the two cases”. If this is the case then we should move this issue over to the IBM Filenet Content Manager forum for help here:
    http://www.ibm.com/developerworks/forums/forum.jspa?forumID=1165

    But before we do that, let's first eliminate the CMIS server and Chemistry API from the scenario so we know for sure this is a pure CE related question. To do this please code up the same logic using the native P8 API :
    http://publib.boulder.ibm.com/infocenter/p8docs/v5r1m0/nav/11_2_3

    After doing that, if we see the same result, then we know this is a CE issue and we can go to pure CE support for the answer. If you see a different result then we know that the problem is either OpenCMIS caching something (maybe a bug) or the CMIS server caching something incorrectly (maybe a bug). Either way we can fix if that is the case once we know for sure.

    Thanks
  • Pratz25
    Pratz25
    8 Posts

    Re: CMIS says the propertydef has a choice list when FEM says &lt;NONE&gt;

    ‏2012-08-02T07:28:50Z  
    • jay.brown
    • ‏2012-07-27T20:56:06Z
    It seems you may have stumbled onto a more advanced type of issue here. One that might be outside the scope of CMIS. I spoke to an internal expert about this. He did not know what the problem was but said “...I have a hunch whatever is going on might be related to there being a CVL defined on the underlying PropertyTemplate and not overridden at the PropertyDefinition level for one of the two cases”. If this is the case then we should move this issue over to the IBM Filenet Content Manager forum for help here:
    http://www.ibm.com/developerworks/forums/forum.jspa?forumID=1165

    But before we do that, let's first eliminate the CMIS server and Chemistry API from the scenario so we know for sure this is a pure CE related question. To do this please code up the same logic using the native P8 API :
    http://publib.boulder.ibm.com/infocenter/p8docs/v5r1m0/nav/11_2_3

    After doing that, if we see the same result, then we know this is a CE issue and we can go to pure CE support for the answer. If you see a different result then we know that the problem is either OpenCMIS caching something (maybe a bug) or the CMIS server caching something incorrectly (maybe a bug). Either way we can fix if that is the case once we know for sure.

    Thanks
    I checked with the native P8 API. It is working fine..
  • jay.brown
    jay.brown
    41 Posts

    Re: CMIS says the propertydef has a choice list when FEM says &lt;NONE&gt;

    ‏2012-08-02T16:30:51Z  
    • Pratz25
    • ‏2012-08-02T07:28:50Z
    I checked with the native P8 API. It is working fine..
    Ok. Now we are getting somewhere then! As you may know, the FileNet CMIS impl uses the native java API too. So all we need to do is reproduce this issue in our lab; then we can then safely call it a bug and get resources to squash it. Can you send us some instructions for setting up test classes and property definitions (and CVLs) where this can be reproduced? They do not have to be as complex as yours. Just close enough where you can still see the problem. Also we will need to have the native API code that you used to verify that the CVLs were indeed not present. Then we can compare what our native API code is doing internally versus yours.
  • Dave Sanders
    Dave Sanders
    19 Posts

    Re: CMIS says the propertydef has a choice list when FEM says &lt;NONE&gt;

    ‏2012-08-02T18:35:16Z  
    • Pratz25
    • ‏2012-08-02T07:28:50Z
    I checked with the native P8 API. It is working fine..
    1. Try disabling CMIS's CVL caching: Add "CVL_Cache=false" to WEB-INF/classes/cmis.properties, and restart the app. That will ensure that com.filenet.api.meta.PropertyDescription.get_ChoiceList() is called every time a property definition is requested.

    2) Ensure that the same user is used for both FEM (where NONE is displayed) and CMIS.