chemistry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergio Lemos (JIRA)" <j...@apache.org>
Subject [jira] [Created] (CMIS-751) "Input String was not in a correct format" exception while trying to get a document from Alfresco
Date Thu, 16 Jan 2014 12:02:19 GMT
Sergio Lemos created CMIS-751:
---------------------------------

             Summary: "Input String was not in a correct format" exception while trying to
get a document from Alfresco
                 Key: CMIS-751
                 URL: https://issues.apache.org/jira/browse/CMIS-751
             Project: Chemistry
          Issue Type: Bug
          Components: dotcmis
    Affects Versions: DotCMIS 0.6
         Environment: Alfresco 4.2
            Reporter: Sergio Lemos
            Priority: Minor


Accessing Alfresco repository through CMIS using the .Net DotCMIS library, a "Input String
was not in a correct format" is thrown when it is tried to get a document by its documentID.


This behavior happens on Alfresco 4.2, but not happens on 4.0.2. 

Analysing the network traffic generated by the communication of the DotCMIS library with the
Alfresco server, it has been noted that the following data is sent by Alfresco: 

<cmis:propertyDecimalDefinition> 
<cmis:id>sf_afi:vlr_total</cmis:id> 
<cmis:localName>vlr_total</cmis:localName> 
<cmis:localNamespace>sf_afi.model.procergs.rs.gov.br</cmis:localNamespace> 
<cmis:displayName>Valor Total do Auto de Lanamento</cmis:displayName> 
<cmis:queryName>sf_afi:vlr_total</cmis:queryName> 
<cmis:description>Valor Total do Auto de Lanamento</cmis:description> 
<cmis:propertyType>decimal</cmis:propertyType> 
<cmis:cardinality>single</cmis:cardinality> 
<cmis:updatability>readwrite</cmis:updatability> 
<cmis:inherited>false</cmis:inherited> 
<cmis:required>false</cmis:required> 
<cmis:queryable>true</cmis:queryable> 
<cmis:orderable>true</cmis:orderable> 
<cmis:maxValue>1.7976931348623157E+308</cmis:maxValue> 
<cmis:minValue>4.9E-324</cmis:minValue> 
</cmis:propertyDecimalDefinition> 

The DotCMIS library tries to convert the minValue and maxValue constraints from its String
representation to a Decimal data type. This is where the exception happens, the value 1.7976931348623157E+308
cannot be converted to a Decimal by the .Net Framework. 

Analysing the same communication with Alfresco 4.0.2 server, it has been noted that Alfresco
4.0.2 doesn't send the minValue and maxValue constraints to the client, therefore, there is
no errors. 

The concerned property is defined as a d:double. We beleave that the problem comes from the
conversion from double to decimal.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message