You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by "SeanCherngTW (via GitHub)" <gi...@apache.org> on 2023/02/06 10:45:37 UTC

[GitHub] [datasketches-java] SeanCherngTW opened a new issue, #426: ArrayIndexOutOfBounds & NullPointerException in ReversePurgeItemHashMap

SeanCherngTW opened a new issue, #426:
URL: https://github.com/apache/datasketches-java/issues/426

   Hi all,
   
   I am using `datasketches-java 2.0.0`
   I encounter some ArrayIndexOutOfBounds and NullPointerException when using ReversePurgeItemHashMap
   
   In my use case, my system is calling
   `freq.getLowerBound(term)  // freq is ItemsSketch` 
   with high qps every 5 minutes. 
   
   Then, when reaching line 332
   https://github.com/apache/datasketches-java/blob/7cda6ed20ca63ff1ff7164d9c7af641cace2deed/src/main/java/org/apache/datasketches/frequencies/ReversePurgeItemHashMap.java#L329-L336
   I occasionally (~1 time/day) encounter the following error:
   ```
   java.lang.ArrayIndexOutOfBoundsException: Index 63717 out of bounds for length 32768
   	at org.apache.datasketches.frequencies.ReversePurgeItemHashMap.hashProbe(ReversePurgeItemHashMap.java:332)
   	at org.apache.datasketches.frequencies.ReversePurgeItemHashMap.get(ReversePurgeItemHashMap.java:85)
   	at org.apache.datasketches.frequencies.ItemsSketch.getLowerBound(ItemsSketch.java:346)
   ```
   or
   ```
   java.lang.NullPointerException: Cannot invoke "Object.equals(Object)" because "this.keys[probe]" is null
   	at org.apache.datasketches.frequencies.ReversePurgeItemHashMap.hashProbe(ReversePurgeItemHashMap.java:332)
   	at org.apache.datasketches.frequencies.ReversePurgeItemHashMap.get(ReversePurgeItemHashMap.java:85)
   	at org.apache.datasketches.frequencies.ItemsSketch.getLowerBound(ItemsSketch.java:346)
   ```
   
   This error is unable to be reproduced, so I apologize that I cannot provide more context now.
   Do you have any idea on this error or have you encountered a similar problem before?
   thank you
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[GitHub] [datasketches-java] SeanCherngTW closed issue #426: ArrayIndexOutOfBounds & NullPointerException in ReversePurgeItemHashMap

Posted by "SeanCherngTW (via GitHub)" <gi...@apache.org>.
SeanCherngTW closed issue #426: ArrayIndexOutOfBounds & NullPointerException in ReversePurgeItemHashMap
URL: https://github.com/apache/datasketches-java/issues/426


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[GitHub] [datasketches-java] AlexanderSaydakov commented on issue #426: ArrayIndexOutOfBounds & NullPointerException in ReversePurgeItemHashMap

Posted by "AlexanderSaydakov (via GitHub)" <gi...@apache.org>.
AlexanderSaydakov commented on issue #426:
URL: https://github.com/apache/datasketches-java/issues/426#issuecomment-1419544392

   Is there a chance that you run this in a multithreaded environment? The library is not thread-safe.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org


[GitHub] [datasketches-java] SeanCherngTW commented on issue #426: ArrayIndexOutOfBounds & NullPointerException in ReversePurgeItemHashMap

Posted by "SeanCherngTW (via GitHub)" <gi...@apache.org>.
SeanCherngTW commented on issue #426:
URL: https://github.com/apache/datasketches-java/issues/426#issuecomment-1420552837

   hi Alexander, 
   thank you for the hint! Yes it's possible to run in multithreaded in our system
   I think we found the root cause and I will close the issue once we verify our guess


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org