Awesome Richard,

All our tests pass with this PR. I only migrated a utility class, which is used 
in several places. This is just a trial balloon for comparing performance and 
behaviour with JCasUtil. I tried the uimaFIT benchmark you mentioned, and 
judging from the output of this, it appears there is generally little or no 
performance gain with the new Select API, and like you said some of them seem 
to be slower, e.g. selectCovered and selectOverlapping. However, there might be 
some gains, if intermediate collection aggregations are avoided by utilising 
streams better.

I can see that the selectAt seems to be implemented more efficiently using 
binary search in the new API, so I tried adding a simple benchmark for it, 
which appears to confirm this. I also tried changing the timer to use CPU time, 
which should yield more accurate timing.

Cheers
Mario

> On 3 Nov 2020, at 22.40, Richard Eckart de Castilho <[email protected]> wrote:
>
> External email – Do not click links or open attachments unless you recognize 
> the sender and know that the content is safe.
>
>
> On 3. Nov 2020, at 15:01, Mario Juric <[email protected]> wrote:
>>
>> I created the Jira issue with a small Maven project that reproduces the 
>> issue. However, it seems to be related to the use of uimaFIT, since removing 
>> the uimaFIT references and running the test in uimaj-core didn’t reproduce 
>> the problem.
>
> With a bit of refactoring of your test, I could reproduce the issue without 
> any uimaFIT whatsoever.
>
> There is a PR for this now with a bunch of fixes: 
> https://github.com/apache/uima-uimaj/pull/81
>
> -- Richard


________________________________
Disclaimer:
This email and any files transmitted with it are confidential and directed 
solely for the use of the intended addressee or addressees and may contain 
information that is legally privileged, confidential, and exempt from 
disclosure. If you have received this email in error, please notify the sender 
by telephone, fax, or return email and immediately delete this email and any 
files transmitted along with it. Unintended recipients are not authorized to 
disclose, disseminate, distribute, copy or take any action in reliance on 
information contained in this email and/or any files attached thereto, in any 
manner other than to notify the sender; any unauthorized use is subject to 
legal prosecution.

Reply via email to