mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (DIRMINA-1037) Throw exception in NioProcessor.write if the session is closing
Date Tue, 16 Aug 2016 09:33:20 GMT

     [ https://issues.apache.org/jira/browse/DIRMINA-1037?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Emmanuel Lecharny resolved DIRMINA-1037.
----------------------------------------
       Resolution: Fixed
    Fix Version/s: 2.0.15

Thanks for the patch. We fixed the issue differently, by closing the channel immediately when
we get an exception. See DIRMINA-1021

> Throw exception in NioProcessor.write if the session is closing
> ---------------------------------------------------------------
>
>                 Key: DIRMINA-1037
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-1037
>             Project: MINA
>          Issue Type: Bug
>          Components: Core, Protocol - HTTP, Transport
>    Affects Versions: 2.0.13
>         Environment: Windows Server 2012 R2
> mina-core 2.0.13
>            Reporter: Dave Heath
>             Fix For: 2.0.15
>
>         Attachments: throw_exception_when_closing.patch
>
>
> There seems to be a race condition where NioProcessor.write() can be called after the
session has been marked as closing. This causes the session to remain open indefinitely, because
it is waiting to finish writing before it closes. Over time, this causes memory issues as
the number of sessions stuck open grows indefinitely (particularly because these sessions
are using SSL).
> I'm attaching a patch that fixes the problem. It simply throws an exception if the session
is already marked as closing when write() is called.
> This only seems to be an issue on Windows; I can't reproduce it on Unix systems. It also
involves a problematic client that sends a RST packet as soon as it's done sending data to
our HTTPS server; this sometimes causes the session to start closing before all of the data
has been received.



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

Mime
View raw message