Quickly looking I think we can switch to 
org.agrona.collections.Long2LongHashMap, the key isn’t the “correct” type (long 
when we want int) but isn’t too hard to switch.  Few differences in the 
semantics need to be handled, but not much

1) get of non-defeiled key should throw NoSuchElementException
2) get with long[] updates the array and returns boolean; easy enough to port 
(copy signature/semantics or just change the single caller)
3) org.hsqldb.store.BaseHashMap#addOrRemove(long, long, java.lang.Object, 
java.lang.Object, boolean) for us is just a put

> On Mar 14, 2023, at 5:32 AM, Derek Chen-Becker <de...@chen-becker.org> wrote:
> 
> Do we have the hsqldb library just for a primitive oriented equivalent of 
> Map<int, long>? If this is test code only that seems like a pretty easy thing 
> to replace and I would vote to implement that so we can fully drop the 
> dependency. 
> 
> Cheers,
> 
> Derek
> 
> On Tue, Mar 14, 2023 at 5:49 AM Miklosovic, Stefan 
> <stefan.mikloso...@netapp.com <mailto:stefan.mikloso...@netapp.com>> wrote:
>> Hi list,
>> 
>> while removing Hadoop code in trunk, as agreed on ML recently, I did that 
>> but we need to do this (1). By removing all Hadoop dependencies, we also 
>> removed hsqldb library we surprisingly rely on so I am putting it back.
>> 
>> Honestly, I do not know if people are even aware of the fact we are 
>> depending on hsqldb in simulator package. Can not we rewrite that so we can 
>> drop this dependency entirely?
>> 
>> Do we want to spend time on rewriting this and then we remove Hadoop 
>> libraries or I just add this library among the test ones?
>> 
>> Thanks
>> 
>> (1) https://github.com/apache/cassandra/pull/2212/files#r1133841928
> 
> 
> -- 
> +---------------------------------------------------------------+
> | Derek Chen-Becker                                             |
> | GPG Key available at https://keybase.io/dchenbecker and       |
> | https://pgp.mit.edu/pks/lookup?search=derek%40chen-becker.org |
> | Fngrprnt: EB8A 6480 F0A3 C8EB C1E7  7F42 AFC5 AFEE 96E4 6ACC  |
> +---------------------------------------------------------------+
> 

Reply via email to