uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Richard Eckart <eck...@linglit.tu-darmstadt.de>
Subject Re: Session variable potpurri in CPE
Date Thu, 05 Jun 2008 00:42:17 GMT
Hi again,

> It sounds like the values of these variables pertain to a particular
> CAS (since you don't want the values to change until that CAS has been
> fully processed).  If so, then storing them them in the CAS was a fine
> solution.  The CollectionReader and CAS Consumers run in separate
> threads, so the CollectionReader definitely may move on to a new CAS
> before the CAS Consumer processes the first one.

The problem is that I need to share data that is not a primitive type
which I could represent in the CAS (it's a rather complex Java object).

> If you wanted your Collection Reader and CAS Consumer so share data
> that was *not* related to a particular CAS, you could use UIMA's
> external resource mechanism to accomplish that.

I was originally searching for that (because it was mentioned at the
UIMA workshop at the LREC) but I only found out how to use the session
variables. Do you have a pointer to finding out how to use that  

What I want is that wherever I put the Java object, it should be  
removed when a CAS is fully processed - no matter if it was  
successful or not.
The object is bound to a document but representable in the CAS.  
Before I had an
ID encoded in the CAS and passed the object out-of-band via a static  
(CollectionReader puts object there under the ID and CASConsumer  
reads it again).
However I was not too happy with this solution. Would this scenario  
be solvable
with the external resources approach?

Richard Eckart

Technische Universit├Ąt Darmstadt
Institute of Linguistics and Literary Studies
Department of English Linguistics

Hochschulstrasse 1
64289 Darmstadt

View raw message