You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by "Trustin Lee (JIRA)" <ji...@apache.org> on 2007/01/29 03:50:49 UTC

[jira] Resolved: (DIRMINA-324) ProtocolCodecFilter can not be dynamicly be replaced by another.

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

Trustin Lee resolved DIRMINA-324.
---------------------------------

    Resolution: Fixed
      Assignee: Trustin Lee

Thanks for the patch.  It's applied to all branches.

> ProtocolCodecFilter can not be dynamicly be replaced by another.
> ----------------------------------------------------------------
>
>                 Key: DIRMINA-324
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-324
>             Project: MINA
>          Issue Type: Bug
>          Components: Filter
>    Affects Versions: 1.0.0, 1.0.1
>            Reporter: Wolter Eldering
>         Assigned To: Trustin Lee
>            Priority: Minor
>             Fix For: 1.0.2
>
>
> ProtocolCodecFilter can not be dynamicly added and removed because the encoder en decoder attributes are not removed from the IoSession when the ProtocolCodecFilter is removed.
> Index: core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java
> ===================================================================
> --- core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java    (revision 487691)
> +++ core/src/main/java/org/apache/mina/filter/codec/ProtocolCodecFilter.java    (working copy)
> @@ -141,6 +141,12 @@
>          }
>      }
>  
> +    public void onPostRemove(IoFilterChain parent, String name, NextFilter nextFilter) throws Exception {
> +      disposeEncoder(parent.getSession());
> +      disposeDecoder(parent.getSession());
> +    }
> +
> +
>      public void messageReceived( NextFilter nextFilter, IoSession session, Object message ) throws Exception
>      {
>          if( !( message instanceof ByteBuffer ) )

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.