Larry,

Thanks for the response, I'm still a little confused ...
 
>> "I do a JCas.reset at the end of the webservice method"
Just to be clear, you are talking about this on the client-side code, right? 
And the PEAR is the server-side?
I do this too: first the server  does a cas.reset(), then the server sets data 
into the cas by cas.setDocumentText(), then the server requests the AE 
(actually an AAE) that it unpacked from the PEAR to process the data in the cas 
by ae.process(cas).

>> "So before I do that I copy the annotations into some serializable POJOs of 
>> my own"
Again, you are talking client-side code?
If so, how do you get a sofa-view of the CAS that is not the default 
"_InitialView"?
This is where I am having trouble.

Except that you say, 
>>"Those are what I return to the client" 
So it sounds like the serializable POJO creation might be server-side code that 
resides inside the UIMA-PEAR?
Is this a CASConsumer or something that creates these POJOs?
How do you connect the POJOs back to the client side?

Cheers,
Helen




-----Original Message-----
From: Kline, Larry D [mailto:[email protected]] 
Sent: Tuesday, February 26, 2013 2:50 PM
To: [email protected]
Subject: RE: problem retrieving the annotations of a specific sofa view over a 
REST service

I have a similar pipeline and deployment (as a pear in a web service).
I do a JCas.reset at the end of the web service method.  This of course clears 
all the annotations out of the CAS.  So before I do that I copy the annotations 
into some serializable POJOs of my own.  Those are what I return to the client. 
 I'm not using a RESTful interface so I generate client side code from the web 
service's WSDL.

I'm not sure that UIMA annotations can be serialized over a web service call.  
Or if you would even want to.  They have a very complicated internal structure.

Larry Kline

-----Original Message-----
From: Helen Johnson -X (heljohns - Infobahn Softworld Inc at Cisco) 
[mailto:[email protected]]
Sent: Tuesday, February 26, 2013 12:52 PM
To: [email protected]
Subject: problem retrieving the annotations of a specific sofa view over a REST 
service

I have a UIMA pipeline that consists of an AAE that uses multiple sofa views.
The first component of the AAE takes the _InitialView cas.documentText, which 
is XML, converts it to plain text, and inputs this new text and some 
annotations into a new view called plainText (thank you to those last week that 
helped me figure out this labyrinth).
The subsequent AEs in the AAE create many annotations.
A final AnnotationPrinter AE at the end of the pipeline shows that the 
plainText view of the CAS contains the annotations I expect.

Next, this AAE is wrapped into a PEAR and deployed onto a tomcat server as a 
REST service (using the sandbox SimpleServer).
The response to a call to the AAE server is supposed to be the annotations. 
However, the result is blank - there are no annotations being sent back from 
the AAE.


-          Could this have to do with the annotations being associated
with the plainText view instead of the _InitialView?

-          If so, how do  I force the AAE to return the annotations
associated with the plainText view?

-          Or, how do I set the plainText view annotations to be
available in the "default" view?

Thank you,
Helen Johnson
</pre>The contents of this electronic mail message and any attachments are 
confidential, possibly privileged and intended for the addressee(s) 
only.<br>Only the addressee(s) may read, disseminate, retain or otherwise use 
this message. If received in error, please immediately inform the sender and 
then delete this message without disclosing its contents to anyone.</pre>

  • problem retr... Helen Johnson -X (heljohns - Infobahn Softworld Inc at Cisco)
    • RE: pro... Kline, Larry D
      • RE:... Helen Johnson -X (heljohns - Infobahn Softworld Inc at Cisco)
        • ... Kline, Larry D
    • Re: pro... Eddie Epstein

Reply via email to