[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-27 Thread Stefan Egli (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14716532#comment-14716532
 ] 

Stefan Egli commented on OAK-3288:
--

replaced that usage of set(,Map) with setMapEntry() in 
http://svn.apache.org/r1698126
/fyi [~reschke]

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Julian Reschke (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14712915#comment-14712915
 ] 

Julian Reschke commented on OAK-3288:
-

If we wanted to change the signature for set() away from Object, what types 
would we need? Obviously String, long, and boolean, but I also see a case where 
a Map is set...

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Marcel Reutegger (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14712969#comment-14712969
 ] 

Marcel Reutegger commented on OAK-3288:
---

bq. I also see a case where a Map is set

This doesn't sound right. The intention of the UpdateOp is to rather provide 
setMapEntry() for this purpose.

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Stefan Egli (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14713401#comment-14713401
 ] 

Stefan Egli commented on OAK-3288:
--

PS: until OAK-3288 is there I had to do an ugly 'instanceof' in 
ClusterViewDocument (http://svn.apache.org/r1697926 ) - I'll remove that once 
this issue is fixed here

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Julian Reschke (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14713635#comment-14713635
 ] 

Julian Reschke commented on OAK-3288:
-

[~egli]?

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Stefan Egli (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14713657#comment-14713657
 ] 

Stefan Egli commented on OAK-3288:
--

could do indeed yes - let's see what the outcome of this ticket is

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Julian Reschke (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14713633#comment-14713633
 ] 

Julian Reschke commented on OAK-3288:
-

You could treat them both as java.lang.Number

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Stefan Egli (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14713648#comment-14713648
 ] 

Stefan Egli commented on OAK-3288:
--

are you referring to 
https://github.com/apache/jackrabbit-oak/blob/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/ClusterViewDocument.java#L213
 ? so that part might be wrong you're saying?

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OAK-3288) clarify DocumentStore contract with respect to number formats

2015-08-26 Thread Julian Reschke (JIRA)

[ 
https://issues.apache.org/jira/browse/OAK-3288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14714179#comment-14714179
 ] 

Julian Reschke commented on OAK-3288:
-

[~mreutegg] so if we want to restrict the types to boolean/long/String then yes 
[~egli] will have to change his code; can you confirm?

 clarify DocumentStore contract with respect to number formats
 -

 Key: OAK-3288
 URL: https://issues.apache.org/jira/browse/OAK-3288
 Project: Jackrabbit Oak
  Issue Type: Improvement
  Components: core, mongomk, rdbmk
Affects Versions: 1.2.3, 1.3.4, 1.0.19
Reporter: Julian Reschke
Assignee: Julian Reschke
  Labels: resilience
 Fix For: 1.3.6

 Attachments: OAK-3288.diff


 The DS API allows setting properties as java.lang.Integer, but 
 implementations vary in whether they can roundtrip Integers; some do, some 
 convert to Long.
 The former is observed for MongoMK (which uses BSON internally), the latter 
 is see in RDBMK (which uses JSON).
 We should
 - clarify that integers can be set, but they will come back as longs, and
 - modify existing implementations to always return longs, so bugs surface 
 early



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)