ASF GitHub Bot commented on DRILL-5270:

Github user kkhatua commented on the issue:

    Thanks, @vrozov. I'll make use of a separate lock for read-only purpose in 
case of `#1`.
    For `#2`, I need to construct a size-limited ordered set from a list of 
unordered elements.
    In this case, the elements (i.e. profiles) need to be ordered by file-name, 
which is a 1:1 mapping function of the start time epoch for the query.
    So, I need to be able to add to such a datastructure in `O(log(n))` time, 
remove in `O(1)` and iterate through it in sequence. So, my puts are the most 
expensive operation. 

> Improve loading of profiles listing in the WebUI
> ------------------------------------------------
>                 Key: DRILL-5270
>                 URL: https://issues.apache.org/jira/browse/DRILL-5270
>             Project: Apache Drill
>          Issue Type: Improvement
>          Components: Web Server
>    Affects Versions: 1.9.0
>            Reporter: Kunal Khatua
>            Assignee: Kunal Khatua
>            Priority: Major
>             Fix For: 1.14.0
> Currently, as the number of profiles increase, we reload the same list of 
> profiles from the FS.
> An ideal improvement would be to detect if there are any new profiles and 
> only reload from the disk then. Otherwise, a cached list is sufficient.
> For a directory of 280K profiles, the load time is close to 6 seconds on a 32 
> core server. With the caching, we can get it down to as much as a few 
> milliseconds.
> To render the cache as invalid, we inspect the last modified time of the 
> directory to confirm whether a reload is needed. 

This message was sent by Atlassian JIRA

Reply via email to