uima-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jerry Cwiklik (JIRA)" <...@uima.apache.org>
Subject [jira] [Created] (UIMA-5119) UIMA-AS: CPP wrapper fails with Exception on service shutdown
Date Fri, 23 Sep 2016 15:25:20 GMT
Jerry Cwiklik created UIMA-5119:
-----------------------------------

             Summary: UIMA-AS: CPP wrapper fails with Exception on service shutdown
                 Key: UIMA-5119
                 URL: https://issues.apache.org/jira/browse/UIMA-5119
             Project: UIMA
          Issue Type: Bug
          Components: Async Scaleout
            Reporter: Jerry Cwiklik
            Assignee: Jerry Cwiklik
             Fix For: 2.9.0AS


The UimacppServiceManagement code fails when remote C++ service terminates with the following
stack trace:

> UimacppServiceManagement service reports shutdown DONE
> UimacppShutdownHook sending quiesce message
> java.net.SocketException: Socket is closed
>         at java.net.Socket.getInputStream(Socket.java:903)
>         at
> org.apache.uima.aae.controller.UimacppServiceManagement.
> quiesceAndStop(Uima
> cppServiceManagement.java:88)
>         at
> org.apache.uima.aae.controller.UimacppServiceManagement.
> quiesceAndShutdown(
> UimacppServiceManagement.java:397)
>         at
> org.apache.uima.aae.controller.UimacppShutdownHook.run(
> UimacppServiceController.java:1105)

The UimacppServiceManagement is a communication wrapper which is used by UimacppServiceController
to interact with a remote C++ process. It sends text commands to the remote using a Socket.


In quiesceAndStop() the code sends "QUIESCEANDSTOP" command and a remote process exits immediately.
After sending the command, the UimacppServiceManagement tries to read from a socket that was
closed causing the exception.

Modify code to catch SocketException and log a short message instead of dumping stack trace
and returning an exception. Process terminating quickly should not be considered an error.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message