SlackJack created FTPSERVER-444:
-----------------------------------

             Summary: DefaultFtpServer.stop() removes default listener from 
FtpServerFactory
                 Key: FTPSERVER-444
                 URL: https://issues.apache.org/jira/browse/FTPSERVER-444
             Project: FtpServer
          Issue Type: Bug
          Components: Server
    Affects Versions: 1.0.6
         Environment: Java 1.7, Windows 64
            Reporter: SlackJack


When using the default classes in an embedded environment, the following 
situation arises:

-Configure FtpServerFactory with addListener("default", someListener)
-Create server via FtpServerFactory.createServer()
-Start / stop the created FTPServer instance
-Create a new server instance with FtpServerFactory.createServer()
-new server does not have a listener. in fact, the FtpServerFactory listener 
map gets cleared the moment the first FtpServer.stop() is called.

In my opinion, this problem occurs because the FtpServerFactory is assigned to 
the same DefaultFtpServerContext as the server instances, which clear the 
listener maps on FtpServer.stop(). This should not happen, since the 
FtpServerFactory and its Context must be out-of-scope for the FtpServer 
instances.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to