[ 
https://issues.apache.org/jira/browse/BEAM-1006?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

David Billings updated BEAM-1006:
---------------------------------
    Comment: was deleted

(was: I've fixed in PR https://github.com/apache/incubator-beam/pull/1387

Works locally against my mongodb)

> splitKeysToFilter method is creating a bad query string.
> --------------------------------------------------------
>
>                 Key: BEAM-1006
>                 URL: https://issues.apache.org/jira/browse/BEAM-1006
>             Project: Beam
>          Issue Type: Bug
>          Components: sdk-java-extensions
>    Affects Versions: 0.3.0-incubating
>            Reporter: David Billings
>            Assignee: James Malone
>            Priority: Critical
>              Labels: mongodb
>             Fix For: 0.4.0-incubating
>
>
> When you have a large number of documents in your mongo collection the 
> splitKeysToFilter method is invoked. 
> Currently Document{{_id= is prefixed to the query string
> {code}{ $and: [ 
> {"_id":{$lte:Objectd("Document{{_id=564a0ad6e21b840001d75f5d}}")}} ]}{code}
> This causes the document parse to fail with the following exception: 
> Exception in thread "main" java.lang.IllegalArgumentException: invalid 
> hexadecimal representation of an ObjectId: 
> [Document{{_id=56e1ec546b2f0700015e61b2}}]
> This is caused by line 305 
> {code}
> String splitKey = splitKeys.get(i).toString();
> {code}
> The code should use 
> {code}
> String splitKey = splitKeys.get(i).toString();
> {code}
> to just return the ID. 



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

Reply via email to