Re: java.util.ConcurrentModificationException at java.util.HashMap while doing Upserts

2016-10-02 Thread anil gupta
Thanks for quick response. James. I'll try out some stuff. On Sun, Oct 2, 2016 at 5:00 PM, James Taylor wrote: > Option #2 is fine. Connections are cheap in Phoenix. > > > On Sunday, October 2, 2016, anil gupta wrote: > >> Hi James, >> >> There is

Re: java.util.ConcurrentModificationException at java.util.HashMap while doing Upserts

2016-10-02 Thread James Taylor
Option #2 is fine. Connections are cheap in Phoenix. On Sunday, October 2, 2016, anil gupta wrote: > Hi James, > > There is a high possibility that we might be sharing connection among > multiple threads. This MR job is fairly complicated because we spin up a > separate

Re: java.util.ConcurrentModificationException at java.util.HashMap while doing Upserts

2016-10-02 Thread anil gupta
Hi James, There is a high possibility that we might be sharing connection among multiple threads. This MR job is fairly complicated because we spin up a separate thread(to kill the download if it doesnt completes in a prespecified time.) within Mapper to perform image downloads from internet. #1.

Re: java.util.ConcurrentModificationException at java.util.HashMap while doing Upserts

2016-10-02 Thread James Taylor
Hi Anil, Make sure you're not sharing the same Connection between multiple threads as it's not thread safe. Thanks, James On Sunday, October 2, 2016, anil gupta wrote: > Hi, > > We are running HDP2.3.4(HBase 1.1 and Phoenix 4.4). I have a MapReduce job > thats writing

java.util.ConcurrentModificationException at java.util.HashMap while doing Upserts

2016-10-02 Thread anil gupta
Hi, We are running HDP2.3.4(HBase 1.1 and Phoenix 4.4). I have a MapReduce job thats writing data to a very simple Phoenix table. We intermittently get and due to this our job fails: java.util.ConcurrentModificationException at java.util.HashMap$HashIterator.remove(HashMap.java:944) at