[
https://issues.apache.org/jira/browse/UIMA-5842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16554776#comment-16554776
]
Marshall Schor commented on UIMA-5842:
--------------------------------------
Thoughts on the control states.
A Cas in "read-only" mode disables updates (writes) of various kinds.
A Cas in "allow-only-one-thread-to-have-r/w-access" disables reads and writes
unless the thread matches a specified one. This allows, for instance, a thread
doing uima-as cas updates upon receiving a returning CAS to update the cas,
while simultaneously blocking all access (read or write) to the cas from other
threads. (this might be required, because otherwise a concurrent thread
reading the CAS could see it in an inconsistent state.)
These would, in turn, be used to:
Allow CAS reading only if
* the disallow access except for 1 thread is not active,
* or it is active, but the thread is right.
Allow CAS updating only if
* the disallow access... is not active & the read-only flag is not active
* or the disallow access.. is active, but the thread is right (read-only flag
is ignored!)
This design says the disallow-access... overrides the readonly (e.g., if the
disallow-access is set for some thread, and that thread is active, then the
readonly flag is ignored.
Does this seem like the right approach for our use cases?
> No-access, Read-only-access modes for a CAS
> -------------------------------------------
>
> Key: UIMA-5842
> URL: https://issues.apache.org/jira/browse/UIMA-5842
> Project: UIMA
> Issue Type: Wish
> Components: Core Java Framework
> Reporter: Marshall Schor
> Priority: Minor
>
> This Jira refs UIMA-5763 having motivation and discussion for no-access and
> read-only-access flags for a CAS. UIMA-5763 is rescoped to its original
> title, specific to releasing CASes.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)