You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@uima.apache.org by "Marshall Schor (JIRA)" <de...@uima.apache.org> on 2018/07/24 13:31:00 UTC

[jira] [Commented] (UIMA-5842) No-access, Read-only-access modes for a CAS

    [ https://issues.apache.org/jira/browse/UIMA-5842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16554245#comment-16554245 ] 

Marshall Schor commented on UIMA-5842:
--------------------------------------

Some thoughts on how this might be implemented.

There are many ways to modify a CAS:  create or update FeatureStructures (FSs) , add/remove FSs to indexes, create views, reset, replace a type system (done by cas complete deserialization).  Others? 

This mode might be set for any / all of these categories. 

One task is finding (hopefully a few) points in the code base where to insert an "isAllowed" test.  Consideration for that test:
 * (simplest) a CAS boolean field.  (problem: multiple threads won't see consistent view)
 * volatile CAS boolean field (problem: each read forces a read-from-memory - potentially slow)
 * use a MutableCallSite to return the is-allowed value, using the "syncAll" method when changing it to make values visible in other threads.  This seems the best (so far).

> 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)