[ https://issues.apache.org/jira/browse/SIS-573?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Desruisseaux updated SIS-573: ------------------------------------ Issue Type: Improvement (was: Task) > Allow data stores to be closed asynchronously > --------------------------------------------- > > Key: SIS-573 > URL: https://issues.apache.org/jira/browse/SIS-573 > Project: Spatial Information Systems > Issue Type: Improvement > Components: Storage > Affects Versions: 1.3 > Reporter: Martin Desruisseaux > Assignee: Martin Desruisseaux > Priority: Major > Fix For: 1.4 > > > A {{DataStore}} can be connected to a big file through internet, for example > if the file is a Cloud Optimized GeoTIFF (COG). This is reasonably efficient > if the server support HTTP ranges. But if the {{GeoTiffStore}} (for example) > is connected to a big TIFF on a server that do not support HTTP range, it may > download a large amount of data. We need a way to interrupt that. > Implementing an {{abort()}} method would be a significant amount of work. But > as a mid-term solution, we need to at least get {{DataStore.close()}} to work > asynchronously. In current {{DataStore}} implementations, {{close()}} is a > synchronized method which blocks until the reading process is completed. We > should invoke {{Channel.close()}} before to enter in the synchronized block. > It will allow {{java.nio.channels.AsynchronousCloseException}} to be thrown > and interrupt the reading process. -- This message was sent by Atlassian Jira (v8.20.10#820010)