directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject [directory-ldap-api] 01/05: Rmoved Decorators from teh LDAP API
Date Tue, 01 Jan 2019 11:17:25 GMT
This is an automated email from the ASF dual-hosted git repository.

elecharny pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/directory-ldap-api.git

commit b23123d84764f1289016df7c7184d208f5fff75c
Author: Emmanuel Lecharny <elecharny@apache.org>
AuthorDate: Thu Dec 27 17:25:30 2018 +0100

    Rmoved Decorators from teh LDAP API
---
 .../api/dsmlv2/AbstractDsmlMessageDecorator.java   |   11 +-
 .../apache/directory/api/dsmlv2/ParserUtils.java   |   19 +-
 .../api/dsmlv2/request/Dsmlv2Grammar.java          |   24 +-
 .../api/dsmlv2/response/Dsmlv2ResponseGrammar.java |   17 +-
 .../java/org/apache/directory/api/i18n/I18n.java   |    5 +
 .../apache/directory/api/i18n/errors.properties    |    3 +
 .../apache/directory/api/i18n/messages.properties  |    1 +
 .../api/osgi/ApiLdapCodecCoreOsgiTest.java         |    4 +-
 .../api/osgi/ApiLdapExtrasCodecOsgiTest.java       |   20 +-
 .../codec/api/StandaloneLdapCodecServiceTest.java  |   21 +-
 ldap/client/api/pom.xml                            |    1 -
 .../ldap/client/api/LdapNetworkConnection.java     |   45 +-
 .../template/AbstractPasswordPolicyResponder.java  |    9 +-
 .../client/template/LdapConnectionTemplate.java    |    8 +-
 ldap/codec/core/pom.xml                            |    1 -
 .../api/ldap/codec/LdapMessageGrammar.java         |   64 +-
 .../api/ldap/codec/actions/AllowGrammarEnd.java    |    7 +-
 .../api/ldap/codec/actions/CheckLengthNotNull.java |    7 +-
 .../ldap/codec/actions/controls/InitControls.java  |    9 +-
 .../actions/controls/StoreControlCriticality.java  |    7 +-
 .../{AddControl.java => StoreControlName.java}     |   43 +-
 .../codec/actions/controls/StoreControlValue.java  |   23 +-
 .../codec/actions/ldapMessage/InitLdapMessage.java |    7 +-
 .../codec/actions/ldapMessage/StoreMessageId.java  |    7 +-
 .../ldap/codec/actions/ldapResult/AddReferral.java |    7 +-
 .../codec/actions/ldapResult/InitReferrals.java    |    7 +-
 .../actions/ldapResult/StoreErrorMessage.java      |    7 +-
 .../codec/actions/ldapResult/StoreMatchedDN.java   |    7 +-
 .../codec/actions/ldapResult/StoreResultCode.java  |    7 +-
 .../request/abandon/InitAbandonRequest.java        |   13 +-
 .../request/add/AddAddRequestAttributeType.java    |   22 +-
 .../actions/request/add/AddAttributeValue.java     |   19 +-
 .../codec/actions/request/add/InitAddRequest.java  |   13 +-
 .../request/add/StoreAddRequestEntryName.java      |   15 +-
 .../actions/request/bind/InitBindRequest.java      |   13 +-
 .../codec/actions/request/bind/InitSaslBind.java   |    7 +-
 .../ldap/codec/actions/request/bind/StoreName.java |    7 +-
 .../actions/request/bind/StoreSaslCredentials.java |    7 +-
 .../actions/request/bind/StoreSaslMechanism.java   |    7 +-
 .../actions/request/bind/StoreSimpleAuth.java      |    7 +-
 .../codec/actions/request/bind/StoreVersion.java   |    7 +-
 .../request/compare/InitCompareRequest.java        |   14 +-
 .../compare/StoreCompareRequestAssertionValue.java |    7 +-
 .../compare/StoreCompareRequestAttributeDesc.java  |    7 +-
 .../compare/StoreCompareRequestEntryName.java      |   18 +-
 .../codec/actions/request/del/InitDelRequest.java  |   35 +-
 .../request/extended/InitExtendedRequest.java      |    8 +-
 .../request/extended/StoreExtendedRequestName.java |   57 +-
 .../extended/StoreExtendedRequestValue.java        |   46 +-
 .../request/modify/AddModifyRequestAttribute.java  |   16 +-
 .../actions/request/modify/InitAttributeVals.java  |    8 +-
 .../actions/request/modify/InitModifyRequest.java  |   27 +-
 .../modify/StoreModifyRequestAttributeValue.java   |   20 +-
 .../modify/StoreModifyRequestObjectName.java       |   12 +-
 .../actions/request/modify/StoreOperationType.java |   21 +-
 .../request/modifydn/InitModifyDnRequest.java      |   13 +-
 .../modifydn/StoreModifyDnRequestDeleteOldRdn.java |    7 +-
 .../modifydn/StoreModifyDnRequestEntryName.java    |   19 +-
 .../modifydn/StoreModifyDnRequestNewRdn.java       |   16 +-
 .../modifydn/StoreModifyDnRequestNewSuperior.java  |   18 +-
 .../actions/request/search/InitSearchRequest.java  |   16 +-
 .../search/InitSearchRequestAttributeDescList.java |  177 ++-
 .../search/StoreSearchRequestAttributeDesc.java    |   12 +-
 .../search/StoreSearchRequestBaseObject.java       |   21 +-
 .../search/StoreSearchRequestDerefAlias.java       |   24 +-
 .../request/search/StoreSearchRequestScope.java    |   22 +-
 .../search/StoreSearchRequestSizeLimit.java        |   17 +-
 .../search/StoreSearchRequestTimeLimit.java        |   18 +-
 .../search/StoreSearchRequestTypesOnly.java        |    9 +-
 .../request/search/filter/InitAndFilter.java       |   14 +-
 .../search/filter/InitApproxMatchFilter.java       |   16 +-
 .../search/filter/InitAssertionValueFilter.java    |   14 +-
 .../search/filter/InitAttributeDescFilter.java     |   12 +-
 .../search/filter/InitEqualityMatchFilter.java     |   16 +-
 .../search/filter/InitExtensibleMatchFilter.java   |   16 +-
 .../search/filter/InitGreaterOrEqualFilter.java    |   16 +-
 .../search/filter/InitLessOrEqualFilter.java       |   16 +-
 .../request/search/filter/InitNotFilter.java       |   14 +-
 .../request/search/filter/InitOrFilter.java        |   14 +-
 .../request/search/filter/InitPresentFilter.java   |   16 +-
 .../search/filter/InitSubstringsFilter.java        |   16 +-
 .../actions/request/search/filter/StoreAny.java    |   14 +-
 .../actions/request/search/filter/StoreFinal.java  |   14 +-
 .../request/search/filter/StoreInitial.java        |   14 +-
 .../request/search/filter/StoreMatchValue.java     |   14 +-
 .../filter/StoreMatchingRuleDnAttributes.java      |   14 +-
 .../StoreMatchingRuleId.java}                      |   39 +-
 .../StoreMatchingRuleType.java}                    |   18 +-
 .../search/filter/StoreSubstringFilterType.java    |   14 +-
 .../actions/request/unbind/InitUnbindRequest.java  |   13 +-
 .../actions/response/add/InitAddResponse.java      |   11 +-
 .../actions/response/bind/InitBindResponse.java    |   11 +-
 .../response/bind/StoreServerSASLCreds.java        |    7 +-
 .../response/compare/InitCompareResponse.java      |   11 +-
 .../actions/response/del/InitDelResponse.java      |   11 +-
 .../response/extended/InitExtendedResponse.java    |   16 +-
 .../extended/StoreExtendedResponseName.java        |   82 +-
 .../extended/StoreExtendedResponseValue.java       |   47 +-
 .../intermediate/InitIntermediateResponse.java     |   13 +-
 .../StoreIntermediateResponseName.java             |   27 +-
 .../StoreIntermediateResponseValue.java            |   27 +-
 .../response/modify/InitModifyResponse.java        |   11 +-
 .../response/modifydn/InitModifyDnResponse.java    |   11 +-
 .../response/search/done/InitSearchResultDone.java |   11 +-
 .../response/search/entry/AddAttributeType.java    |   16 +-
 .../search/entry/InitSearchResultEntry.java        |   11 +-
 .../entry/StoreSearchResultAttributeValue.java     |   24 +-
 .../entry/StoreSearchResultEntryObjectName.java    |   19 +-
 .../reference/InitSearchResultReference.java       |   11 +-
 .../response/search/reference/StoreReference.java  |    7 +-
 .../api/ldap/codec/api/AbstractControlFactory.java |   41 +-
 .../api/AbstractExtendedOperationFactory.java      |   58 +-
 .../api/AbstractIntermediateOperationFactory.java  |   55 -
 .../ldap/codec/api/AbstractMessageDecorator.java   |  455 --------
 .../api/ldap/codec/api/ControlContainer.java}      |   28 +-
 .../api/ldap/codec/api/ControlFactory.java         |   37 +-
 .../ldap/codec/api/ExtendedOperationFactory.java   |   49 +-
 .../codec/api/IntermediateOperationFactory.java    |   29 +-
 .../api/ldap/codec/api/LdapApiService.java         |  118 --
 .../directory/api/ldap/codec/api/LdapDecoder.java  |    2 +-
 .../directory/api/ldap/codec/api/LdapEncoder.java  |  171 ---
 .../api/ldap/codec/api/LdapMessageContainer.java   |    2 +-
 .../ldap/codec/api/LdapMessageContainerDirect.java |  544 +++++++++
 .../ldap/codec/controls/OpaqueControlFactory.java} |   50 +-
 .../codec/controls/cascade/CascadeDecorator.java   |   80 --
 .../codec/controls/cascade/CascadeFactory.java     |   27 +-
 .../controls/manageDsaIT/ManageDsaITDecorator.java |   81 --
 .../controls/manageDsaIT/ManageDsaITFactory.java   |   27 +-
 .../proxiedauthz/ProxiedAuthzDecorator.java        |  197 ----
 .../controls/proxiedauthz/ProxiedAuthzFactory.java |   42 +-
 .../search/entryChange/EntryChangeContainer.java   |   66 +-
 .../search/entryChange/EntryChangeDecorator.java   |  288 -----
 .../search/entryChange/EntryChangeFactory.java     |   39 +-
 .../search/entryChange/EntryChangeGrammar.java     |    8 +-
 .../search/pagedSearch/PagedResultsContainer.java  |   72 +-
 .../search/pagedSearch/PagedResultsDecorator.java  |  327 ------
 .../search/pagedSearch/PagedResultsFactory.java    |   39 +-
 .../search/pagedSearch/PagedResultsGrammar.java    |    6 +-
 .../PersistentSearchContainer.java                 |   66 +-
 .../PersistentSearchDecorator.java                 |  275 -----
 .../persistentSearch/PersistentSearchFactory.java  |   39 +-
 .../persistentSearch/PersistentSearchGrammar.java  |    6 +-
 .../search/subentries/SubentriesContainer.java     |   46 +-
 .../search/subentries/SubentriesDecorator.java     |  170 ---
 .../search/subentries/SubentriesFactory.java       |   30 +-
 .../codec/controls/sort/SortRequestContainer.java  |   56 +-
 .../codec/controls/sort/SortRequestDecorator.java  |  240 ----
 .../codec/controls/sort/SortRequestFactory.java    |   42 +-
 .../codec/controls/sort/SortResponseContainer.java |   55 +-
 .../codec/controls/sort/SortResponseDecorator.java |  208 ----
 .../codec/controls/sort/SortResponseFactory.java   |   39 +-
 .../codec/decorators/AbandonRequestDecorator.java  |  169 ---
 .../AbandonableResultResponseRequest.java          |   33 -
 .../codec/decorators/AbstractRequestDecorator.java |   57 -
 .../decorators/AbstractResponseDecorator.java      |   73 --
 .../AbstractResultResponseRequestDecorator.java    |   68 --
 .../AbstractSingleReplyRequestDecorator.java       |   92 --
 .../ldap/codec/decorators/AddRequestDecorator.java |  456 --------
 .../codec/decorators/AddResponseDecorator.java     |  120 --
 .../codec/decorators/BindRequestDecorator.java     |  477 --------
 .../codec/decorators/BindResponseDecorator.java    |  166 ---
 .../codec/decorators/CompareRequestDecorator.java  |  286 -----
 .../codec/decorators/CompareResponseDecorator.java |  124 --
 .../codec/decorators/DeleteRequestDecorator.java   |  183 ---
 .../codec/decorators/DeleteResponseDecorator.java  |  109 --
 .../codec/decorators/ExtendedRequestDecorator.java |  252 -----
 .../decorators/ExtendedResponseDecorator.java      |  222 ----
 .../decorators/IntermediateResponseDecorator.java  |  203 ----
 .../ldap/codec/decorators/LdapResultDecorator.java |  328 ------
 .../codec/decorators/ModifyDnRequestDecorator.java |  315 ------
 .../decorators/ModifyDnResponseDecorator.java      |  107 --
 .../codec/decorators/ModifyRequestDecorator.java   |  620 ----------
 .../codec/decorators/ModifyResponseDecorator.java  |  108 --
 .../codec/decorators/SearchRequestDecorator.java   | 1192 --------------------
 .../decorators/SearchResultDoneDecorator.java      |  110 --
 .../decorators/SearchResultEntryDecorator.java     |  399 -------
 .../decorators/SearchResultReferenceDecorator.java |  175 ---
 .../codec/decorators/UnbindRequestDecorator.java   |  137 ---
 .../codec/factory/ExtendedResponseFactory.java     |   11 +
 .../codec/factory/IntermediateResponseFactory.java |    6 +
 .../ldap/codec/osgi/DefaultLdapCodecService.java   |  336 +-----
 .../directory/api/ldap/codec/LdapControlTest.java  |   86 +-
 .../directory/api/ldap/codec/LdapDecoderTest.java  |  150 ++-
 .../directory/api/ldap/codec/LdapMessageTest.java  |   31 +-
 .../directory/api/ldap/codec/LdapResultTest.java   |   37 +-
 .../api/ldap/codec/abandon/AbandonRequestTest.java |   35 +-
 .../api/ldap/codec/add/AddRequestTest.java         |   30 +-
 .../api/ldap/codec/add/AddResponseTest.java        |   36 +-
 .../api/ldap/codec/bind/BindRequestPerfTest.java   |  117 --
 .../api/ldap/codec/bind/BindRequestTest.java       |   58 +-
 .../api/ldap/codec/bind/BindResponseTest.java      |   29 +-
 .../api/ldap/codec/compare/CompareRequestTest.java |   30 +-
 .../ldap/codec/compare/CompareResponseTest.java    |   18 +-
 .../proxiedauthz/ProxiedAuthzControlTest.java      |  133 +--
 .../search/entryChange/EntryChangeControlTest.java |   79 +-
 .../search/pagedSearch/PagedSearchControlTest.java |  101 +-
 .../persistentSearch/PSearchControlTest.java       |   68 +-
 .../search/subentries/SubEntryControlTest.java     |   46 +-
 .../controls/sort/SortRequestControlTest.java      |  168 ++-
 .../controls/sort/SortResponseControlTest.java     |   59 +-
 .../api/ldap/codec/del/DelRequestTest.java         |   20 +-
 .../api/ldap/codec/del/DelResponseTest.java        |   18 +-
 .../ldap/codec/extended/ExtendedResponseTest.java  |  717 ------------
 .../intermediate/IntermediateResponseTest.java     |  731 ++++--------
 .../api/ldap/codec/modify/ModifyRequestTest.java   |  229 +---
 .../api/ldap/codec/modify/ModifyResponseTest.java  |   74 +-
 .../ldap/codec/modifyDn/ModifyDNRequestTest.java   |  121 +-
 .../ldap/codec/modifyDn/ModifyDNResponseTest.java  |   74 +-
 .../SearchRequestMatchingRuleAssertionTest.java    |   89 +-
 .../codec/search/SearchRequestSubstringTest.java   |  343 +-----
 .../api/ldap/codec/search/SearchRequestTest.java   |  879 ++++-----------
 .../ldap/codec/search/SearchResultDoneTest.java    |   99 +-
 .../ldap/codec/search/SearchResultEntryTest.java   |  290 ++---
 .../codec/search/SearchResultReferenceTest.java    |   98 +-
 .../api/ldap/codec/unbind/UnBindRequestTest.java   |   19 +-
 .../ldap/codec/standalone/CodecFactoryUtil.java    |    2 +-
 .../codec/standalone/StandaloneLdapApiService.java |    4 +-
 .../extended/pwdModify/PasswordModifyResponse.java |    8 +
 .../intermediate/syncrepl/SyncInfoValueImpl.java   |    5 +
 ldap/extras/codec/pom.xml                          |    1 -
 .../ad_impl/AdDirSyncRequestContainer.java         |   46 +-
 .../ad_impl/AdDirSyncRequestDecorator.java         |  267 -----
 .../controls/ad_impl/AdDirSyncRequestFactory.java  |   39 +-
 .../controls/ad_impl/AdDirSyncRequestGrammar.java  |    6 +-
 .../ad_impl/AdDirSyncResponseContainer.java        |   48 +-
 .../ad_impl/AdDirSyncResponseDecorator.java        |  288 -----
 .../controls/ad_impl/AdDirSyncResponseFactory.java |   40 +-
 .../controls/ad_impl/AdPolicyHintsContainer.java   |   54 +-
 .../controls/ad_impl/AdPolicyHintsDecorator.java   |  166 ---
 .../controls/ad_impl/AdPolicyHintsFactory.java     |   36 +-
 .../controls/ad_impl/AdShowDeletedDecorator.java   |   80 --
 .../controls/ad_impl/AdShowDeletedFactory.java     |   37 +-
 .../ldap/extras/controls/ad_impl/StoreFlags.java   |    2 +-
 .../ChangeNotificationsDecorator.java              |   81 --
 .../ChangeNotificationsFactory.java                |   27 +-
 .../PermissiveModifyDecorator.java                 |   80 --
 .../PermissiveModifyFactory.java                   |   37 +-
 .../PasswordPolicyRequestDecorator.java            |  118 --
 .../ppolicy_impl/PasswordPolicyRequestFactory.java |   39 +-
 .../PasswordPolicyResponseContainer.java           |   38 +-
 .../PasswordPolicyResponseDecorator.java           |  286 -----
 .../PasswordPolicyResponseFactory.java             |   40 +-
 .../extras/controls/ppolicy_impl/StoreError.java   |    2 +-
 .../ppolicy_impl/StoreGraceAuthNRemaining.java     |    2 +-
 .../ppolicy_impl/StoreTimeBeforeExpiration.java    |    2 +-
 .../syncrepl_impl/SyncDoneValueContainer.java      |   47 +-
 .../syncrepl_impl/SyncDoneValueDecorator.java      |  243 ----
 .../syncrepl_impl/SyncDoneValueFactory.java        |   39 +-
 .../syncrepl_impl/SyncDoneValueGrammar.java        |    4 +-
 .../syncrepl_impl/SyncRequestValueContainer.java   |   30 +-
 .../syncrepl_impl/SyncRequestValueDecorator.java   |  285 -----
 .../syncrepl_impl/SyncRequestValueFactory.java     |   39 +-
 .../syncrepl_impl/SyncRequestValueGrammar.java     |    8 +-
 .../syncrepl_impl/SyncStateValueContainer.java     |   30 +-
 .../syncrepl_impl/SyncStateValueDecorator.java     |  262 -----
 .../syncrepl_impl/SyncStateValueFactory.java       |   39 +-
 .../syncrepl_impl/SyncStateValueGrammar.java       |    6 +-
 .../TransactionSpecificationDecorator.java         |  123 --
 .../TransactionSpecificationFactory.java           |   37 +-
 .../extras/controls/vlv_impl/StoreAfterCount.java  |    2 +-
 .../controls/vlv_impl/StoreAssertionValue.java     |    4 +-
 .../extras/controls/vlv_impl/StoreBeforeCount.java |    2 +-
 .../controls/vlv_impl/StoreContentCount.java       |    2 +-
 .../vlv_impl/StoreContentCountResponse.java        |    2 +-
 .../extras/controls/vlv_impl/StoreContextId.java   |    2 +-
 .../controls/vlv_impl/StoreContextIdResponse.java  |    2 +-
 .../ldap/extras/controls/vlv_impl/StoreOffset.java |    2 +-
 .../controls/vlv_impl/StoreTargetPosition.java     |    2 +-
 .../vlv_impl/StoreVirtualListViewResult.java       |    2 +-
 .../vlv_impl/VirtualListViewRequestContainer.java  |   54 +-
 .../vlv_impl/VirtualListViewRequestDecorator.java  |  351 ------
 .../vlv_impl/VirtualListViewRequestFactory.java    |   39 +-
 .../vlv_impl/VirtualListViewResponseContainer.java |   54 +-
 .../vlv_impl/VirtualListViewResponseDecorator.java |  246 ----
 .../vlv_impl/VirtualListViewResponseFactory.java   |   39 +-
 .../extended/ads_impl/cancel/CancelDecoder.java    |   61 -
 .../extended/ads_impl/cancel/CancelFactory.java    |   52 +-
 ...lContainer.java => CancelRequestContainer.java} |   20 +-
 .../ads_impl/cancel/CancelRequestDecorator.java    |  194 ----
 ...ancelGrammar.java => CancelRequestGrammar.java} |   37 +-
 .../certGeneration/CertGenerationDecoder.java      |   61 -
 .../certGeneration/CertGenerationFactory.java      |   54 +-
 ...er.java => CertGenerationRequestContainer.java} |   16 +-
 .../CertGenerationRequestDecorator.java            |  277 -----
 ...mmar.java => CertGenerationRequestGrammar.java} |   75 +-
 ...m.java => CertGenerationRequestStatesEnum.java} |    4 +-
 .../CertGenerationResponseDecorator.java           |   46 -
 .../endTransaction/EndTransactionFactory.java      |   76 +-
 .../EndTransactionRequestContainer.java            |   10 +-
 .../EndTransactionRequestDecoder.java              |   62 -
 .../EndTransactionRequestDecorator.java            |  231 ----
 .../EndTransactionRequestGrammar.java              |   12 +-
 .../EndTransactionResponseContainer.java           |   37 +-
 .../EndTransactionResponseDecoder.java             |   60 -
 .../EndTransactionResponseDecorator.java           |  334 ------
 .../EndTransactionResponseGrammar.java             |   19 +-
 .../endTransaction/controls/ControlsContainer.java |    7 +-
 .../controls/actions/AddControl.java               |    4 +-
 .../controls/actions/StoreControlValue.java        |   35 +-
 .../GracefulDisconnectDecoder.java                 |   63 --
 .../GracefulDisconnectFactory.java                 |   49 +-
 ...va => GracefulDisconnectResponseContainer.java} |   10 +-
 .../GracefulDisconnectResponseDecorator.java       |  314 ------
 ...java => GracefulDisconnectResponseGrammar.java} |   65 +-
 .../gracefulShutdown/GracefulShutdownDecoder.java  |   61 -
 .../gracefulShutdown/GracefulShutdownFactory.java  |   47 +-
 ....java => GracefulShutdownRequestContainer.java} |   14 +-
 .../GracefulShutdownRequestDecorator.java          |  237 ----
 ...ar.java => GracefulShutdownRequestGrammar.java} |   50 +-
 .../GracefulShutdownResponseDecorator.java         |   46 -
 .../ads_impl/pwdModify/PasswordModifyFactory.java  |  140 +--
 .../pwdModify/PasswordModifyRequestContainer.java  |   10 +-
 .../pwdModify/PasswordModifyRequestDecoder.java    |   62 -
 .../pwdModify/PasswordModifyRequestDecorator.java  |  257 -----
 .../pwdModify/PasswordModifyRequestGrammar.java    |   11 +-
 .../pwdModify/PasswordModifyResponseContainer.java |   12 +-
 .../pwdModify/PasswordModifyResponseDecoder.java   |   62 -
 .../pwdModify/PasswordModifyResponseDecorator.java |  189 ----
 .../pwdModify/PasswordModifyResponseGrammar.java   |   13 +-
 .../ads_impl/startTls/StartTlsFactory.java         |   70 +-
 .../startTls/StartTlsRequestDecorator.java         |   59 -
 .../startTls/StartTlsResponseDecorator.java        |   56 -
 .../startTransaction/StartTransactionFactory.java  |   77 +-
 .../StartTransactionRequestDecorator.java          |   62 -
 .../StartTransactionResponseDecorator.java         |   96 --
 .../storedProcedure/StoredProcedureDecoder.java    |   40 -
 .../storedProcedure/StoredProcedureFactory.java    |   56 +-
 ...r.java => StoredProcedureRequestContainer.java} |   46 +-
 .../StoredProcedureRequestDecorator.java           |  453 --------
 ...mar.java => StoredProcedureRequestGrammar.java} |   78 +-
 .../StoredProcedureResponseDecorator.java          |   46 -
 .../extended/ads_impl/whoAmI/WhoAmIFactory.java    |  219 ++--
 .../ads_impl/whoAmI/WhoAmIRequestDecorator.java    |   59 -
 .../ads_impl/whoAmI/WhoAmIResponseContainer.java   |   80 --
 .../ads_impl/whoAmI/WhoAmIResponseDecoder.java     |  165 ---
 .../ads_impl/whoAmI/WhoAmIResponseDecorator.java   |  250 ----
 .../ads_impl/whoAmI/WhoAmIResponseGrammar.java     |  201 ----
 .../ads_impl/whoAmI/WhoAmIResponseStatesEnum.java  |   89 --
 .../syncrepl_impl/SyncInfoValueContainer.java      |   38 +-
 .../syncrepl_impl/SyncInfoValueDecorator.java      |  585 ----------
 .../syncrepl_impl/SyncInfoValueFactory.java        |   65 +-
 .../controls/ad/AdDirSyncRequestControlTest.java   |   64 +-
 .../controls/ad/AdDirSyncResponseControlTest.java  |   64 +-
 .../controls/ad/AdPolicyHintsControlTest.java      |   41 +-
 .../ppolicy/PasswordPolicyResponseTest.java        |   98 +-
 .../syncrepl_impl/SyncDoneValueControlTest.java    |   78 +-
 .../syncrepl_impl/SyncRequestValueControlTest.java |  141 +--
 .../syncrepl_impl/SyncStateValueControlTest.java   |   92 +-
 .../extras/controls/vlv/VLVRequestControlTest.java |  166 ++-
 .../controls/vlv/VLVResponseControlTest.java       |   84 +-
 .../ldap/extras/extended/ExtendedRequestTest.java  |   86 +-
 .../ldap/extras/extended/ExtendedResponseTest.java |  337 +++---
 .../ads_impl/cancel/CancelRequestTest.java         |  111 +-
 .../certGeneration/CertGenerationRequestTest.java  |  174 +--
 .../endTransaction/EndTransactionRequestTest.java  |  123 +-
 .../endTransaction/EndTransactionResponseTest.java |   74 +-
 .../GracefulDisconnectResponseTest.java            |  310 ++---
 .../gracefulShutdown/GracefulShutdownTest.java     |  269 ++---
 .../pwdModify/PasswordModifyRequestTest.java       |  571 ++++------
 .../pwdModify/PasswordModifyResponseTest.java      |  113 +-
 .../storedProcedure/StoredProcedureTest.java       |  106 +-
 .../ads_impl/whoAmI/WhoAmIResponseTest.java        |   62 +-
 .../syncrepl/SyncInfoValueControlTest.java         |  513 +++------
 .../api/ldap/model/message/ModifyRequestImpl.java  |    8 +-
 ...RequestImpl.java => OpaqueExtendedRequest.java} |  104 +-
 ...equestImpl.java => OpaqueExtendedResponse.java} |  119 +-
 .../model/message/ExtendedRequestImplTest.java     |  136 +--
 .../codec/protocol/mina/LdapProtocolDecoder.java   |   10 +-
 368 files changed, 5907 insertions(+), 26605 deletions(-)

diff --git a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/AbstractDsmlMessageDecorator.java b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/AbstractDsmlMessageDecorator.java
index c058448..f4c5659 100644
--- a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/AbstractDsmlMessageDecorator.java
+++ b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/AbstractDsmlMessageDecorator.java
@@ -27,7 +27,6 @@ import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.ldap.model.message.MessageTypeEnum;
-import org.apache.directory.api.ldap.model.message.Request;
 
 
 /**
@@ -143,15 +142,7 @@ public abstract class AbstractDsmlMessageDecorator<M extends Message>
         }
         else
         {
-            if ( this instanceof Request )
-            {
-                decorator = new DsmlControl<>( codec, codec.newRequestControl( control ) );
-            }
-            else
-            {
-                decorator = new DsmlControl<>( codec, codec.newResponseControl( control ) );
-            }
-
+            decorator = new DsmlControl( codec, control );
             decorated = control;
         }
 
diff --git a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/ParserUtils.java b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/ParserUtils.java
index e4c73e4..cb4fbf6 100644
--- a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/ParserUtils.java
+++ b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/ParserUtils.java
@@ -29,12 +29,12 @@ import javax.xml.transform.TransformerException;
 import javax.xml.transform.TransformerFactory;
 import javax.xml.transform.stream.StreamSource;
 
+import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.dsmlv2.actions.ReadSoapHeader;
 import org.apache.directory.api.dsmlv2.request.BatchRequestDsml;
 import org.apache.directory.api.dsmlv2.request.BatchRequestDsml.Processing;
 import org.apache.directory.api.dsmlv2.request.BatchRequestDsml.ResponseOrder;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.entry.Value;
 import org.apache.directory.api.ldap.model.ldif.LdifUtils;
@@ -245,23 +245,18 @@ public final class ParserUtils
                     controlElement.addAttribute( "criticality", "true" );
                 }
 
-                byte[] value;
+                Asn1Buffer asn1Buffer = new Asn1Buffer();
 
-                if ( control instanceof CodecControl<?> )
+                if ( isRequest )
                 {
-                    value = ( ( org.apache.directory.api.ldap.codec.api.CodecControl<?> ) control ).getValue();
+                    codec.getRequestControlFactories().get( control.getOid() ).encodeValue( asn1Buffer, control );
                 }
                 else
                 {
-                    if ( isRequest )
-                    {
-                        value = codec.newRequestControl( control ).getValue();
-                    }
-                    else
-                    {
-                        value = codec.newResponseControl( control ).getValue();
-                    }
+                    codec.getResponseControlFactories().get( control.getOid() ).encodeValue( asn1Buffer, control );
                 }
+                
+               byte[] value = asn1Buffer.getBytes().array();
 
                 if ( value != null )
                 {
diff --git a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/request/Dsmlv2Grammar.java b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/request/Dsmlv2Grammar.java
index bf57ab7..c1b714a 100644
--- a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/request/Dsmlv2Grammar.java
+++ b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/request/Dsmlv2Grammar.java
@@ -40,7 +40,7 @@ import org.apache.directory.api.dsmlv2.request.BatchRequestDsml.OnError;
 import org.apache.directory.api.dsmlv2.request.BatchRequestDsml.Processing;
 import org.apache.directory.api.dsmlv2.request.BatchRequestDsml.ResponseOrder;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
+import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.codec.api.LdapApiServiceFactory;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
@@ -57,13 +57,14 @@ import org.apache.directory.api.ldap.model.message.CompareRequest;
 import org.apache.directory.api.ldap.model.message.CompareRequestImpl;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.DeleteRequestImpl;
-import org.apache.directory.api.ldap.model.message.ExtendedRequestImpl;
+import org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequestImpl;
 import org.apache.directory.api.ldap.model.message.ModifyRequestImpl;
 import org.apache.directory.api.ldap.model.message.Request;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.ldap.model.message.SearchRequestImpl;
 import org.apache.directory.api.ldap.model.message.SearchScope;
+import org.apache.directory.api.ldap.model.message.controls.OpaqueControl;
 import org.apache.directory.api.ldap.model.name.Dn;
 import org.apache.directory.api.ldap.model.name.Rdn;
 import org.apache.directory.api.util.Base64;
@@ -643,7 +644,7 @@ public final class Dsmlv2Grammar extends AbstractGrammar implements Grammar
         {
             ExtendedRequestDsml<?, ?> extendedRequest =
                 new ExtendedRequestDsml<>( codec,
-                    new ExtendedRequestImpl() );
+                    new OpaqueExtendedRequest() );
             container.getBatchRequest().addRequest( extendedRequest );
 
             XmlPullParser xpp = container.getParser();
@@ -1994,10 +1995,11 @@ public final class Dsmlv2Grammar extends AbstractGrammar implements Grammar
         public void action( Dsmlv2Container container ) throws XmlPullParserException
         {
             XmlPullParser xpp = container.getParser();
-            CodecControl<? extends Control> control;
+            Control control;
 
             // Checking and adding the Control's attributes
             String attributeValue;
+            
             // TYPE
             attributeValue = xpp.getAttributeValue( "", "type" );
 
@@ -2007,8 +2009,18 @@ public final class Dsmlv2Grammar extends AbstractGrammar implements Grammar
                 {
                     throw new XmlPullParserException( I18n.err( I18n.ERR_03034_INCORRECT_TYPE_VALUE ), xpp, null );
                 }
-
-                control = codec.newRequestControl( codec.newRequestControl( attributeValue ) );
+                
+                ControlFactory<? extends Control> factory = codec.getRequestControlFactories().get( attributeValue );
+                
+                if ( factory == null )
+                {
+                    control = new OpaqueControl( attributeValue );
+                }
+                else
+                {
+                    control = factory.newControl();
+                }
+                
                 ( ( Request ) container.getBatchRequest().getCurrentRequest() ).addControl( control );
             }
             else
diff --git a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/response/Dsmlv2ResponseGrammar.java b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/response/Dsmlv2ResponseGrammar.java
index 14ae0dc..cd52f10 100644
--- a/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/response/Dsmlv2ResponseGrammar.java
+++ b/dsml/parser/src/main/java/org/apache/directory/api/dsmlv2/response/Dsmlv2ResponseGrammar.java
@@ -41,7 +41,7 @@ import org.apache.directory.api.dsmlv2.ParserUtils;
 import org.apache.directory.api.dsmlv2.Tag;
 import org.apache.directory.api.dsmlv2.response.ErrorResponse.ErrorResponseType;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
+import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.model.exception.LdapException;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.exception.LdapURLEncodingException;
@@ -2098,7 +2098,7 @@ public final class Dsmlv2ResponseGrammar extends AbstractGrammar implements Gram
     private void createAndAddControl( Dsmlv2Container container,
         AbstractDsmlMessageDecorator<? extends Message> parent ) throws XmlPullParserException
     {
-        CodecControl<? extends Control> control;
+        Control control;
 
         XmlPullParser xpp = container.getParser();
 
@@ -2114,7 +2114,18 @@ public final class Dsmlv2ResponseGrammar extends AbstractGrammar implements Gram
                 throw new XmlPullParserException( I18n.err( I18n.ERR_03006_INCORRECT_TYPE_ATTRIBUTE_VALUE ), xpp, null );
             }
 
-            control = container.getLdapCodecService().newResponseControl( new OpaqueControl( attributeValue ) );
+            ControlFactory<? extends Control> factory = container.getLdapCodecService().
+                getRequestControlFactories().get( attributeValue );
+            
+            if ( factory == null )
+            {
+                control = new OpaqueControl( attributeValue );
+            }
+            else
+            {
+                control = factory.newControl();
+            }
+            
             parent.addControl( control );
         }
         else
diff --git a/i18n/src/main/java/org/apache/directory/api/i18n/I18n.java b/i18n/src/main/java/org/apache/directory/api/i18n/I18n.java
index fa18f0e..b3a4340 100644
--- a/i18n/src/main/java/org/apache/directory/api/i18n/I18n.java
+++ b/i18n/src/main/java/org/apache/directory/api/i18n/I18n.java
@@ -274,6 +274,9 @@ public enum I18n
     ERR_05155_FLAG_TYPE_INVALID( "ERR_05155_FLAG_TYPE_INVALID" ),
     ERR_05156_INVALID_ATTRIBUTE_TYPE( "ERR_05156_INVALID_ATTRIBUTE_TYPE" ),
     ERR_05157_INVALID_DN( "ERR_05157_INVALID_DN" ),
+    ERR_05158_INVALID_REQUEST_VALUE( "ERR_05158_INVALID_REQUEST_VALUE" ),
+    ERR_05159_INVALID_RESPONSE_NAME_OID( "ERR_05159_INVALID_RESPONSE_NAME_OID" ),
+
 
     //     api                          5200-5299
     ERR_05200_NOT_INITIALIZED_YET( "ERR_05200_NOT_INITIALIZED_YET" ),
@@ -334,6 +337,7 @@ public enum I18n
     ERR_08106_AD_DIR_SYNC_MAX_RETURN_LENGTH_DECODING_ERROR( "ERR_08106_AD_DIR_SYNC_MAX_RETURN_LENGTH_DECODING_ERROR" ),
     ERR_08107_AD_DIR_SYNC_PARENTS_FIRST_DECODING_ERROR( "ERR_08107_AD_DIR_SYNC_PARENTS_FIRST_DECODING_ERROR" ),
     ERR_08108_AD_DIR_SYNC_MAX_ATTRIBUTE_COUNT_DECODING_ERROR( "ERR_08107_AD_DIR_SYNC_MAX_ATTRIBUTE_COUNT_DECODING_ERROR" ),
+    ERR_08109_BAD_CONTROL_VALUE( "ERR_08109_BAD_CONTROL_VALUE" ),
 
     //     extended                         8200-8399
     ERR_08200_CANCELID_DECODING_FAILED( "ERR_08200_CANCELID_DECODING_FAILED" ),
@@ -1210,6 +1214,7 @@ public enum I18n
     MSG_05182_SEARCH_RESULT_ENTRY_DN( "MSG_05182_SEARCH_RESULT_ENTRY_DN" ),
     MSG_05183_SEARCH_RESULT_REFERENCE_RESPONSE( "MSG_05183_SEARCH_RESULT_REFERENCE_RESPONSE" ),
     MSG_05184_SEARCH_REFERENCE_URL( "MSG_05184_SEARCH_REFERENCE_URL" ),
+    MSG_05185_MODIFY_REQUEST( "MSG_05185_MODIFY_REQUEST" ),
 
     //     api                              5200-5299
     MSG_5200_DECODED_LDAP_MESSAGE( "MSG_5200_DECODED_LDAP_MESSAGE" ),
diff --git a/i18n/src/main/resources/org/apache/directory/api/i18n/errors.properties b/i18n/src/main/resources/org/apache/directory/api/i18n/errors.properties
index 010efa7..3650d45 100644
--- a/i18n/src/main/resources/org/apache/directory/api/i18n/errors.properties
+++ b/i18n/src/main/resources/org/apache/directory/api/i18n/errors.properties
@@ -266,6 +266,8 @@ ERR_05154_EMPTY_SUBSTRING_INITIAL_FILTER_PDU=The substring initial filter is emp
 ERR_05155_FLAG_TYPE_INVALID=The types only flag {0} is invalid: {1}. It should be 0 or 255
 ERR_05156_INVALID_ATTRIBUTE_TYPE=The Attribute type {0} is invalid : {1}
 ERR_05157_INVALID_DN=The Dn {0} is invalid : {1}
+ERR_05158_INVALID_REQUEST_VALUE=The encoded value '{0}' cannot be decoded
+ERR_05159_INVALID_RESPONSE_NAME_OID=The Response name is not a valid OID : {0} ({1}) is invalid
 
 # api-ldap-codec-core api       5200-5299
 ERR_05200_NOT_INITIALIZED_YET=Not initialized yet!
@@ -326,6 +328,7 @@ ERR_08105_AD_DIR_SYNC_FLAG_DECODING_ERROR=Error while decoding the AdDirSync fla
 ERR_08106_AD_DIR_SYNC_MAX_RETURN_LENGTH_DECODING_ERROR=Error while decoding the AdDirSync maxReturnLength value: {0} 
 ERR_08107_AD_DIR_SYNC_PARENTS_FIRST_DECODING_ERROR=Error while decoding the AdDirSync parentsFirst value: {0}
 ERR_08108_AD_DIR_SYNC_MAX_ATTRIBUTE_COUNT_DECODING_ERROR=Error while decoding the AdDirSync maxAttributeCount value: {0}
+ERR_08109_BAD_CONTROL_VALUE=Bad control value: {0}
 
 # api-ldap-extras-codec extended     8200-8399
 ERR_08200_CANCELID_DECODING_FAILED=failed to decode the cancelId, the value should be between 0 and 2^31-1, it is ''{0}''
diff --git a/i18n/src/main/resources/org/apache/directory/api/i18n/messages.properties b/i18n/src/main/resources/org/apache/directory/api/i18n/messages.properties
index 08402ce..bb32351 100644
--- a/i18n/src/main/resources/org/apache/directory/api/i18n/messages.properties
+++ b/i18n/src/main/resources/org/apache/directory/api/i18n/messages.properties
@@ -227,6 +227,7 @@ MSG_05181_ATTRIBUTE_VALUE=Attribute value: {0}
 MSG_05182_SEARCH_RESULT_ENTRY_DN=Search Result Entry Dn found: {0}
 MSG_05183_SEARCH_RESULT_REFERENCE_RESPONSE=SearchResultReference response
 MSG_05184_SEARCH_REFERENCE_URL=Search reference URL found: {0}
+MSG_05185_MODIFY_REQUEST=Modify Request
 
 # api-ldap-codec-core api       5200-5299
 MSG_5200_DECODED_LDAP_MESSAGE=Decoded LdapMessage: {0}
diff --git a/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapCodecCoreOsgiTest.java b/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapCodecCoreOsgiTest.java
index 20a3ae3..166acd2 100644
--- a/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapCodecCoreOsgiTest.java
+++ b/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapCodecCoreOsgiTest.java
@@ -35,7 +35,6 @@ import org.apache.directory.api.ldap.codec.actions.response.bind.InitBindRespons
 import org.apache.directory.api.ldap.codec.actions.response.search.done.InitSearchResultDone;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.codec.api.LdapApiServiceFactory;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
 import org.apache.directory.api.ldap.codec.search.AndFilter;
 import org.apache.directory.api.ldap.codec.search.SubstringFilter;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
@@ -74,8 +73,7 @@ public class ApiLdapCodecCoreOsgiTest extends ApiOsgiTestBase
         new AndFilter();
         new SubstringFilter();
 
-        SearchRequest decoratedMessage = new SearchRequestImpl();
-        new SearchRequestDecorator( ldapApiService, decoratedMessage );
+        new SearchRequestImpl();
     }
 
 
diff --git a/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapExtrasCodecOsgiTest.java b/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapExtrasCodecOsgiTest.java
index 19ab5b3..ec40798 100644
--- a/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapExtrasCodecOsgiTest.java
+++ b/integ-osgi/src/test/java/org/apache/directory/api/osgi/ApiLdapExtrasCodecOsgiTest.java
@@ -25,13 +25,9 @@ import static org.junit.Assert.assertTrue;
 
 import javax.inject.Inject;
 
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyRequest;
 import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyResponse;
-import org.apache.directory.api.ldap.extras.controls.ppolicy_impl.PasswordPolicyRequestDecorator;
-import org.apache.directory.api.ldap.extras.controls.ppolicy_impl.PasswordPolicyResponseDecorator;
-import org.apache.directory.api.ldap.extras.extended.ads_impl.startTls.StartTlsRequestDecorator;
 import org.apache.directory.api.ldap.extras.extended.startTls.StartTlsRequest;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.ExtendedRequest;
@@ -54,17 +50,19 @@ public class ApiLdapExtrasCodecOsgiTest extends ApiOsgiTestBase
     @Override
     protected void useBundleClasses() throws Exception
     {
-        CodecControl<? extends Control> ppRequest = ldapApiService.newRequestControl( PasswordPolicyRequest.OID );
+        Control ppRequest = ldapApiService.getRequestControlFactories().
+            get( PasswordPolicyRequest.OID ).newControl();
         assertNotNull( ppRequest );
-        assertTrue( ppRequest instanceof PasswordPolicyRequestDecorator );
+        assertTrue( ppRequest instanceof PasswordPolicyRequest );
 
-        CodecControl<? extends Control> ppResponse = ldapApiService.newResponseControl( PasswordPolicyResponse.OID );
+        Control ppResponse = ldapApiService.getResponseControlFactories().
+            get( PasswordPolicyResponse.OID ).newControl();
+        
         assertNotNull( ppResponse );
-        assertTrue( ppResponse instanceof PasswordPolicyResponseDecorator );
+        assertTrue( ppResponse instanceof PasswordPolicyResponse );
 
-        ExtendedRequest extendedRequest = ldapApiService.newExtendedRequest( StartTlsRequest.EXTENSION_OID, null );
+        ExtendedRequest extendedRequest = ldapApiService.getExtendedRequestFactories().get( StartTlsRequest.EXTENSION_OID ).newRequest();
         assertNotNull( extendedRequest );
-        assertTrue( extendedRequest instanceof StartTlsRequestDecorator );
+        assertTrue( extendedRequest instanceof StartTlsRequest );
     }
-
 }
diff --git a/integ/src/test/java/org/apache/directory/api/ldap/codec/api/StandaloneLdapCodecServiceTest.java b/integ/src/test/java/org/apache/directory/api/ldap/codec/api/StandaloneLdapCodecServiceTest.java
index ab6a435..329b8e4 100644
--- a/integ/src/test/java/org/apache/directory/api/ldap/codec/api/StandaloneLdapCodecServiceTest.java
+++ b/integ/src/test/java/org/apache/directory/api/ldap/codec/api/StandaloneLdapCodecServiceTest.java
@@ -25,10 +25,12 @@ import static org.junit.Assert.assertTrue;
 
 import org.apache.directory.api.ldap.codec.standalone.StandaloneLdapApiService;
 import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyRequest;
+import org.apache.directory.api.ldap.extras.extended.ads_impl.storedProcedure.StoredProcedureFactory;
 import org.apache.directory.api.ldap.extras.extended.storedProcedure.StoredProcedureRequest;
 import org.apache.directory.api.ldap.extras.extended.storedProcedure.StoredProcedureRequestImpl;
 import org.apache.directory.api.ldap.extras.intermediate.syncrepl.SyncInfoValue;
 import org.apache.directory.api.ldap.extras.intermediate.syncrepl.SyncInfoValueImpl;
+import org.apache.directory.api.ldap.extras.intermediate.syncrepl_impl.SyncInfoValueFactory;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.util.Strings;
 import org.junit.BeforeClass;
@@ -107,7 +109,7 @@ public class StandaloneLdapCodecServiceTest
 
         assertTrue( codec.isControlRegistered( PasswordPolicyRequest.OID ) );
 
-        CodecControl<? extends Control> control = codec.newRequestControl( PasswordPolicyRequest.OID );
+        Control control = codec.getRequestControlFactories().get( PasswordPolicyRequest.OID ).newControl();
         assertNotNull( control );
         assertNotNull( codec );
     }
@@ -126,9 +128,12 @@ public class StandaloneLdapCodecServiceTest
 
         assertNotNull( req );
         assertNotNull( codec );
-
-        StoredProcedureRequest decorator = ( StoredProcedureRequest ) codec.decorate( req );
-        assertNotNull( decorator );
+        
+        StoredProcedureFactory factory = ( StoredProcedureFactory ) codec.getExtendedRequestFactories().get( 
+            StoredProcedureRequest.EXTENSION_OID );
+        
+        req = factory.newRequest();
+        assertNotNull( req );
     }
 
 
@@ -145,8 +150,10 @@ public class StandaloneLdapCodecServiceTest
         assertNotNull( syncInfoValue );
         assertNotNull( codec );
 
-        codec.decorate( syncInfoValue );
-        SyncInfoValue decorator = ( SyncInfoValue ) codec.decorate( syncInfoValue );
-        assertNotNull( decorator );
+        SyncInfoValueFactory factory = 
+            ( SyncInfoValueFactory ) codec.getIntermediateResponseFactories().get( 
+                SyncInfoValue.OID );
+        syncInfoValue = ( SyncInfoValue ) factory.newResponse();
+        assertNotNull( syncInfoValue );
     }
 }
diff --git a/ldap/client/api/pom.xml b/ldap/client/api/pom.xml
index 71d7ff8..edfadf9 100644
--- a/ldap/client/api/pom.xml
+++ b/ldap/client/api/pom.xml
@@ -155,7 +155,6 @@
               org.apache.directory.api.ldap.aci;version=${project.version},
               org.apache.directory.api.ldap.aci.protectedItem;version=${project.version},
               org.apache.directory.api.ldap.codec.api;version=${project.version},
-              org.apache.directory.api.ldap.codec.decorators;version=${project.version},
               org.apache.directory.api.ldap.extras.controls.ppolicy_impl;version=${project.version},
               org.apache.directory.api.ldap.extras.controls.ppolicy;version=${project.version},
               org.apache.directory.api.ldap.extras.controls.vlv_impl;version=${project.version},
diff --git a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
index 3f33606..cb4784d 100644
--- a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
+++ b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
@@ -55,13 +55,13 @@ import javax.security.sasl.SaslClient;
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Oid;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
 import org.apache.directory.api.ldap.codec.api.BinaryAttributeDetector;
 import org.apache.directory.api.ldap.codec.api.DefaultConfigurableBinaryAttributeDetector;
+import org.apache.directory.api.ldap.codec.api.ExtendedOperationFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.codec.api.LdapApiServiceFactory;
 import org.apache.directory.api.ldap.codec.api.LdapDecoder;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.MessageEncoderException;
 import org.apache.directory.api.ldap.codec.api.SchemaBinaryAttributeDetector;
 import org.apache.directory.api.ldap.extras.extended.startTls.StartTlsRequestImpl;
@@ -81,6 +81,7 @@ import org.apache.directory.api.ldap.model.exception.LdapAuthenticationException
 import org.apache.directory.api.ldap.model.exception.LdapException;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.exception.LdapNoPermissionException;
+import org.apache.directory.api.ldap.model.exception.LdapNoSuchObjectException;
 import org.apache.directory.api.ldap.model.exception.LdapOperationException;
 import org.apache.directory.api.ldap.model.exception.LdapOtherException;
 import org.apache.directory.api.ldap.model.exception.LdapTlsHandshakeException;
@@ -112,6 +113,7 @@ import org.apache.directory.api.ldap.model.message.ModifyDnResponse;
 import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.apache.directory.api.ldap.model.message.ModifyRequestImpl;
 import org.apache.directory.api.ldap.model.message.ModifyResponse;
+import org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest;
 import org.apache.directory.api.ldap.model.message.Request;
 import org.apache.directory.api.ldap.model.message.Response;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
@@ -892,8 +894,8 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
 
         // Store the container into the session if we don't have one
         @SuppressWarnings("unchecked")
-        LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container =
-            ( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> ) ldapSession
+        LdapMessageContainerDirect<? extends Message> container =
+            ( LdapMessageContainerDirect<? extends Message> ) ldapSession
                 .getAttribute( LdapDecoder.MESSAGE_CONTAINER_ATTR );
 
         if ( container != null )
@@ -913,7 +915,7 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
             }
 
             ldapSession.setAttribute( LdapDecoder.MESSAGE_CONTAINER_ATTR,
-                new LdapMessageContainer<AbstractMessageDecorator<? extends Message>>( codec, atDetector ) );
+                new LdapMessageContainerDirect<Message>( codec, atDetector ) );
         }
 
         // Initialize the MessageId
@@ -3897,9 +3899,26 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
     @Override
     public ExtendedResponse extended( Oid oid, byte[] value ) throws LdapException
     {
-        ExtendedRequest extendedRequest =
-            LdapApiServiceFactory.getSingleton().newExtendedRequest( oid.toString(), value );
-        return extended( extendedRequest );
+        Map<String, ExtendedOperationFactory> factories = LdapApiServiceFactory.getSingleton().getExtendedRequestFactories();
+        String oidStr = oid.toString();
+        
+        ExtendedOperationFactory factory = factories.get( oidStr );
+        
+        if ( factory != null )
+        {
+            try
+            {            
+                return extended( factory.newRequest( value ) );
+            }
+            catch ( DecoderException de )
+            {
+                throw new LdapNoSuchObjectException( de.getMessage() );
+            }
+        }
+        else
+        {
+            return extended( new OpaqueExtendedRequest( oidStr, value ) );
+        }
     }
 
 
@@ -3966,7 +3985,7 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
             }
 
             // Decode the payload now
-            return codec.decorate( response );
+            return response;
         }
         catch ( Exception ie )
         {
@@ -4014,7 +4033,7 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
         addToFutureMap( newId, extendedFuture );
 
         // Send the request to the server
-        writeRequest( codec.decorate( extendedRequest ) );
+        writeRequest( extendedRequest );
 
         // Ok, done return the future
         return extendedFuture;
@@ -4277,7 +4296,7 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
 
             // Change the container's BinaryDetector
             ldapSession.setAttribute( LdapDecoder.MESSAGE_CONTAINER_ATTR,
-                new LdapMessageContainer<AbstractMessageDecorator<? extends Message>>( codec,
+                new LdapMessageContainerDirect<>( codec,
                     new SchemaBinaryAttributeDetector( schemaManager ) ) );
 
         }
@@ -4539,8 +4558,8 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
     public void sessionCreated( IoSession session ) throws Exception
     {
         // Last, store the message container
-        LdapMessageContainer<? extends AbstractMessageDecorator<Message>> ldapMessageContainer =
-            new LdapMessageContainer<>(
+        LdapMessageContainerDirect<Message> ldapMessageContainer =
+            new LdapMessageContainerDirect<>(
                 codec, config.getBinaryAttributeDetector() );
 
         session.setAttribute( LdapDecoder.MESSAGE_CONTAINER_ATTR, ldapMessageContainer );
diff --git a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/AbstractPasswordPolicyResponder.java b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/AbstractPasswordPolicyResponder.java
index 64e97f6..62b9109 100755
--- a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/AbstractPasswordPolicyResponder.java
+++ b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/AbstractPasswordPolicyResponder.java
@@ -22,7 +22,7 @@ package org.apache.directory.ldap.client.template;
 
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyResponse;
-import org.apache.directory.api.ldap.extras.controls.ppolicy_impl.PasswordPolicyResponseDecorator;
+import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyResponseImpl;
 import org.apache.directory.api.ldap.model.exception.LdapException;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.Response;
@@ -42,13 +42,12 @@ import org.apache.directory.ldap.client.template.exception.PasswordException;
  */
 public abstract class AbstractPasswordPolicyResponder implements PasswordPolicyResponder
 {
-    private final PasswordPolicyResponseDecorator passwordPolicyResponseControl;
+    private final PasswordPolicyResponse passwordPolicyResponseControl;
 
 
     protected AbstractPasswordPolicyResponder( LdapApiService ldapApiService )
     {
-        this.passwordPolicyResponseControl = new PasswordPolicyResponseDecorator(
-            ldapApiService );
+        this.passwordPolicyResponseControl = new PasswordPolicyResponseImpl();
     }
     
     
@@ -96,7 +95,7 @@ public abstract class AbstractPasswordPolicyResponder implements PasswordPolicyR
         
         return control == null
             ? null
-            : ( ( PasswordPolicyResponseDecorator ) control ).getDecorated();
+            : ( PasswordPolicyResponse ) control;
     }
 
 
diff --git a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/LdapConnectionTemplate.java b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/LdapConnectionTemplate.java
index bcbe5ae..5cfb70f 100755
--- a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/LdapConnectionTemplate.java
+++ b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/template/LdapConnectionTemplate.java
@@ -24,7 +24,8 @@ import java.util.ArrayList;
 import java.util.List;
 
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.extras.controls.ppolicy_impl.PasswordPolicyResponseDecorator;
+import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyResponse;
+import org.apache.directory.api.ldap.extras.controls.ppolicy.PasswordPolicyResponseImpl;
 import org.apache.directory.api.ldap.model.entry.Attribute;
 import org.apache.directory.api.ldap.model.entry.Entry;
 import org.apache.directory.api.ldap.model.entry.Value;
@@ -75,7 +76,7 @@ public class LdapConnectionTemplate implements LdapConnectionOperations, ModelFa
     };
 
     private LdapConnectionPool connectionPool;
-    private final PasswordPolicyResponseDecorator passwordPolicyRequestControl;
+    private final PasswordPolicyResponse passwordPolicyRequestControl;
     private PasswordPolicyResponder passwordPolicyResponder;
     private ModelFactory modelFactory;
 
@@ -93,8 +94,7 @@ public class LdapConnectionTemplate implements LdapConnectionOperations, ModelFa
         }
         
         this.connectionPool = connectionPool;
-        this.passwordPolicyRequestControl = new PasswordPolicyResponseDecorator(
-            connectionPool.getLdapApiService() );
+        this.passwordPolicyRequestControl = new PasswordPolicyResponseImpl();
         this.passwordPolicyResponder = new PasswordPolicyResponderImpl(
             connectionPool.getLdapApiService() );
         this.modelFactory = new ModelFactoryImpl();
diff --git a/ldap/codec/core/pom.xml b/ldap/codec/core/pom.xml
index 8345d8c..893e77f 100644
--- a/ldap/codec/core/pom.xml
+++ b/ldap/codec/core/pom.xml
@@ -127,7 +127,6 @@
               org.apache.directory.api.ldap.codec.api;version=${project.version};-noimport:=true,
               org.apache.directory.api.ldap.codec.controls;version=${project.version};-noimport:=true,
               org.apache.directory.api.ldap.codec.controls.*;version=${project.version};-noimport:=true,
-              org.apache.directory.api.ldap.codec.decorators;version=${project.version};-noimport:=true,
               org.apache.directory.api.ldap.codec.osgi;version=${project.version};-noimport:=true,
               org.apache.directory.api.ldap.codec.search;version=${project.version};-noimport:=true
             </Export-Package>
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/LdapMessageGrammar.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/LdapMessageGrammar.java
index 65d9ce5..930e925 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/LdapMessageGrammar.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/LdapMessageGrammar.java
@@ -27,17 +27,13 @@ import static org.apache.directory.api.asn1.ber.tlv.UniversalTag.OCTET_STRING;
 import static org.apache.directory.api.asn1.ber.tlv.UniversalTag.SEQUENCE;
 import static org.apache.directory.api.asn1.ber.tlv.UniversalTag.SET;
 
-import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.actions.CheckNotNullLength;
 import org.apache.directory.api.asn1.ber.grammar.AbstractGrammar;
 import org.apache.directory.api.asn1.ber.grammar.Grammar;
-import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.grammar.GrammarTransition;
-import org.apache.directory.api.asn1.ber.tlv.TLV;
-import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.actions.AllowGrammarEnd;
 import org.apache.directory.api.ldap.codec.actions.CheckLengthNotNull;
-import org.apache.directory.api.ldap.codec.actions.controls.AddControl;
+import org.apache.directory.api.ldap.codec.actions.controls.StoreControlName;
 import org.apache.directory.api.ldap.codec.actions.controls.InitControls;
 import org.apache.directory.api.ldap.codec.actions.controls.StoreControlCriticality;
 import org.apache.directory.api.ldap.codec.actions.controls.StoreControlValue;
@@ -88,7 +84,6 @@ import org.apache.directory.api.ldap.codec.actions.request.search.StoreSearchReq
 import org.apache.directory.api.ldap.codec.actions.request.search.StoreSearchRequestSizeLimit;
 import org.apache.directory.api.ldap.codec.actions.request.search.StoreSearchRequestTimeLimit;
 import org.apache.directory.api.ldap.codec.actions.request.search.StoreSearchRequestTypesOnly;
-import org.apache.directory.api.ldap.codec.actions.request.search.StoreTypeMatchingRule;
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.InitAndFilter;
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.InitApproxMatchFilter;
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.InitAssertionValueFilter;
@@ -106,7 +101,9 @@ import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreFi
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreInitial;
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreMatchValue;
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreMatchingRuleDnAttributes;
+import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreMatchingRuleId;
 import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreSubstringFilterType;
+import org.apache.directory.api.ldap.codec.actions.request.search.filter.StoreMatchingRuleType;
 import org.apache.directory.api.ldap.codec.actions.request.unbind.InitUnbindRequest;
 import org.apache.directory.api.ldap.codec.actions.response.add.InitAddResponse;
 import org.apache.directory.api.ldap.codec.actions.response.bind.InitBindResponse;
@@ -128,13 +125,10 @@ import org.apache.directory.api.ldap.codec.actions.response.search.entry.StoreSe
 import org.apache.directory.api.ldap.codec.actions.response.search.entry.StoreSearchResultEntryObjectName;
 import org.apache.directory.api.ldap.codec.actions.response.search.reference.InitSearchResultReference;
 import org.apache.directory.api.ldap.codec.actions.response.search.reference.StoreReference;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
-import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
-import org.apache.directory.api.ldap.model.message.Message;
-import org.apache.directory.api.util.Strings;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.AbstractMessage;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -147,13 +141,13 @@ import org.slf4j.LoggerFactory;
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public final class LdapMessageGrammar extends
-    AbstractGrammar<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+    AbstractGrammar<LdapMessageContainerDirect<AbstractMessage>>
 {
     /** The logger */
     static final Logger LOG = LoggerFactory.getLogger( LdapMessageGrammar.class );
 
     /** The instance of grammar. LdapMessageGrammar is a singleton */
-    private static Grammar<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>> instance =
+    private static Grammar<LdapMessageContainerDirect<AbstractMessage>> instance =
         new LdapMessageGrammar();
 
 
@@ -182,7 +176,7 @@ public final class LdapMessageGrammar extends
         //
         // We will just check that the length is not null
         super.transitions[LdapStatesEnum.START_STATE.ordinal()][SEQUENCE.getValue()] =
-            new GrammarTransition<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>(
+            new GrammarTransition(
                 LdapStatesEnum.START_STATE,
                 LdapStatesEnum.LDAP_MESSAGE_STATE,
                 SEQUENCE,
@@ -202,7 +196,7 @@ public final class LdapMessageGrammar extends
         // The message ID will be temporarily stored in the container, because we can't store it
         // into an object.
         super.transitions[LdapStatesEnum.LDAP_MESSAGE_STATE.ordinal()][INTEGER.getValue()] =
-            new GrammarTransition<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>(
+            new GrammarTransition(
                 LdapStatesEnum.LDAP_MESSAGE_STATE,
                 LdapStatesEnum.MESSAGE_ID_STATE,
                 INTEGER,
@@ -2260,7 +2254,7 @@ public final class LdapMessageGrammar extends
                 LdapStatesEnum.CONTROL_STATE,
                 LdapStatesEnum.CONTROL_TYPE_STATE,
                 OCTET_STRING,
-                new AddControl() );
+                new StoreControlName() );
 
         // ============================================================================================
         // Transition from ControlType to Control Criticality
@@ -3783,7 +3777,7 @@ public final class LdapMessageGrammar extends
                 LdapStatesEnum.TYPE_SUBSTRING_STATE,
                 LdapStatesEnum.SUBSTRINGS_STATE,
                 SEQUENCE,
-                new CheckNotNullLength<LdapMessageContainer<SearchRequestDecorator>>() );
+                new CheckNotNullLength<LdapMessageContainerDirect<SearchRequest>>() );
 
         // --------------------------------------------------------------------------------------------
         // Transition from substrings to Initial
@@ -4853,34 +4847,8 @@ public final class LdapMessageGrammar extends
         // Store the matching rule ID
         super.transitions[LdapStatesEnum.EXTENSIBLE_MATCH_STATE.ordinal()][LdapCodecConstants.MATCHING_RULE_ID_TAG] = new GrammarTransition(
             LdapStatesEnum.EXTENSIBLE_MATCH_STATE, LdapStatesEnum.MATCHING_RULE_STATE,
-            LdapCodecConstants.MATCHING_RULE_ID_TAG, new GrammarAction<LdapMessageContainer<SearchRequestDecorator>>(
-                "Store matching rule Value" )
-            {
-                @Override
-                public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
-                {
-                    SearchRequestDecorator searchRequest = container.getMessage();
-
-                    TLV tlv = container.getCurrentTLV();
-
-                    // Store the value.
-                    ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter )
-                        searchRequest.getTerminalFilter();
-
-                    if ( tlv.getLength() == 0 )
-                    {
-                        String msg = I18n.err( I18n.ERR_05001_EMPTY_MATCHING_RULE );
-                        LOG.error( msg );
-
-                        // It will generate a PROTOCOL_ERROR
-                        throw new DecoderException( msg );
-                    }
-                    else
-                    {
-                        extensibleMatchFilter.setMatchingRule( Strings.utf8ToString( tlv.getValue().getData() ) );
-                    }
-                }
-            } );
+            LdapCodecConstants.MATCHING_RULE_ID_TAG, 
+            new StoreMatchingRuleId() );
 
         // --------------------------------------------------------------------------------------------
         // Transition from Extensible Match to type matching rule
@@ -4900,7 +4868,7 @@ public final class LdapMessageGrammar extends
                 LdapStatesEnum.EXTENSIBLE_MATCH_STATE,
                 LdapStatesEnum.TYPE_MATCHING_RULE_STATE,
                 LdapCodecConstants.MATCHING_RULE_TYPE_TAG,
-                new StoreTypeMatchingRule() );
+                new StoreMatchingRuleType() );
 
         // --------------------------------------------------------------------------------------------
         // Transition from Extensible Match to match value
@@ -4942,7 +4910,7 @@ public final class LdapMessageGrammar extends
                 LdapStatesEnum.MATCHING_RULE_STATE,
                 LdapStatesEnum.TYPE_MATCHING_RULE_STATE,
                 LdapCodecConstants.MATCHING_RULE_TYPE_TAG,
-                new StoreTypeMatchingRule() );
+                new StoreMatchingRuleType() );
 
         // --------------------------------------------------------------------------------------------
         // Transition from matching rule to match value
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/AllowGrammarEnd.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/AllowGrammarEnd.java
index ecf29f5..5c0be61 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/AllowGrammarEnd.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/AllowGrammarEnd.java
@@ -21,8 +21,7 @@ package org.apache.directory.api.ldap.codec.actions;
 
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Message;
 
 
@@ -31,7 +30,7 @@ import org.apache.directory.api.ldap.model.message.Message;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AllowGrammarEnd extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class AllowGrammarEnd extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /**
      * Instantiates a new value action.
@@ -45,7 +44,7 @@ public class AllowGrammarEnd extends GrammarAction<LdapMessageContainer<Abstract
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container )
+    public void action( LdapMessageContainerDirect<Message> container )
     {
         container.setGrammarEndAllowed( true );
     }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/CheckLengthNotNull.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/CheckLengthNotNull.java
index 579f9f8..c99de8b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/CheckLengthNotNull.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/CheckLengthNotNull.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -36,7 +35,7 @@ import org.slf4j.LoggerFactory;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class CheckLengthNotNull extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class CheckLengthNotNull extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( CheckLengthNotNull.class );
@@ -54,7 +53,7 @@ public class CheckLengthNotNull extends GrammarAction<LdapMessageContainer<Abstr
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
         int expectedLength = tlv.getLength();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/InitControls.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/InitControls.java
index 2342901..e3926f7 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/InitControls.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/InitControls.java
@@ -23,15 +23,14 @@ package org.apache.directory.api.ldap.codec.actions.controls;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 
 /**
- * The action used to initialize a control.
+ * The action used to initialise the controls.
  * <pre>
  *         ... },
  *     controls       [0] Controls OPTIONAL }
@@ -41,7 +40,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitControls extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class InitControls extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitControls.class );
@@ -59,7 +58,7 @@ public class InitControls extends GrammarAction<LdapMessageContainer<AbstractMes
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container )
+    public void action( LdapMessageContainerDirect<Message> container )
     {
         TLV tlv = container.getCurrentTLV();
         int expectedLength = tlv.getLength();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlCriticality.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlCriticality.java
index 46a9d9d..d3c789e 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlCriticality.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlCriticality.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.BooleanDecoder;
 import org.apache.directory.api.asn1.ber.tlv.BooleanDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.util.Strings;
@@ -47,7 +46,7 @@ import org.slf4j.LoggerFactory;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreControlCriticality extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreControlCriticality extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreControlCriticality.class );
@@ -65,7 +64,7 @@ public class StoreControlCriticality extends GrammarAction<LdapMessageContainer<
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/AddControl.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlName.java
similarity index 67%
rename from ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/AddControl.java
rename to ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlName.java
index feeb25e..cf00b01 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/AddControl.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlName.java
@@ -25,12 +25,13 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.asn1.util.Oid;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.ControlFactory;
+import org.apache.directory.api.ldap.codec.api.LdapApiService;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.ldap.model.message.Request;
+import org.apache.directory.api.ldap.model.message.controls.OpaqueControl;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -41,20 +42,20 @@ import org.slf4j.LoggerFactory;
  * <pre>
  * Control ::= SEQUENCE {
  *     controlType             LDAPOID,
- *     ...
+ *     ...LdapMessageContainerDirect<Message>
  * </pre>
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AddControl extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreControlName extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
-    private static final Logger LOG = LoggerFactory.getLogger( AddControl.class );
+    private static final Logger LOG = LoggerFactory.getLogger( StoreControlName.class );
 
     /**
      * Instantiates a new AddControl action.
      */
-    public AddControl()
+    public StoreControlName()
     {
         super( "Add a new control" );
     }
@@ -64,7 +65,7 @@ public class AddControl extends GrammarAction<LdapMessageContainer<AbstractMessa
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
@@ -92,22 +93,40 @@ public class AddControl extends GrammarAction<LdapMessageContainer<AbstractMessa
             throw new DecoderException( msg );
         }
 
+        // Search for the control. It can be a request or a response control.
+        // If the control is not known, we create an Opaque control
         Message message = container.getMessage();
+        LdapApiService codec = container.getLdapCodecService();
+        ControlFactory<? extends Control> controlFactory;
         
         Control control;
 
         if ( message instanceof Request )
         {
-            control = container.getLdapCodecService().newRequestControl( oidValue );
+            controlFactory = codec.getRequestControlFactories().get( oidValue );
         }
         else
         {
-            control = container.getLdapCodecService().newResponseControl( oidValue );
+            controlFactory = codec.getResponseControlFactories().get( oidValue );
         }
-    
+
+        if ( controlFactory == null )
+        {
+            control =  new OpaqueControl( oidValue );
+        }
+        else
+        {
+            control = controlFactory.newControl();
+        }
+
+        container.setControlFactory( controlFactory );
+        
+        // At this point, the control exists, we may have to decode the value and feed it
+        //In any case, add it to the message's controls, and store it in the container for further
+        // processing (aka, value decoding)
         message.addControl( control );
 
-        container.setCurrentControl( ( ControlDecorator<?> ) control );
+        container.setCurrentControl( control );
 
         // We can have an END transition
         container.setGrammarEndAllowed( true );
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlValue.java
index 2f2a69a..19408fa 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/controls/StoreControlValue.java
@@ -25,9 +25,8 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.BerValue;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.ControlFactory;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.util.Strings;
@@ -47,7 +46,7 @@ import org.slf4j.LoggerFactory;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreControlValue extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreControlValue extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreControlValue.class );
@@ -66,24 +65,20 @@ public class StoreControlValue extends GrammarAction<LdapMessageContainer<Abstra
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
-        CodecControl<? extends Control> control = container.getCurrentControl();
+        Control control = container.getCurrentControl();
 
         // Get the current control
         BerValue value = tlv.getValue();
 
         // Store the value - have to handle the special case of a 0 length value
-        if ( tlv.getLength() == 0 )
+        if ( tlv.getLength() >= 0 )
         {
-            control.setValue( Strings.EMPTY_BYTES );
-        }
-        else
-        {
-            control.setValue( value.getData() );
-            control.decode( value.getData() );
+            ControlFactory<?> factory = container.getControlFactory();
+            factory.decodeValue( control, value.getData() );
         }
 
         // We can have an END transition
@@ -91,7 +86,7 @@ public class StoreControlValue extends GrammarAction<LdapMessageContainer<Abstra
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_08203_CONTROL_VALUE, Strings.dumpBytes( control.getValue() ) ) );
+            LOG.debug( I18n.msg( I18n.MSG_08203_CONTROL_VALUE, Strings.dumpBytes( value.getData() ) ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/InitLdapMessage.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/InitLdapMessage.java
index 681adde..6e37601 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/InitLdapMessage.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/InitLdapMessage.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -42,7 +41,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitLdapMessage extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class InitLdapMessage extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitLdapMessage.class );
@@ -61,7 +60,7 @@ public class InitLdapMessage extends GrammarAction<LdapMessageContainer<Abstract
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/StoreMessageId.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/StoreMessageId.java
index 7933baa..ffc2cfe 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/StoreMessageId.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapMessage/StoreMessageId.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoder;
 import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -51,7 +50,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreMessageId extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreMessageId extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreMessageId.class );
@@ -70,7 +69,7 @@ public class StoreMessageId extends GrammarAction<LdapMessageContainer<AbstractM
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         // The current TLV should be a integer
         // We get it and store it in MessageId
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/AddReferral.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/AddReferral.java
index 5e7fb73..f870e9f 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/AddReferral.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/AddReferral.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.exception.LdapURLEncodingException;
 import org.apache.directory.api.ldap.model.message.LdapResult;
 import org.apache.directory.api.ldap.model.message.Message;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AddReferral extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class AddReferral extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( AddReferral.class );
@@ -65,7 +64,7 @@ public class AddReferral extends GrammarAction<LdapMessageContainer<AbstractMess
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/InitReferrals.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/InitReferrals.java
index d11aff5..ac3e649 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/InitReferrals.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/InitReferrals.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.LdapResult;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.ldap.model.message.Referral;
@@ -44,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitReferrals extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class InitReferrals extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitReferrals.class );
@@ -62,7 +61,7 @@ public class InitReferrals extends GrammarAction<LdapMessageContainer<AbstractMe
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreErrorMessage.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreErrorMessage.java
index a61faf6..0199a17 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreErrorMessage.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreErrorMessage.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.ldapResult;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.LdapResult;
 import org.apache.directory.api.ldap.model.message.Message;
 import org.apache.directory.api.util.Strings;
@@ -43,7 +42,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreErrorMessage extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreErrorMessage extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreErrorMessage.class );
@@ -61,7 +60,7 @@ public class StoreErrorMessage extends GrammarAction<LdapMessageContainer<Abstra
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container )
+    public void action( LdapMessageContainerDirect<Message> container )
     {
         // Get the Value and store it in the BindResponse
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreMatchedDN.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreMatchedDN.java
index e3ad3f0..755c98e 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreMatchedDN.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreMatchedDN.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.LdapResult;
 import org.apache.directory.api.ldap.model.message.Message;
@@ -47,7 +46,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreMatchedDN extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreMatchedDN extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreMatchedDN.class );
@@ -65,7 +64,7 @@ public class StoreMatchedDN extends GrammarAction<LdapMessageContainer<AbstractM
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         // Get the Value and store it in the BindResponse
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreResultCode.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreResultCode.java
index adb1a61..12ef847 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreResultCode.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/ldapResult/StoreResultCode.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoder;
 import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.api.AbstractMessageDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.LdapResult;
 import org.apache.directory.api.ldap.model.message.LdapResultImpl;
 import org.apache.directory.api.ldap.model.message.Message;
@@ -48,7 +47,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreResultCode extends GrammarAction<LdapMessageContainer<AbstractMessageDecorator<? extends Message>>>
+public class StoreResultCode extends GrammarAction<LdapMessageContainerDirect<Message>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreResultCode.class );
@@ -66,7 +65,7 @@ public class StoreResultCode extends GrammarAction<LdapMessageContainer<Abstract
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<Message> container ) throws DecoderException
     {
         // The current TLV should be a integer
         // We get it and store it in MessageId
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/abandon/InitAbandonRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/abandon/InitAbandonRequest.java
index 514eca7..5272e2a 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/abandon/InitAbandonRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/abandon/InitAbandonRequest.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoder;
 import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.AbandonRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.AbandonRequest;
 import org.apache.directory.api.ldap.model.message.AbandonRequestImpl;
 import org.apache.directory.api.util.Strings;
@@ -44,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAbandonRequest extends GrammarAction<LdapMessageContainer<AbandonRequestDecorator>>
+public class InitAbandonRequest extends GrammarAction<LdapMessageContainerDirect<AbandonRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAbandonRequest.class );
@@ -63,13 +62,11 @@ public class InitAbandonRequest extends GrammarAction<LdapMessageContainer<Aband
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AbandonRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<AbandonRequest> container ) throws DecoderException
     {
         // Create the AbandonRequest LdapMessage instance and store it in the container
-        AbandonRequest internalAbandonRequest = new AbandonRequestImpl();
-        internalAbandonRequest.setMessageId( container.getMessageId() );
-        AbandonRequestDecorator abandonRequest = new AbandonRequestDecorator(
-            container.getLdapCodecService(), internalAbandonRequest );
+        AbandonRequest abandonRequest = new AbandonRequestImpl();
+        abandonRequest.setMessageId( container.getMessageId() );
         container.setMessage( abandonRequest );
 
         // The current TLV should be a integer
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAddRequestAttributeType.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAddRequestAttributeType.java
index 883bcc9..5fcfb0d 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAddRequestAttributeType.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAddRequestAttributeType.java
@@ -24,10 +24,12 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.AddRequestDecorator;
+import org.apache.directory.api.ldap.model.entry.Attribute;
+import org.apache.directory.api.ldap.model.entry.DefaultAttribute;
 import org.apache.directory.api.ldap.model.exception.LdapException;
+import org.apache.directory.api.ldap.model.message.AddRequest;
 import org.apache.directory.api.ldap.model.message.AddResponseImpl;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
 import org.apache.directory.api.util.Strings;
@@ -44,7 +46,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AddAddRequestAttributeType extends GrammarAction<LdapMessageContainer<AddRequestDecorator>>
+public class AddAddRequestAttributeType extends GrammarAction<LdapMessageContainerDirect<AddRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( AddAddRequestAttributeType.class );
@@ -62,9 +64,9 @@ public class AddAddRequestAttributeType extends GrammarAction<LdapMessageContain
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AddRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<AddRequest> container ) throws DecoderException
     {
-        AddRequestDecorator addRequest = container.getMessage();
+        AddRequest addRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -84,7 +86,15 @@ public class AddAddRequestAttributeType extends GrammarAction<LdapMessageContain
 
         try
         {
-            addRequest.addAttributeType( type );
+            Attribute attribute = addRequest.getEntry().get( type );
+            
+            if ( attribute == null )
+            {
+                attribute = new DefaultAttribute( type );
+                addRequest.getEntry().add( attribute );
+            }
+            
+            container.setCurrentAttribute( attribute );
         }
         catch ( LdapException ne )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAttributeValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAttributeValue.java
index f4a4178..f45bbc3 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAttributeValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/AddAttributeValue.java
@@ -23,9 +23,10 @@ package org.apache.directory.api.ldap.codec.actions.request.add;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.AddRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.entry.Attribute;
 import org.apache.directory.api.ldap.model.exception.LdapException;
+import org.apache.directory.api.ldap.model.message.AddRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -42,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AddAttributeValue extends GrammarAction<LdapMessageContainer<AddRequestDecorator>>
+public class AddAttributeValue extends GrammarAction<LdapMessageContainerDirect<AddRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( AddAttributeValue.class );
@@ -60,9 +61,9 @@ public class AddAttributeValue extends GrammarAction<LdapMessageContainer<AddReq
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AddRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<AddRequest> container )
     {
-        AddRequestDecorator addRequest = container.getMessage();
+        Attribute currentAttribute = container.getCurrentAttribute();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -73,11 +74,11 @@ public class AddAttributeValue extends GrammarAction<LdapMessageContainer<AddReq
         {
             if ( tlv.getLength() == 0 )
             {
-                addRequest.addAttributeValue( "" );
+                currentAttribute.add( "" );
             }
             else
             {
-                if ( container.isBinary( addRequest.getCurrentAttributeType() ) )
+                if ( container.isBinary( currentAttribute.getId() ) )
                 {
                     value = tlv.getValue().getData();
 
@@ -86,7 +87,7 @@ public class AddAttributeValue extends GrammarAction<LdapMessageContainer<AddReq
                         LOG.debug( I18n.msg( I18n.MSG_05112_ADDING_VALUE, Strings.dumpBytes( ( byte[] ) value ) ) );
                     }
 
-                    addRequest.addAttributeValue( ( byte[] ) value );
+                    currentAttribute.add( ( byte[] ) value );
                 }
                 else
                 {
@@ -97,7 +98,7 @@ public class AddAttributeValue extends GrammarAction<LdapMessageContainer<AddReq
                         LOG.debug( I18n.msg( I18n.MSG_05112_ADDING_VALUE, value ) );
                     }
 
-                    addRequest.addAttributeValue( ( String ) value );
+                    currentAttribute.add( ( String ) value );
                 }
             }
         }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/InitAddRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/InitAddRequest.java
index 7e73d26..7ff391f 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/InitAddRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/InitAddRequest.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.AddRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.AddRequest;
 import org.apache.directory.api.ldap.model.message.AddRequestImpl;
 import org.slf4j.Logger;
@@ -40,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAddRequest extends GrammarAction<LdapMessageContainer<AddRequestDecorator>>
+public class InitAddRequest extends GrammarAction<LdapMessageContainerDirect<AddRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAddRequest.class );
@@ -59,14 +58,12 @@ public class InitAddRequest extends GrammarAction<LdapMessageContainer<AddReques
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AddRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<AddRequest> container ) throws DecoderException
     {
         // Now, we can allocate the AddRequest Object
         int messageId = container.getMessageId();
-        AddRequest internalAddRequest = new AddRequestImpl();
-        internalAddRequest.setMessageId( messageId );
-        AddRequestDecorator addRequest = new AddRequestDecorator(
-            container.getLdapCodecService(), internalAddRequest );
+        AddRequest addRequest = new AddRequestImpl();
+        addRequest.setMessageId( messageId );
         container.setMessage( addRequest );
 
         // We will check that the request is not null
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/StoreAddRequestEntryName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/StoreAddRequestEntryName.java
index ba9b4c5..b193269 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/StoreAddRequestEntryName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/add/StoreAddRequestEntryName.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.AddRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
+import org.apache.directory.api.ldap.model.message.AddRequest;
 import org.apache.directory.api.ldap.model.message.AddResponseImpl;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
 import org.apache.directory.api.ldap.model.name.Dn;
@@ -45,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreAddRequestEntryName extends GrammarAction<LdapMessageContainer<AddRequestDecorator>>
+public class StoreAddRequestEntryName extends GrammarAction<LdapMessageContainerDirect<AddRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreAddRequestEntryName.class );
@@ -64,9 +64,9 @@ public class StoreAddRequestEntryName extends GrammarAction<LdapMessageContainer
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<AddRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<AddRequest> container ) throws DecoderException
     {
-        AddRequestDecorator addRequest = container.getMessage();
+        AddRequest addRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -85,13 +85,13 @@ public class StoreAddRequestEntryName extends GrammarAction<LdapMessageContainer
         }
         else
         {
-            Dn entryDn = null;
             byte[] dnBytes = tlv.getValue().getData();
             String dnStr = Strings.utf8ToString( dnBytes );
 
             try
             {
-                entryDn = new Dn( dnStr );
+                Dn entryDn = new Dn( dnStr );
+                addRequest.setEntryDn( entryDn );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -103,7 +103,6 @@ public class StoreAddRequestEntryName extends GrammarAction<LdapMessageContainer
                     Dn.EMPTY_DN, ine );
             }
 
-            addRequest.setEntryDn( entryDn );
         }
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitBindRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitBindRequest.java
index 7ec34b9..00bdd9b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitBindRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitBindRequest.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.ldap.model.message.BindRequestImpl;
 import org.slf4j.Logger;
@@ -40,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitBindRequest extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class InitBindRequest extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitBindRequest.class );
@@ -59,13 +58,11 @@ public class InitBindRequest extends GrammarAction<LdapMessageContainer<BindRequ
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<BindRequest> container ) throws DecoderException
     {
         // Create the BindRequest LdapMessage instance and store it in the container
-        BindRequest internalBindRequest = new BindRequestImpl();
-        internalBindRequest.setMessageId( container.getMessageId() );
-        BindRequestDecorator bindRequest = new BindRequestDecorator(
-            container.getLdapCodecService(), internalBindRequest );
+        BindRequest bindRequest = new BindRequestImpl();
+        bindRequest.setMessageId( container.getMessageId() );
         container.setMessage( bindRequest );
 
         // We will check that the request is not null
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitSaslBind.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitSaslBind.java
index 00fced8..eeaba4b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitSaslBind.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/InitSaslBind.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.ldap.model.message.BindResponseImpl;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
@@ -51,7 +50,7 @@ import org.slf4j.LoggerFactory;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSaslBind extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class InitSaslBind extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitSaslBind.class );
@@ -69,7 +68,7 @@ public class InitSaslBind extends GrammarAction<LdapMessageContainer<BindRequest
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<BindRequest> container ) throws DecoderException
     {
         BindRequest bindRequestMessage = container.getMessage();
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreName.java
index 57212d6..6c13f1d 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreName.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.request.bind;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -41,7 +40,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreName extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class StoreName extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreName.class );
@@ -59,7 +58,7 @@ public class StoreName extends GrammarAction<LdapMessageContainer<BindRequestDec
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<BindRequest> container )
     {
         BindRequest bindRequestMessage = container.getMessage();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslCredentials.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslCredentials.java
index 3b3fd96..ce54b10 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslCredentials.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslCredentials.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.request.bind;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -40,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSaslCredentials extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class StoreSaslCredentials extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSaslCredentials.class );
@@ -58,7 +57,7 @@ public class StoreSaslCredentials extends GrammarAction<LdapMessageContainer<Bin
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<BindRequest> container )
     {
         BindRequest bindRequestMessage = container.getMessage();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslMechanism.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslMechanism.java
index 292bdbc..044e168 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslMechanism.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSaslMechanism.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.request.bind;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -40,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSaslMechanism extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class StoreSaslMechanism extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSaslMechanism.class );
@@ -58,7 +57,7 @@ public class StoreSaslMechanism extends GrammarAction<LdapMessageContainer<BindR
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<BindRequest> container )
     {
         BindRequest bindRequestMessage = container.getMessage();
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSimpleAuth.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSimpleAuth.java
index 901fe97..dfaf714 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSimpleAuth.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreSimpleAuth.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.request.bind;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSimpleAuth extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class StoreSimpleAuth extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSimpleAuth.class );
@@ -64,7 +63,7 @@ public class StoreSimpleAuth extends GrammarAction<LdapMessageContainer<BindRequ
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<BindRequest> container )
     {
         BindRequest bindRequestMessage = container.getMessage();
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreVersion.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreVersion.java
index 2ec8d64..b8a2207 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreVersion.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/bind/StoreVersion.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoder;
 import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -44,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreVersion extends GrammarAction<LdapMessageContainer<BindRequestDecorator>>
+public class StoreVersion extends GrammarAction<LdapMessageContainerDirect<BindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreVersion.class );
@@ -62,7 +61,7 @@ public class StoreVersion extends GrammarAction<LdapMessageContainer<BindRequest
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<BindRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<BindRequest> container ) throws DecoderException
     {
         BindRequest bindRequestMessage = container.getMessage();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/InitCompareRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/InitCompareRequest.java
index fb12921..90dcf56 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/InitCompareRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/InitCompareRequest.java
@@ -22,8 +22,7 @@ package org.apache.directory.api.ldap.codec.actions.request.compare;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.CompareRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.CompareRequest;
 import org.apache.directory.api.ldap.model.message.CompareRequestImpl;
 import org.slf4j.Logger;
@@ -40,12 +39,11 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitCompareRequest extends GrammarAction<LdapMessageContainer<CompareRequestDecorator>>
+public class InitCompareRequest extends GrammarAction<LdapMessageContainerDirect<CompareRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitCompareRequest.class );
 
-
     /**
      * Instantiates a new action.
      */
@@ -59,13 +57,11 @@ public class InitCompareRequest extends GrammarAction<LdapMessageContainer<Compa
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<CompareRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<CompareRequest> container )
     {
         // Now, we can allocate the CompareRequest Object
-        CompareRequest internalCompareRequest = new CompareRequestImpl();
-        internalCompareRequest.setMessageId( container.getMessageId() );
-        CompareRequestDecorator compareRequest = new CompareRequestDecorator(
-            container.getLdapCodecService(), internalCompareRequest );
+        CompareRequest compareRequest = new CompareRequestImpl();
+        compareRequest.setMessageId( container.getMessageId() );
         container.setMessage( compareRequest );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAssertionValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAssertionValue.java
index 84e9373..8f108e4 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAssertionValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAssertionValue.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.request.compare;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.CompareRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.CompareRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreCompareRequestAssertionValue extends GrammarAction<LdapMessageContainer<CompareRequestDecorator>>
+public class StoreCompareRequestAssertionValue extends GrammarAction<LdapMessageContainerDirect<CompareRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreCompareRequestAssertionValue.class );
@@ -64,7 +63,7 @@ public class StoreCompareRequestAssertionValue extends GrammarAction<LdapMessage
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<CompareRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<CompareRequest> container )
     {
         // Get the CompareRequest Object
         CompareRequest compareRequest = container.getMessage();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAttributeDesc.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAttributeDesc.java
index b7b8447..0ae4131 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAttributeDesc.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestAttributeDesc.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.CompareRequestDecorator;
 import org.apache.directory.api.ldap.model.message.CompareRequest;
 import org.apache.directory.api.ldap.model.message.CompareResponseImpl;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
@@ -48,7 +47,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreCompareRequestAttributeDesc extends GrammarAction<LdapMessageContainer<CompareRequestDecorator>>
+public class StoreCompareRequestAttributeDesc extends GrammarAction<LdapMessageContainerDirect<CompareRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreCompareRequestAttributeDesc.class );
@@ -66,7 +65,7 @@ public class StoreCompareRequestAttributeDesc extends GrammarAction<LdapMessageC
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<CompareRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<CompareRequest> container ) throws DecoderException
     {
         // Get the CompareRequest Object
         CompareRequest compareRequest = container.getMessage();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestEntryName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestEntryName.java
index 88c3c89..c043369 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestEntryName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/compare/StoreCompareRequestEntryName.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.CompareRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.CompareRequest;
 import org.apache.directory.api.ldap.model.message.CompareResponseImpl;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreCompareRequestEntryName extends GrammarAction<LdapMessageContainer<CompareRequestDecorator>>
+public class StoreCompareRequestEntryName extends GrammarAction<LdapMessageContainerDirect<CompareRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreCompareRequestEntryName.class );
@@ -64,16 +63,14 @@ public class StoreCompareRequestEntryName extends GrammarAction<LdapMessageConta
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<CompareRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<CompareRequest> container ) throws DecoderException
     {
         CompareRequest compareRequest = container.getMessage();
 
         // Get the Value and store it in the CompareRequest
         TLV tlv = container.getCurrentTLV();
-        Dn entry;
 
-        // We have to handle the special case of a 0 length matched
-        // Dn
+        // We have to handle the special case of a 0 length matched Dn
         if ( tlv.getLength() == 0 )
         {
             // This will generate a PROTOCOL_ERROR
@@ -86,7 +83,8 @@ public class StoreCompareRequestEntryName extends GrammarAction<LdapMessageConta
 
             try
             {
-                entry = new Dn( dnStr );
+                Dn entry = new Dn( dnStr );
+                compareRequest.setName( entry );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -97,13 +95,11 @@ public class StoreCompareRequestEntryName extends GrammarAction<LdapMessageConta
                 throw new ResponseCarryingException( msg, response, ResultCodeEnum.INVALID_DN_SYNTAX,
                     Dn.EMPTY_DN, ine );
             }
-
-            compareRequest.setName( entry );
         }
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05123_COMPARING_DN, entry ) );
+            LOG.debug( I18n.msg( I18n.MSG_05123_COMPARING_DN, compareRequest.getName() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/del/InitDelRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/del/InitDelRequest.java
index 4b776e4..a18a03c 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/del/InitDelRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/del/InitDelRequest.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.DeleteRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.DeleteRequest;
 import org.apache.directory.api.ldap.model.message.DeleteRequestImpl;
@@ -48,7 +47,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitDelRequest extends GrammarAction<LdapMessageContainer<DeleteRequestDecorator>>
+public class InitDelRequest extends GrammarAction<LdapMessageContainerDirect<DeleteRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitDelRequest.class );
@@ -66,23 +65,18 @@ public class InitDelRequest extends GrammarAction<LdapMessageContainer<DeleteReq
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<DeleteRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<DeleteRequest> container ) throws DecoderException
     {
         // Create the DeleteRequest LdapMessage instance and store it in the container
-        DeleteRequest internaldelRequest = new DeleteRequestImpl();
-        internaldelRequest.setMessageId( container.getMessageId() );
-        DeleteRequestDecorator delRequest = new DeleteRequestDecorator(
-            container.getLdapCodecService(), internaldelRequest );
+        DeleteRequest delRequest = new DeleteRequestImpl();
+        delRequest.setMessageId( container.getMessageId() );
         container.setMessage( delRequest );
 
         // And store the Dn into it
         // Get the Value and store it in the DelRequest
         TLV tlv = container.getCurrentTLV();
 
-        // We have to handle the special case of a 0 length matched
-        // Dn
-        Dn entry;
-
+        // We have to handle the special case of a 0 length matchedDN
         if ( tlv.getLength() == 0 )
         {
             // This will generate a PROTOCOL_ERROR
@@ -95,28 +89,27 @@ public class InitDelRequest extends GrammarAction<LdapMessageContainer<DeleteReq
 
             try
             {
-                entry = new Dn( dnStr );
+                Dn entry = new Dn( dnStr );
+                delRequest.setName( entry );
             }
             catch ( LdapInvalidDnException ine )
             {
-                String msg = I18n.err( I18n.ERR_05120_INVALID_DELETE_DN, dnStr, Strings.dumpBytes( dnBytes ), ine
-                    .getLocalizedMessage() );
+                String msg = I18n.err( I18n.ERR_05120_INVALID_DELETE_DN, dnStr, 
+                    Strings.dumpBytes( dnBytes ), ine.getLocalizedMessage() );
                 LOG.error( msg );
 
                 DeleteResponseImpl response = new DeleteResponseImpl( delRequest.getMessageId() );
                 throw new ResponseCarryingException( msg, response, ResultCodeEnum.INVALID_DN_SYNTAX,
                     Dn.EMPTY_DN, ine );
             }
-
-            delRequest.setName( entry );
         }
 
-        // We can have an END transition
-        container.setGrammarEndAllowed( true );
-
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05124_DELETING_DN, entry ) );
+            LOG.debug( I18n.msg( I18n.MSG_05124_DELETING_DN, delRequest.getName() ) );
         }
+
+        // We can have an END transition
+        container.setGrammarEndAllowed( true );
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/InitExtendedRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/InitExtendedRequest.java
index 39b0b49..c80e225 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/InitExtendedRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/InitExtendedRequest.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.request.extended;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.ExtendedRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitExtendedRequest extends GrammarAction<LdapMessageContainer<ExtendedRequestDecorator<?>>>
+public class InitExtendedRequest extends GrammarAction<LdapMessageContainerDirect<ExtendedRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitExtendedRequest.class );
@@ -55,7 +55,7 @@ public class InitExtendedRequest extends GrammarAction<LdapMessageContainer<Exte
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ExtendedRequestDecorator<?>> container )
+    public void action( LdapMessageContainerDirect<ExtendedRequest> container )
     {
         /*
          * It is the responsibility of the LdapCodecService to instantiate new
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestName.java
index 68497ef..ce67751 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestName.java
@@ -25,9 +25,11 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.asn1.util.Oid;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.ExtendedOperationFactory;
+import org.apache.directory.api.ldap.codec.api.LdapApiService;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.ExtendedRequest;
+import org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -42,7 +44,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreExtendedRequestName extends GrammarAction<LdapMessageContainer<ExtendedRequestDecorator<?>>>
+public class StoreExtendedRequestName extends GrammarAction<LdapMessageContainerDirect<ExtendedRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreExtendedRequestName.class );
@@ -60,11 +62,12 @@ public class StoreExtendedRequestName extends GrammarAction<LdapMessageContainer
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ExtendedRequestDecorator<?>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ExtendedRequest> container ) throws DecoderException
     {
-        ExtendedRequest req;
-
-        // Get the Value and store it in the ExtendedRequest
+        // Get the Name and store it in the ExtendedRequest. That will
+        // allow us to find the proper extended request instance, if it's 
+        // already declared. Otherwise, we will use a default ExtendedRequest
+        // in which the value will be stored un-decoded.
         TLV tlv = container.getCurrentTLV();
 
         // We have to handle the special case of a 0 length matched
@@ -79,30 +82,49 @@ public class StoreExtendedRequestName extends GrammarAction<LdapMessageContainer
         else
         {
             byte[] requestNameBytes = tlv.getValue().getData();
+            String requestName = Strings.utf8ToString( requestNameBytes );
 
             try
             {
-                String requestName = Strings.utf8ToString( requestNameBytes );
-
+                // Check the OID first, if it's invalid, reject the operation
                 if ( !Oid.isOid( requestName ) )
                 {
-
                     String msg = I18n.err( I18n.ERR_05121_INVALID_REQUEST_NAME_OID,
-                        Strings.utf8ToString( requestNameBytes ), Strings.dumpBytes( requestNameBytes ) );
+                        requestName, Strings.dumpBytes( requestNameBytes ) );
                     LOG.error( msg );
 
                     // throw an exception, we will get a PROTOCOL_ERROR
                     throw new DecoderException( msg );
                 }
 
-                req = container.getLdapCodecService().newExtendedRequest( requestName, null );
-                req.setMessageId( container.getMessageId() );
-                container.setMessage( container.getLdapCodecService().decorate( req ) );
+                // Get the extended request factory from the LdapApiService, if it's registered
+                LdapApiService codec = container.getLdapCodecService();
+                ExtendedOperationFactory factory = codec.getExtendedRequestFactories().get( requestName );
+                ExtendedRequest extendedRequest;
+                
+                if ( factory == null )
+                {
+                    // Create a default extended request operation
+                    extendedRequest = new OpaqueExtendedRequest();
+                }
+                else
+                {
+                    // Create the extended request
+                    extendedRequest = factory.newRequest();
+                }
+
+                extendedRequest.setMessageId( container.getMessageId() );
+                container.setMessage( extendedRequest );
+
+                if ( LOG.isDebugEnabled() )
+                {
+                    LOG.debug( I18n.msg( I18n.MSG_05126_OID_READ, extendedRequest.getRequestName() ) );
+                }
             }
             catch ( DecoderException de )
             {
                 String msg = I18n.err( I18n.ERR_05121_INVALID_REQUEST_NAME_OID,
-                    Strings.utf8ToString( requestNameBytes ), Strings.dumpBytes( requestNameBytes ) );
+                    requestName, Strings.dumpBytes( requestNameBytes ) );
                 LOG.error( I18n.err( I18n.ERR_05114_ERROR_MESSAGE, msg, de.getMessage() ) );
 
                 // Rethrow the exception, we will get a PROTOCOL_ERROR
@@ -112,10 +134,5 @@ public class StoreExtendedRequestName extends GrammarAction<LdapMessageContainer
 
         // We can have an END transition
         container.setGrammarEndAllowed( true );
-
-        if ( LOG.isDebugEnabled() )
-        {
-            LOG.debug( I18n.msg( I18n.MSG_05126_OID_READ, req.getRequestName() ) );
-        }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestValue.java
index 71168ee..e764867 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/extended/StoreExtendedRequestValue.java
@@ -20,11 +20,14 @@
 package org.apache.directory.api.ldap.codec.actions.request.extended;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.ExtendedOperationFactory;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.ExtendedRequest;
+import org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -39,7 +42,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreExtendedRequestValue extends GrammarAction<LdapMessageContainer<ExtendedRequestDecorator<?>>>
+public class StoreExtendedRequestValue extends GrammarAction<LdapMessageContainerDirect<ExtendedRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreExtendedRequestValue.class );
@@ -57,23 +60,45 @@ public class StoreExtendedRequestValue extends GrammarAction<LdapMessageContaine
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ExtendedRequestDecorator<?>> container )
+    public void action( LdapMessageContainerDirect<ExtendedRequest> container ) throws DecoderException
     {
         // We can allocate the ExtendedRequest Object
-        ExtendedRequestDecorator<?> extendedRequest = container.getMessage();
+        ExtendedRequest extendedRequest = container.getMessage();
 
         // Get the Value and store it in the ExtendedRequest
         TLV tlv = container.getCurrentTLV();
+        
+        ExtendedOperationFactory factory = container.getLdapCodecService().
+            getExtendedRequestFactories().get( extendedRequest.getRequestName() );
 
         // We have to handle the special case of a 0 length matched
         // value
-        if ( tlv.getLength() == 0 )
+        try
         {
-            extendedRequest.setRequestValue( Strings.EMPTY_BYTES );
+            if ( factory == null )
+            {
+                if ( tlv.getLength() == 0 )
+                {
+                    ( ( OpaqueExtendedRequest ) extendedRequest ).setRequestValue( Strings.EMPTY_BYTES );
+                } 
+                else
+                {
+                    ( ( OpaqueExtendedRequest ) extendedRequest ).setRequestValue( tlv.getValue().getData() );
+                }
+            }
+            else
+            {
+                factory.decodeValue( extendedRequest, tlv.getValue().getData() );
+            }
         }
-        else
+        catch ( DecoderException de )
         {
-            extendedRequest.setRequestValue( tlv.getValue().getData() );
+            String msg = I18n.err( I18n.ERR_05158_INVALID_REQUEST_VALUE,
+                Strings.dumpBytes( tlv.getValue().getData() ) );
+            LOG.error( I18n.err( I18n.ERR_05114_ERROR_MESSAGE, msg, de.getMessage() ) );
+
+            // Rethrow the exception, we will get a PROTOCOL_ERROR
+            throw de;
         }
 
         // We can have an END transition
@@ -81,7 +106,8 @@ public class StoreExtendedRequestValue extends GrammarAction<LdapMessageContaine
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05127_EXTENDED_VALUE, extendedRequest.getRequestValue() ) );
+            LOG.debug( I18n.msg( I18n.MSG_05127_EXTENDED_VALUE, 
+                Strings.dumpBytes( tlv.getValue().getData() ) ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/AddModifyRequestAttribute.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/AddModifyRequestAttribute.java
index df6abd5..1387439 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/AddModifyRequestAttribute.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/AddModifyRequestAttribute.java
@@ -24,9 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
+import org.apache.directory.api.ldap.model.entry.Attribute;
+import org.apache.directory.api.ldap.model.entry.DefaultAttribute;
 import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.apache.directory.api.ldap.model.message.ModifyResponseImpl;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
@@ -50,7 +51,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AddModifyRequestAttribute extends GrammarAction<LdapMessageContainer<ModifyRequestDecorator>>
+public class AddModifyRequestAttribute extends GrammarAction<LdapMessageContainerDirect<ModifyRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( AddModifyRequestAttribute.class );
@@ -68,10 +69,9 @@ public class AddModifyRequestAttribute extends GrammarAction<LdapMessageContaine
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyRequest> container ) throws DecoderException
     {
-        ModifyRequestDecorator modifyRequestDecorator = container.getMessage();
-        ModifyRequest modifyRequest = modifyRequestDecorator.getDecorated();
+        ModifyRequest modifyRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -90,7 +90,9 @@ public class AddModifyRequestAttribute extends GrammarAction<LdapMessageContaine
         else
         {
             type = Strings.utf8ToString( tlv.getValue().getData() );
-            modifyRequestDecorator.addAttributeTypeAndValues( type );
+            Attribute currentAttribute = new DefaultAttribute( type );
+            container.setCurrentAttribute( currentAttribute );
+            container.getCurrentModification().setAttribute( currentAttribute );
         }
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitAttributeVals.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitAttributeVals.java
index 6db6ebd..d0f1805 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitAttributeVals.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitAttributeVals.java
@@ -23,8 +23,8 @@ package org.apache.directory.api.ldap.codec.actions.request.modify;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAttributeVals extends GrammarAction<LdapMessageContainer<ModifyRequestDecorator>>
+public class InitAttributeVals extends GrammarAction<LdapMessageContainerDirect<ModifyRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAttributeVals.class );
@@ -63,7 +63,7 @@ public class InitAttributeVals extends GrammarAction<LdapMessageContainer<Modify
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<ModifyRequest> container )
     {
         TLV tlv = container.getCurrentTLV();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitModifyRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitModifyRequest.java
index 4129e75..8d10610 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitModifyRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/InitModifyRequest.java
@@ -21,10 +21,12 @@ package org.apache.directory.api.ldap.codec.actions.request.modify;
 
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
+import org.apache.directory.api.i18n.I18n;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.apache.directory.api.ldap.model.message.ModifyRequestImpl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 
 /**
@@ -35,9 +37,11 @@ import org.apache.directory.api.ldap.model.message.ModifyRequestImpl;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitModifyRequest extends GrammarAction<LdapMessageContainer<ModifyRequestDecorator>>
+public class InitModifyRequest extends GrammarAction<LdapMessageContainerDirect<ModifyRequest>>
 {
-    /**
+    /** The logger */
+    private static final Logger LOG = LoggerFactory.getLogger( InitModifyRequest.class );
+   /**
      * Instantiates a new action.
      */
     public InitModifyRequest()
@@ -50,13 +54,16 @@ public class InitModifyRequest extends GrammarAction<LdapMessageContainer<Modify
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<ModifyRequest> container )
     {
         // Now, we can allocate the ModifyRequest Object
-        ModifyRequest internalModifyRequest = new ModifyRequestImpl();
-        internalModifyRequest.setMessageId( container.getMessageId() );
-        ModifyRequestDecorator modifyRequestDecorator = new ModifyRequestDecorator(
-            container.getLdapCodecService(), internalModifyRequest );
-        container.setMessage( modifyRequestDecorator );
+        ModifyRequest modifyRequest = new ModifyRequestImpl();
+        modifyRequest.setMessageId( container.getMessageId() );
+        container.setMessage( modifyRequest );
+        
+        if ( LOG.isDebugEnabled() )
+        {
+            LOG.debug( I18n.msg( I18n.MSG_05120_COMPARE_REQUEST ) );
+        }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestAttributeValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestAttributeValue.java
index 18f6834..a8f2fcd 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestAttributeValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestAttributeValue.java
@@ -23,9 +23,10 @@ package org.apache.directory.api.ldap.codec.actions.request.modify;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.entry.Attribute;
 import org.apache.directory.api.ldap.model.exception.LdapException;
+import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -36,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreModifyRequestAttributeValue extends GrammarAction<LdapMessageContainer<ModifyRequestDecorator>>
+public class StoreModifyRequestAttributeValue extends GrammarAction<LdapMessageContainerDirect<ModifyRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreModifyRequestAttributeValue.class );
@@ -54,32 +55,31 @@ public class StoreModifyRequestAttributeValue extends GrammarAction<LdapMessageC
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<ModifyRequest> container )
     {
-        ModifyRequestDecorator modifyRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value. It can't be null
         byte[] value = Strings.EMPTY_BYTES;
+        Attribute currentAttribute = container.getCurrentAttribute();
 
         try
         {
             if ( tlv.getLength() == 0 )
             {
-                modifyRequestDecorator.addAttributeValue( "" );
+                currentAttribute.add( "" );
             }
             else
             {
                 value = tlv.getValue().getData();
 
-                if ( container.isBinary( modifyRequestDecorator.getCurrentAttributeType() ) )
+                if ( container.isBinary( currentAttribute.getId() ) )
                 {
-                    modifyRequestDecorator.addAttributeValue( value );
+                    container.getCurrentAttribute().add( value );
                 }
                 else
                 {
-                    modifyRequestDecorator.addAttributeValue( Strings.utf8ToString( ( byte[] ) value ) );
+                    currentAttribute.add( Strings.utf8ToString( ( byte[] ) value ) );
                 }
             }
         }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestObjectName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestObjectName.java
index db857cb..9ade22e 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestObjectName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreModifyRequestObjectName.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.apache.directory.api.ldap.model.message.ModifyResponseImpl;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreModifyRequestObjectName extends GrammarAction<LdapMessageContainer<ModifyRequestDecorator>>
+public class StoreModifyRequestObjectName extends GrammarAction<LdapMessageContainerDirect<ModifyRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreModifyRequestObjectName.class );
@@ -64,10 +63,9 @@ public class StoreModifyRequestObjectName extends GrammarAction<LdapMessageConta
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyRequest> container ) throws DecoderException
     {
-        ModifyRequestDecorator modifyRequestDecorator = container.getMessage();
-        ModifyRequest modifyRequest = modifyRequestDecorator.getDecorated();
+        ModifyRequest modifyRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -76,7 +74,7 @@ public class StoreModifyRequestObjectName extends GrammarAction<LdapMessageConta
         // Store the value.
         if ( tlv.getLength() == 0 )
         {
-            ( modifyRequestDecorator.getDecorated() ).setName( object );
+            modifyRequest.setName( object );
         }
         else
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreOperationType.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreOperationType.java
index 12bd997..75afb8b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreOperationType.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modify/StoreOperationType.java
@@ -27,8 +27,10 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.entry.DefaultModification;
+import org.apache.directory.api.ldap.model.entry.Modification;
+import org.apache.directory.api.ldap.model.message.ModifyRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -45,7 +47,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreOperationType extends GrammarAction<LdapMessageContainer<ModifyRequestDecorator>>
+public class StoreOperationType extends GrammarAction<LdapMessageContainerDirect<ModifyRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreOperationType.class );
@@ -63,10 +65,9 @@ public class StoreOperationType extends GrammarAction<LdapMessageContainer<Modif
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyRequest> container ) throws DecoderException
     {
-        ModifyRequestDecorator modifyRequestDecorator = container.getMessage();
-
+        ModifyRequest modifyRequest = container.getMessage();
         TLV tlv = container.getCurrentTLV();
 
         // Decode the operation type
@@ -74,7 +75,12 @@ public class StoreOperationType extends GrammarAction<LdapMessageContainer<Modif
 
         try
         {
+            // Store the current operation.
             operation = IntegerDecoder.parse( tlv.getValue(), 0, 2 );
+            Modification modification = new DefaultModification();
+            modification.setOperation( operation );
+            modifyRequest.addModification( modification );
+            container.setCurrentModification( modification );
         }
         catch ( IntegerDecoderException ide )
         {
@@ -85,9 +91,6 @@ public class StoreOperationType extends GrammarAction<LdapMessageContainer<Modif
             throw new DecoderException( msg, ide );
         }
 
-        // Store the current operation.
-        modifyRequestDecorator.setCurrentOperation( operation );
-
         if ( LOG.isDebugEnabled() )
         {
             switch ( operation )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/InitModifyDnRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/InitModifyDnRequest.java
index 4602308..c53e657 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/InitModifyDnRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/InitModifyDnRequest.java
@@ -22,8 +22,7 @@ package org.apache.directory.api.ldap.codec.actions.request.modifydn;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequest;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequestImpl;
 import org.slf4j.Logger;
@@ -38,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitModifyDnRequest extends GrammarAction<LdapMessageContainer<ModifyDnRequestDecorator>>
+public class InitModifyDnRequest extends GrammarAction<LdapMessageContainerDirect<ModifyDnRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitModifyDnRequest.class );
@@ -57,13 +56,11 @@ public class InitModifyDnRequest extends GrammarAction<LdapMessageContainer<Modi
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyDnRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<ModifyDnRequest> container )
     {
         // Now, we can allocate the ModifyDNRequest Object
-        ModifyDnRequest internalModifyDnRequest = new ModifyDnRequestImpl();
-        internalModifyDnRequest.setMessageId( container.getMessageId() );
-        ModifyDnRequestDecorator modifyDnRequest = new ModifyDnRequestDecorator(
-            container.getLdapCodecService(), internalModifyDnRequest );
+        ModifyDnRequest modifyDnRequest = new ModifyDnRequestImpl();
+        modifyDnRequest.setMessageId( container.getMessageId() );
         container.setMessage( modifyDnRequest );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestDeleteOldRdn.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestDeleteOldRdn.java
index 897ee9c..5d23a4b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestDeleteOldRdn.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestDeleteOldRdn.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.BooleanDecoder;
 import org.apache.directory.api.asn1.ber.tlv.BooleanDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -45,7 +44,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreModifyDnRequestDeleteOldRdn extends GrammarAction<LdapMessageContainer<ModifyDnRequestDecorator>>
+public class StoreModifyDnRequestDeleteOldRdn extends GrammarAction<LdapMessageContainerDirect<ModifyDnRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreModifyDnRequestDeleteOldRdn.class );
@@ -63,7 +62,7 @@ public class StoreModifyDnRequestDeleteOldRdn extends GrammarAction<LdapMessageC
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyDnRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyDnRequest> container ) throws DecoderException
     {
         ModifyDnRequest modifyDnRequest = container.getMessage();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestEntryName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestEntryName.java
index dd36898..a225d2f 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestEntryName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestEntryName.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequest;
 import org.apache.directory.api.ldap.model.message.ModifyDnResponseImpl;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreModifyDnRequestEntryName extends GrammarAction<LdapMessageContainer<ModifyDnRequestDecorator>>
+public class StoreModifyDnRequestEntryName extends GrammarAction<LdapMessageContainerDirect<ModifyDnRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreModifyDnRequestEntryName.class );
@@ -64,17 +63,14 @@ public class StoreModifyDnRequestEntryName extends GrammarAction<LdapMessageCont
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyDnRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyDnRequest> container ) throws DecoderException
     {
         ModifyDnRequest modifyDnRequest = container.getMessage();
 
         // Get the Value and store it in the modifyDNRequest
         TLV tlv = container.getCurrentTLV();
 
-        // We have to handle the special case of a 0 length matched
-        // Dn
-        Dn entry;
-
+        // We have to handle the special case of a 0 length matched DN
         if ( tlv.getLength() == 0 )
         {
             // This will generate a PROTOCOL_ERROR
@@ -87,7 +83,8 @@ public class StoreModifyDnRequestEntryName extends GrammarAction<LdapMessageCont
 
             try
             {
-                entry = new Dn( dnStr );
+                Dn entry = new Dn( dnStr );
+                modifyDnRequest.setName( entry );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -98,13 +95,11 @@ public class StoreModifyDnRequestEntryName extends GrammarAction<LdapMessageCont
                 throw new ResponseCarryingException( msg, response, ResultCodeEnum.INVALID_DN_SYNTAX,
                     Dn.EMPTY_DN, ine );
             }
-
-            modifyDnRequest.setName( entry );
         }
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05137_MODIFYING_DN, entry ) );
+            LOG.debug( I18n.msg( I18n.MSG_05137_MODIFYING_DN, modifyDnRequest.getName() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewRdn.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewRdn.java
index eabb5c0..090f166 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewRdn.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewRdn.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequest;
 import org.apache.directory.api.ldap.model.message.ModifyDnResponseImpl;
@@ -50,7 +49,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreModifyDnRequestNewRdn extends GrammarAction<LdapMessageContainer<ModifyDnRequestDecorator>>
+public class StoreModifyDnRequestNewRdn extends GrammarAction<LdapMessageContainerDirect<ModifyDnRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreModifyDnRequestNewRdn.class );
@@ -68,7 +67,7 @@ public class StoreModifyDnRequestNewRdn extends GrammarAction<LdapMessageContain
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyDnRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyDnRequest> container ) throws DecoderException
     {
         ModifyDnRequest modifyDnRequest = container.getMessage();
 
@@ -77,8 +76,6 @@ public class StoreModifyDnRequestNewRdn extends GrammarAction<LdapMessageContain
 
         // We have to handle the special case of a 0 length matched
         // newDN
-        Rdn newRdn;
-
         if ( tlv.getLength() == 0 )
         {
             String msg = I18n.err( I18n.ERR_05126_RDN_MUST_NOT_BE_NULL );
@@ -96,7 +93,8 @@ public class StoreModifyDnRequestNewRdn extends GrammarAction<LdapMessageContain
             try
             {
                 Dn dn = new Dn( dnStr );
-                newRdn = dn.getRdn( dn.size() - 1 );
+                Rdn newRdn = dn.getRdn( dn.size() - 1 );
+                modifyDnRequest.setNewRdn( newRdn );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -107,13 +105,11 @@ public class StoreModifyDnRequestNewRdn extends GrammarAction<LdapMessageContain
                 throw new ResponseCarryingException( msg, response, ResultCodeEnum.INVALID_DN_SYNTAX,
                     modifyDnRequest.getName(), ine );
             }
-
-            modifyDnRequest.setNewRdn( newRdn );
         }
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05138_MODIFYING_WITH_NEW_RDN, newRdn ) );
+            LOG.debug( I18n.msg( I18n.MSG_05138_MODIFYING_WITH_NEW_RDN, modifyDnRequest.getNewRdn() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewSuperior.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewSuperior.java
index 3eb4345..c3f9568 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewSuperior.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/modifydn/StoreModifyDnRequestNewSuperior.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.ModifyDnRequest;
 import org.apache.directory.api.ldap.model.message.ModifyDnResponseImpl;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageContainer<ModifyDnRequestDecorator>>
+public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageContainerDirect<ModifyDnRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreModifyDnRequestNewSuperior.class );
@@ -64,7 +63,7 @@ public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageCo
      * {@inheritDoc}
      */
     @Override
-    public void action( LdapMessageContainer<ModifyDnRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ModifyDnRequest> container ) throws DecoderException
     {
         ModifyDnRequest modifyDnRequest = container.getMessage();
 
@@ -73,8 +72,6 @@ public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageCo
 
         // We have to handle the special case of a 0 length matched
         // Dn
-        Dn newSuperior = Dn.EMPTY_DN;
-
         if ( tlv.getLength() == 0 )
         {
 
@@ -91,7 +88,7 @@ public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageCo
                 }
             }
 
-            modifyDnRequest.setNewSuperior( newSuperior );
+            modifyDnRequest.setNewSuperior( Dn.EMPTY_DN );
         }
         else
         {
@@ -100,7 +97,8 @@ public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageCo
 
             try
             {
-                newSuperior = new Dn( dnStr );
+                Dn newSuperior = new Dn( dnStr );
+                modifyDnRequest.setNewSuperior( newSuperior );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -111,8 +109,6 @@ public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageCo
                 throw new ResponseCarryingException( msg, response, ResultCodeEnum.INVALID_DN_SYNTAX,
                     modifyDnRequest.getName(), ine );
             }
-
-            modifyDnRequest.setNewSuperior( newSuperior );
         }
 
         // We can have an END transition
@@ -120,7 +116,7 @@ public class StoreModifyDnRequestNewSuperior extends GrammarAction<LdapMessageCo
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05140_NEW_SUPERIOR_DN, newSuperior ) );
+            LOG.debug( I18n.msg( I18n.MSG_05140_NEW_SUPERIOR_DN, modifyDnRequest.getNewSuperior() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequest.java
index a4ba3d6..df08154 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequest.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.request.search;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.ldap.model.message.SearchRequestImpl;
 import org.slf4j.Logger;
@@ -39,7 +38,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSearchRequest extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitSearchRequest extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitSearchRequest.class );
@@ -57,17 +56,14 @@ public class InitSearchRequest extends GrammarAction<LdapMessageContainer<Search
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchRequest> container )
     {
         // Now, we can allocate the SearchRequest Object
         TLV tlv = container.getCurrentTLV();
 
-        SearchRequest internalSearchRequest = new SearchRequestImpl();
-        internalSearchRequest.setMessageId( container.getMessageId() );
-        SearchRequestDecorator searchRequest = new SearchRequestDecorator(
-            container.getLdapCodecService(), internalSearchRequest );
-
-        searchRequest.setTlvId( tlv.getId() );
+        SearchRequest searchRequest = new SearchRequestImpl();
+        searchRequest.setMessageId( container.getMessageId() );
+        container.setTlvId( tlv.getId() );
         container.setMessage( searchRequest );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequestAttributeDescList.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequestAttributeDescList.java
index 1dbc4ae..374792a 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequestAttributeDescList.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/InitSearchRequestAttributeDescList.java
@@ -20,12 +20,38 @@
 package org.apache.directory.api.ldap.codec.actions.request.search;
 
 
+import java.util.ArrayList;
+import java.util.List;
+
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.AttributeValueAssertion;
+import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.codec.search.AndFilter;
+import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
+import org.apache.directory.api.ldap.codec.search.ConnectorFilter;
+import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
+import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.codec.search.OrFilter;
+import org.apache.directory.api.ldap.codec.search.PresentFilter;
+import org.apache.directory.api.ldap.codec.search.SubstringFilter;
+import org.apache.directory.api.ldap.model.entry.Value;
 import org.apache.directory.api.ldap.model.exception.LdapSchemaException;
+import org.apache.directory.api.ldap.model.filter.AndNode;
+import org.apache.directory.api.ldap.model.filter.ApproximateNode;
+import org.apache.directory.api.ldap.model.filter.BranchNode;
+import org.apache.directory.api.ldap.model.filter.EqualityNode;
+import org.apache.directory.api.ldap.model.filter.ExprNode;
+import org.apache.directory.api.ldap.model.filter.ExtensibleNode;
+import org.apache.directory.api.ldap.model.filter.GreaterEqNode;
+import org.apache.directory.api.ldap.model.filter.LeafNode;
+import org.apache.directory.api.ldap.model.filter.LessEqNode;
+import org.apache.directory.api.ldap.model.filter.NotNode;
+import org.apache.directory.api.ldap.model.filter.OrNode;
+import org.apache.directory.api.ldap.model.filter.PresenceNode;
+import org.apache.directory.api.ldap.model.filter.SubstringNode;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -44,7 +70,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSearchRequestAttributeDescList extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitSearchRequestAttributeDescList extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitSearchRequestAttributeDescList.class );
@@ -59,17 +85,154 @@ public class InitSearchRequestAttributeDescList extends GrammarAction<LdapMessag
 
 
     /**
+     * Transform the Filter part of a SearchRequest to an ExprNode
+     *
+     * @param filter The filter to be transformed
+     * @return An ExprNode
+     * @throws LdapSchemaException If teh filter is invalid
+     */
+    private ExprNode transform( Filter filter ) throws LdapSchemaException
+    {
+        if ( filter != null )
+        {
+            // Transform OR, AND or NOT leaves
+            if ( filter instanceof ConnectorFilter )
+            {
+                BranchNode branch;
+
+                if ( filter instanceof AndFilter )
+                {
+                    branch = new AndNode();
+                }
+                else if ( filter instanceof OrFilter )
+                {
+                    branch = new OrNode();
+                }
+                else
+                {
+                    branch = new NotNode();
+                }
+
+                List<Filter> filtersSet = ( ( ConnectorFilter ) filter ).getFilterSet();
+
+                // Loop on all AND/OR children
+                if ( filtersSet != null )
+                {
+                    for ( Filter node : filtersSet )
+                    {
+                        branch.addNode( transform( node ) );
+                    }
+                }
+
+                return branch;
+            }
+            else
+            {
+                // Transform PRESENT or ATTRIBUTE_VALUE_ASSERTION
+                LeafNode branch = null;
+
+                if ( filter instanceof PresentFilter )
+                {
+                    branch = new PresenceNode( ( ( PresentFilter ) filter ).getAttributeDescription() );
+                }
+                else if ( filter instanceof AttributeValueAssertionFilter )
+                {
+                    AttributeValueAssertion ava = ( ( AttributeValueAssertionFilter ) filter ).getAssertion();
+
+                    // Transform =, >=, <=, ~= filters
+                    int filterType = ( ( AttributeValueAssertionFilter ) filter ).getFilterType();
+                    
+                    switch ( filterType )
+                    {
+                        case LdapCodecConstants.EQUALITY_MATCH_FILTER:
+                            branch = new EqualityNode( ava.getAttributeDesc(), ava.getAssertion() );
+                            break;
+
+                        case LdapCodecConstants.GREATER_OR_EQUAL_FILTER:
+                            branch = new GreaterEqNode( ava.getAttributeDesc(), ava.getAssertion() );
+                            break;
+
+                        case LdapCodecConstants.LESS_OR_EQUAL_FILTER:
+                            branch = new LessEqNode( ava.getAttributeDesc(), ava.getAssertion() );
+                            break;
+
+                        case LdapCodecConstants.APPROX_MATCH_FILTER:
+                            branch = new ApproximateNode( ava.getAttributeDesc(), ava.getAssertion() );
+                            break;
+
+                        default:
+                            throw new IllegalArgumentException( I18n.err( I18n.ERR_05503_UNEXPECTED_FILTER_TYPE, filterType ) );
+                    }
+
+                }
+                else if ( filter instanceof SubstringFilter )
+                {
+                    // Transform Substring filters
+                    SubstringFilter substrFilter = ( SubstringFilter ) filter;
+                    String initialString = null;
+                    String finalString = null;
+                    List<String> anyString = null;
+
+                    if ( substrFilter.getInitialSubstrings() != null )
+                    {
+                        initialString = substrFilter.getInitialSubstrings();
+                    }
+
+                    if ( substrFilter.getFinalSubstrings() != null )
+                    {
+                        finalString = substrFilter.getFinalSubstrings();
+                    }
+
+                    if ( substrFilter.getAnySubstrings() != null )
+                    {
+                        anyString = new ArrayList<>();
+
+                        for ( String any : substrFilter.getAnySubstrings() )
+                        {
+                            anyString.add( any );
+                        }
+                    }
+
+                    branch = new SubstringNode( anyString, substrFilter.getType(), initialString, finalString );
+                }
+                else if ( filter instanceof ExtensibleMatchFilter )
+                {
+                    // Transform Extensible Match Filter
+                    ExtensibleMatchFilter extFilter = ( ExtensibleMatchFilter ) filter;
+                    String matchingRule = null;
+
+                    Value value = extFilter.getMatchValue();
+
+                    if ( extFilter.getMatchingRule() != null )
+                    {
+                        matchingRule = extFilter.getMatchingRule();
+                    }
+
+                    branch = new ExtensibleNode( extFilter.getType(), value, matchingRule, extFilter.isDnAttributes() );
+                }
+
+                return branch;
+            }
+        }
+        else
+        {
+            // We have found nothing to transform. Return null then.
+            return null;
+        }
+    }
+
+
+    /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
         // Here, we have to inject the decoded filter into the SearchRequest
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-        SearchRequest searchRequest = searchRequestDecorator.getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         try
         {
-            searchRequest.setFilter( searchRequestDecorator.getFilterNode() );
+            searchRequest.setFilter( transform( container.getTopFilter() ) );
         }
         catch ( LdapSchemaException lse )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestAttributeDesc.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestAttributeDesc.java
index e9aea24..0dc61ec 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestAttributeDesc.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestAttributeDesc.java
@@ -23,8 +23,8 @@ package org.apache.directory.api.ldap.codec.actions.request.search;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestAttributeDesc extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestAttributeDesc extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestAttributeDesc.class );
@@ -59,9 +59,9 @@ public class StoreSearchRequestAttributeDesc extends GrammarAction<LdapMessageCo
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchRequest> container )
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
+        SearchRequest searchRequest = container.getMessage();
         TLV tlv = container.getCurrentTLV();
         String attributeDescription = null;
 
@@ -72,7 +72,7 @@ public class StoreSearchRequestAttributeDesc extends GrammarAction<LdapMessageCo
             // If the attributeDescription is empty, we won't add it
             if ( !Strings.isEmpty( attributeDescription.trim() ) )
             {
-                searchRequestDecorator.getDecorated().addAttributes( attributeDescription );
+                searchRequest.addAttributes( attributeDescription );
             }
         }
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestBaseObject.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestBaseObject.java
index 79e3b7d..556c509 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestBaseObject.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestBaseObject.java
@@ -24,9 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.api.ResponseCarryingException;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
 import org.apache.directory.api.ldap.model.message.ResultCodeEnum;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
@@ -46,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestBaseObject extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestBaseObject extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestBaseObject.class );
@@ -64,16 +63,13 @@ public class StoreSearchRequestBaseObject extends GrammarAction<LdapMessageConta
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-        SearchRequest searchRequest = searchRequestDecorator.getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
         // We have to check that this is a correct Dn
-        Dn baseObject;
-
         // We have to handle the special case of a 0 length base
         // object,
         // which means that the search is done from the default
@@ -85,7 +81,8 @@ public class StoreSearchRequestBaseObject extends GrammarAction<LdapMessageConta
 
             try
             {
-                baseObject = new Dn( dnStr );
+                Dn baseObject = new Dn( dnStr );
+                searchRequest.setBase( baseObject );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -99,14 +96,12 @@ public class StoreSearchRequestBaseObject extends GrammarAction<LdapMessageConta
         }
         else
         {
-            baseObject = Dn.EMPTY_DN;
+            searchRequest.setBase( Dn.EMPTY_DN );
         }
 
-        searchRequest.setBase( baseObject );
-
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05160_SEARCHING_WITH_ROOT_DN, baseObject ) );
+            LOG.debug( I18n.msg( I18n.MSG_05160_SEARCHING_WITH_ROOT_DN, searchRequest.getBase() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestDerefAlias.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestDerefAlias.java
index 3b250c8..3bde6ac 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestDerefAlias.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestDerefAlias.java
@@ -28,8 +28,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.AliasDerefMode;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
@@ -50,7 +49,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestDerefAlias extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestDerefAlias extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestDerefAlias.class );
@@ -67,20 +66,20 @@ public class StoreSearchRequestDerefAlias extends GrammarAction<LdapMessageConta
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequest searchRequest = container.getMessage().getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
         // We have to check that this is a correct derefAliases
         BerValue value = tlv.getValue();
-        int derefAliases = 0;
 
         try
         {
-            derefAliases = IntegerDecoder.parse( value, LdapCodecConstants.NEVER_DEREF_ALIASES,
+            int derefAliases = IntegerDecoder.parse( value, LdapCodecConstants.NEVER_DEREF_ALIASES,
                 LdapCodecConstants.DEREF_ALWAYS );
+            searchRequest.setDerefAliases( AliasDerefMode.getDerefMode( derefAliases ) );
         }
         catch ( IntegerDecoderException ide )
         {
@@ -89,25 +88,24 @@ public class StoreSearchRequestDerefAlias extends GrammarAction<LdapMessageConta
             throw new DecoderException( msg, ide );
         }
 
-        searchRequest.setDerefAliases( AliasDerefMode.getDerefMode( derefAliases ) );
 
         if ( LOG.isDebugEnabled() )
         {
-            switch ( derefAliases )
+            switch ( searchRequest.getDerefAliases() )
             {
-                case LdapCodecConstants.NEVER_DEREF_ALIASES:
+                case NEVER_DEREF_ALIASES:
                     LOG.debug( I18n.msg( I18n.MSG_05161_HANDLING_OBJECT_STRATEGY, "NEVER_DEREF_ALIASES" ) );
                     break;
 
-                case LdapCodecConstants.DEREF_IN_SEARCHING:
+                case DEREF_IN_SEARCHING:
                     LOG.debug( I18n.msg( I18n.MSG_05161_HANDLING_OBJECT_STRATEGY, "DEREF_IN_SEARCHING" ) );
                     break;
 
-                case LdapCodecConstants.DEREF_FINDING_BASE_OBJ:
+                case DEREF_FINDING_BASE_OBJ:
                     LOG.debug( I18n.msg( I18n.MSG_05161_HANDLING_OBJECT_STRATEGY, "DEREF_FINDING_BASE_OBJ" ) );
                     break;
 
-                case LdapCodecConstants.DEREF_ALWAYS:
+                case DEREF_ALWAYS:
                     LOG.debug( I18n.msg( I18n.MSG_05161_HANDLING_OBJECT_STRATEGY, "DEREF_ALWAYS" ) );
                     break;
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestScope.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestScope.java
index 88129ec..1dca1dc 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestScope.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestScope.java
@@ -28,8 +28,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.ldap.model.message.SearchScope;
 import org.slf4j.Logger;
@@ -49,7 +48,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestScope extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestScope extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestScope.class );
@@ -66,20 +65,20 @@ public class StoreSearchRequestScope extends GrammarAction<LdapMessageContainer<
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequest searchRequest = container.getMessage().getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
         // We have to check that this is a correct scope
         BerValue value = tlv.getValue();
-        int scope = 0;
 
         try
         {
-            scope = IntegerDecoder.parse( value, LdapCodecConstants.SCOPE_BASE_OBJECT,
+            int scope = IntegerDecoder.parse( value, LdapCodecConstants.SCOPE_BASE_OBJECT,
                 LdapCodecConstants.SCOPE_WHOLE_SUBTREE );
+            searchRequest.setScope( SearchScope.getSearchScope( scope ) );
         }
         catch ( IntegerDecoderException ide )
         {
@@ -88,21 +87,20 @@ public class StoreSearchRequestScope extends GrammarAction<LdapMessageContainer<
             throw new DecoderException( msg, ide );
         }
 
-        searchRequest.setScope( SearchScope.getSearchScope( scope ) );
 
         if ( LOG.isDebugEnabled() )
         {
-            switch ( scope )
+            switch ( searchRequest.getScope() )
             {
-                case LdapCodecConstants.SCOPE_BASE_OBJECT:
+                case OBJECT :
                     LOG.debug( I18n.msg( I18n.MSG_05162_SEARCHING_WITH_SCOPE, "BASE_OBJECT" ) );
                     break;
 
-                case LdapCodecConstants.SCOPE_SINGLE_LEVEL:
+                case ONELEVEL :
                     LOG.debug( I18n.msg( I18n.MSG_05162_SEARCHING_WITH_SCOPE, "SINGLE_LEVEL" ) );
                     break;
 
-                case LdapCodecConstants.SCOPE_WHOLE_SUBTREE:
+                case SUBTREE :
                     LOG.debug( I18n.msg( I18n.MSG_05162_SEARCHING_WITH_SCOPE, "WHOLE_SUBTREE" ) );
                     break;
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestSizeLimit.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestSizeLimit.java
index d46d51e..7b58a2c 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestSizeLimit.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestSizeLimit.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.LongDecoder;
 import org.apache.directory.api.asn1.ber.tlv.LongDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -44,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestSizeLimit extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestSizeLimit extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestSizeLimit.class );
@@ -61,20 +60,20 @@ public class StoreSearchRequestSizeLimit extends GrammarAction<LdapMessageContai
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequest searchRequest = container.getMessage().getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
         // The current TLV should be a integer
         // We get it and store it in sizeLimit
         BerValue value = tlv.getValue();
-        long sizeLimit = 0;
 
         try
         {
-            sizeLimit = LongDecoder.parse( value, 0, Integer.MAX_VALUE );
+            long sizeLimit = LongDecoder.parse( value, 0, Integer.MAX_VALUE );
+            searchRequest.setSizeLimit( sizeLimit );
         }
         catch ( LongDecoderException lde )
         {
@@ -83,11 +82,9 @@ public class StoreSearchRequestSizeLimit extends GrammarAction<LdapMessageContai
             throw new DecoderException( msg, lde );
         }
 
-        searchRequest.setSizeLimit( sizeLimit );
-
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05163_SIZE_LIMIT_SET_TO, Long.valueOf( sizeLimit ) ) );
+            LOG.debug( I18n.msg( I18n.MSG_05163_SIZE_LIMIT_SET_TO, searchRequest.getSizeLimit() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTimeLimit.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTimeLimit.java
index b7108a2..034cec6 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTimeLimit.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTimeLimit.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.IntegerDecoder;
 import org.apache.directory.api.asn1.ber.tlv.IntegerDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -44,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestTimeLimit extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestTimeLimit extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestTimeLimit.class );
@@ -61,9 +60,9 @@ public class StoreSearchRequestTimeLimit extends GrammarAction<LdapMessageContai
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequest searchRequest = container.getMessage().getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -71,11 +70,10 @@ public class StoreSearchRequestTimeLimit extends GrammarAction<LdapMessageContai
         // We get it and store it in timeLimit
         BerValue value = tlv.getValue();
 
-        int timeLimit = 0;
-
         try
         {
-            timeLimit = IntegerDecoder.parse( value, 0, Integer.MAX_VALUE );
+            int timeLimit = IntegerDecoder.parse( value, 0, Integer.MAX_VALUE );
+            searchRequest.setTimeLimit( timeLimit );
         }
         catch ( IntegerDecoderException ide )
         {
@@ -84,11 +82,9 @@ public class StoreSearchRequestTimeLimit extends GrammarAction<LdapMessageContai
             throw new DecoderException( msg, ide );
         }
 
-        searchRequest.setTimeLimit( timeLimit );
-
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05164_TIME_LIMIT_SET_TO, Integer.valueOf( timeLimit ) ) );
+            LOG.debug( I18n.msg( I18n.MSG_05164_TIME_LIMIT_SET_TO, searchRequest.getTimeLimit() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTypesOnly.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTypesOnly.java
index 20d027a..f963d9e 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTypesOnly.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreSearchRequestTypesOnly.java
@@ -27,8 +27,7 @@ import org.apache.directory.api.asn1.ber.tlv.BooleanDecoder;
 import org.apache.directory.api.asn1.ber.tlv.BooleanDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -45,7 +44,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchRequestTypesOnly extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSearchRequestTypesOnly extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchRequestTypesOnly.class );
@@ -62,9 +61,9 @@ public class StoreSearchRequestTypesOnly extends GrammarAction<LdapMessageContai
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequest searchRequest = container.getMessage().getDecorated();
+        SearchRequest searchRequest = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAndFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAndFilter.java
index 8eed05d..8a4f757 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAndFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAndFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AndFilter;
 import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAndFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitAndFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAndFilter.class );
@@ -54,7 +54,7 @@ public class InitAndFilter extends GrammarAction<LdapMessageContainer<SearchRequ
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
@@ -65,13 +65,11 @@ public class InitAndFilter extends GrammarAction<LdapMessageContainer<SearchRequ
             throw new DecoderException( msg );
         }
 
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the SearchRequest
-        Filter andFilter = new AndFilter( container.getTlvId() );
+        Filter andFilter = new AndFilter( tlv.getId()  );
 
         // Set the filter
-        searchRequestDecorator.addCurrentFilter( andFilter );
+        container.addCurrentFilter( andFilter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitApproxMatchFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitApproxMatchFilter.java
index 3d3ec25..c84dc92 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitApproxMatchFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitApproxMatchFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
 import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitApproxMatchFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitApproxMatchFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitApproxMatchFilter.class );
@@ -54,19 +54,17 @@ public class InitApproxMatchFilter extends GrammarAction<LdapMessageContainer<Se
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the Attribute Value Assertion
-        Filter filter = new AttributeValueAssertionFilter( container.getTlvId(),
+        Filter filter = new AttributeValueAssertionFilter( container.getCurrentTLV().getId(),
             LdapCodecConstants.APPROX_MATCH_FILTER );
 
-        searchRequestDecorator.addCurrentFilter( filter );
+        container.addCurrentFilter( filter );
 
         // Store the filter structure that still has to be
         // fulfilled
-        searchRequestDecorator.setTerminalFilter( filter );
+        container.setTerminalFilter( filter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAssertionValueFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAssertionValueFilter.java
index 60a2a12..cc0cb78 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAssertionValueFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAssertionValueFilter.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.AttributeValueAssertion;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAssertionValueFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitAssertionValueFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAssertionValueFilter.class );
@@ -54,17 +54,15 @@ public class InitAssertionValueFilter extends GrammarAction<LdapMessageContainer
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchRequest> container )
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // The value can be null.
         byte[] assertion = tlv.getValue().getData();
         
         AttributeValueAssertionFilter terminalFilter = ( AttributeValueAssertionFilter )
-            searchRequestDecorator.getTerminalFilter();
+            container.getTerminalFilter();
         AttributeValueAssertion attributeValueAssertion = terminalFilter.getAssertion();
 
         if ( assertion == null )
@@ -78,7 +76,7 @@ public class InitAssertionValueFilter extends GrammarAction<LdapMessageContainer
 
         // We now have to get back to the nearest filter which is
         // not terminal.
-        searchRequestDecorator.unstackFilters( container );
+        container.unstackFilters();
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAttributeDescFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAttributeDescFilter.java
index f9ea341..3be2f95 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAttributeDescFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitAttributeDescFilter.java
@@ -25,9 +25,9 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.AttributeValueAssertion;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAttributeDescFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitAttributeDescFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAttributeDescFilter.class );
@@ -55,10 +55,8 @@ public class InitAttributeDescFilter extends GrammarAction<LdapMessageContainer<
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         AttributeValueAssertion assertion = new AttributeValueAssertion();
@@ -75,7 +73,7 @@ public class InitAttributeDescFilter extends GrammarAction<LdapMessageContainer<
             assertion.setAttributeDesc( type );
 
             AttributeValueAssertionFilter terminalFilter = ( AttributeValueAssertionFilter )
-                searchRequestDecorator.getTerminalFilter();
+                container.getTerminalFilter();
             terminalFilter.setAssertion( assertion );
         }
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitEqualityMatchFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitEqualityMatchFilter.java
index 8e2f008..9a0926b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitEqualityMatchFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitEqualityMatchFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
 import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitEqualityMatchFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitEqualityMatchFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitEqualityMatchFilter.class );
@@ -54,19 +54,17 @@ public class InitEqualityMatchFilter extends GrammarAction<LdapMessageContainer<
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the Attribute Value Assertion
-        Filter filter = new AttributeValueAssertionFilter( container.getTlvId(),
+        Filter filter = new AttributeValueAssertionFilter( container.getCurrentTLV().getId(),
             LdapCodecConstants.EQUALITY_MATCH_FILTER );
 
-        searchRequestDecorator.addCurrentFilter( filter );
+        container.addCurrentFilter( filter );
 
         // Store the filter structure that still has to be
         // fulfilled
-        searchRequestDecorator.setTerminalFilter( filter );
+        container.setTerminalFilter( filter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitExtensibleMatchFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitExtensibleMatchFilter.java
index 659b4f9..18d0f1b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitExtensibleMatchFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitExtensibleMatchFilter.java
@@ -23,10 +23,10 @@ package org.apache.directory.api.ldap.codec.actions.request.search.filter;
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
 import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitExtensibleMatchFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitExtensibleMatchFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitExtensibleMatchFilter.class );
@@ -53,15 +53,13 @@ public class InitExtensibleMatchFilter extends GrammarAction<LdapMessageContaine
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the ExtensibleMatch Filter
-        Filter extensibleMatchFilter = new ExtensibleMatchFilter( container.getTlvId() );
+        Filter extensibleMatchFilter = new ExtensibleMatchFilter( container.getCurrentTLV().getId() );
 
-        searchRequestDecorator.addCurrentFilter( extensibleMatchFilter );
-        searchRequestDecorator.setTerminalFilter( extensibleMatchFilter );
+        container.addCurrentFilter( extensibleMatchFilter );
+        container.setTerminalFilter( extensibleMatchFilter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitGreaterOrEqualFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitGreaterOrEqualFilter.java
index 1fc7a22..70f7d87 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitGreaterOrEqualFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitGreaterOrEqualFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
 import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitGreaterOrEqualFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitGreaterOrEqualFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitGreaterOrEqualFilter.class );
@@ -54,19 +54,17 @@ public class InitGreaterOrEqualFilter extends GrammarAction<LdapMessageContainer
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the Attribute Value Assertion
-        Filter filter = new AttributeValueAssertionFilter( container.getTlvId(),
+        Filter filter = new AttributeValueAssertionFilter( container.getCurrentTLV().getId(),
             LdapCodecConstants.GREATER_OR_EQUAL_FILTER );
 
-        searchRequestDecorator.addCurrentFilter( filter );
+        container.addCurrentFilter( filter );
 
         // Store the filter structure that still has to be
         // fulfilled
-        searchRequestDecorator.setTerminalFilter( filter );
+        container.setTerminalFilter( filter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitLessOrEqualFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitLessOrEqualFilter.java
index eed5419..86bebba 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitLessOrEqualFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitLessOrEqualFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.codec.api.LdapCodecConstants;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.AttributeValueAssertionFilter;
 import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitLessOrEqualFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitLessOrEqualFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitLessOrEqualFilter.class );
@@ -54,19 +54,17 @@ public class InitLessOrEqualFilter extends GrammarAction<LdapMessageContainer<Se
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the Attribute Value Assertion
-        Filter filter = new AttributeValueAssertionFilter( container.getTlvId(),
+        Filter filter = new AttributeValueAssertionFilter( container.getCurrentTLV().getId(),
             LdapCodecConstants.LESS_OR_EQUAL_FILTER );
 
-        searchRequestDecorator.addCurrentFilter( filter );
+        container.addCurrentFilter( filter );
 
         // Store the filter structure that still has to be
         // fulfilled
-        searchRequestDecorator.setTerminalFilter( filter );
+        container.setTerminalFilter( filter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitNotFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitNotFilter.java
index e6a6ab1..807f83d 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitNotFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitNotFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.Filter;
 import org.apache.directory.api.ldap.codec.search.NotFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitNotFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitNotFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitNotFilter.class );
@@ -54,7 +54,7 @@ public class InitNotFilter extends GrammarAction<LdapMessageContainer<SearchRequ
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
@@ -65,13 +65,11 @@ public class InitNotFilter extends GrammarAction<LdapMessageContainer<SearchRequ
             throw new DecoderException( msg );
         }
 
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the SearchRequest
-        Filter notFilter = new NotFilter( container.getTlvId() );
+        Filter notFilter = new NotFilter( tlv.getId() );
 
         // Set the filter
-        searchRequestDecorator.addCurrentFilter( notFilter );
+        container.addCurrentFilter( notFilter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitOrFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitOrFilter.java
index 0f60d83..5500d9d 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitOrFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitOrFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.Filter;
 import org.apache.directory.api.ldap.codec.search.OrFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitOrFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitOrFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitOrFilter.class );
@@ -54,7 +54,7 @@ public class InitOrFilter extends GrammarAction<LdapMessageContainer<SearchReque
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
         TLV tlv = container.getCurrentTLV();
 
@@ -65,13 +65,11 @@ public class InitOrFilter extends GrammarAction<LdapMessageContainer<SearchReque
             throw new DecoderException( msg );
         }
 
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         // We can allocate the SearchRequest
-        Filter orFilter = new OrFilter( container.getTlvId() );
+        Filter orFilter = new OrFilter( tlv.getId() );
 
         // Set the filter
-        searchRequestDecorator.addCurrentFilter( orFilter );
+        container.addCurrentFilter( orFilter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitPresentFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitPresentFilter.java
index b56c295..b72a49a 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitPresentFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitPresentFilter.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.PresentFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 
 import org.slf4j.Logger;
@@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitPresentFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitPresentFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitPresentFilter.class );
@@ -55,18 +55,16 @@ public class InitPresentFilter extends GrammarAction<LdapMessageContainer<Search
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // We can allocate the Attribute Value Assertion
         PresentFilter presentFilter = new PresentFilter( container.getTlvId() );
 
         // add the filter to the request filter
-        searchRequestDecorator.addCurrentFilter( presentFilter );
-        searchRequestDecorator.setTerminalFilter( presentFilter );
+        container.addCurrentFilter( presentFilter );
+        container.setTerminalFilter( presentFilter );
 
         String value = Strings.utf8ToString( tlv.getValue().getData() );
 
@@ -83,7 +81,7 @@ public class InitPresentFilter extends GrammarAction<LdapMessageContainer<Search
 
         // We now have to get back to the nearest filter which is
         // not terminal.
-        searchRequestDecorator.unstackFilters( container );
+        container.unstackFilters();
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitSubstringsFilter.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitSubstringsFilter.java
index 60956d7..044a917 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitSubstringsFilter.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/InitSubstringsFilter.java
@@ -24,10 +24,10 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.Filter;
 import org.apache.directory.api.ldap.codec.search.SubstringFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSubstringsFilter extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class InitSubstringsFilter extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitSubstringsFilter.class );
@@ -54,10 +54,8 @@ public class InitSubstringsFilter extends GrammarAction<LdapMessageContainer<Sea
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         int expectedLength = tlv.getLength();
@@ -70,10 +68,10 @@ public class InitSubstringsFilter extends GrammarAction<LdapMessageContainer<Sea
         }
 
         // We can allocate the SearchRequest
-        Filter substringFilter = new SubstringFilter( container.getTlvId() );
+        Filter substringFilter = new SubstringFilter( container.getCurrentTLV().getId() );
 
-        searchRequestDecorator.addCurrentFilter( substringFilter );
-        searchRequestDecorator.setTerminalFilter( substringFilter );
+        container.addCurrentFilter( substringFilter );
+        container.setTerminalFilter( substringFilter );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreAny.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreAny.java
index a8d015d..2750fd0 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreAny.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreAny.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.SubstringFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreAny extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreAny extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreAny.class );
@@ -61,14 +61,12 @@ public class StoreAny extends GrammarAction<LdapMessageContainer<SearchRequestDe
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator decorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value.
-        SubstringFilter substringFilter = ( SubstringFilter ) decorator.getTerminalFilter();
+        SubstringFilter substringFilter = ( SubstringFilter ) container.getTerminalFilter();
 
         if ( tlv.getLength() == 0 )
         {
@@ -82,7 +80,7 @@ public class StoreAny extends GrammarAction<LdapMessageContainer<SearchRequestDe
 
         // We now have to get back to the nearest filter which is
         // not terminal.
-        decorator.unstackFilters( container );
+        container.unstackFilters();
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreFinal.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreFinal.java
index 1186774..2fbce84 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreFinal.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreFinal.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.SubstringFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreFinal extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreFinal extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreFinal.class );
@@ -61,14 +61,12 @@ public class StoreFinal extends GrammarAction<LdapMessageContainer<SearchRequest
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequest = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value.
-        SubstringFilter substringFilter = ( SubstringFilter ) searchRequest.getTerminalFilter();
+        SubstringFilter substringFilter = ( SubstringFilter ) container.getTerminalFilter();
 
         if ( tlv.getLength() == 0 )
         {
@@ -82,7 +80,7 @@ public class StoreFinal extends GrammarAction<LdapMessageContainer<SearchRequest
 
         // We now have to get back to the nearest filter which is
         // not terminal.
-        searchRequest.unstackFilters( container );
+        container.unstackFilters();
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreInitial.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreInitial.java
index 2b52b6f..3cc142c 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreInitial.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreInitial.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.SubstringFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreInitial extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreInitial extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreInitial.class );
@@ -62,14 +62,12 @@ public class StoreInitial extends GrammarAction<LdapMessageContainer<SearchReque
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value.
-        SubstringFilter substringFilter = ( SubstringFilter ) searchRequestDecorator.getTerminalFilter();
+        SubstringFilter substringFilter = ( SubstringFilter ) container.getTerminalFilter();
 
         if ( tlv.getLength() == 0 )
         {
@@ -82,6 +80,6 @@ public class StoreInitial extends GrammarAction<LdapMessageContainer<SearchReque
 
         // We now have to get back to the nearest filter which is
         // not terminal.
-        searchRequestDecorator.unstackFilters( container );
+        container.unstackFilters();
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchValue.java
index 141eb8a..4b66b62 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchValue.java
@@ -23,10 +23,10 @@ package org.apache.directory.api.ldap.codec.actions.request.search.filter;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
 import org.apache.directory.api.ldap.model.entry.Value;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -45,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreMatchValue extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreMatchValue extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreMatchValue.class );
@@ -62,20 +62,18 @@ public class StoreMatchValue extends GrammarAction<LdapMessageContainer<SearchRe
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchRequest> container )
     {
-        SearchRequestDecorator decorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value.
-        ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) decorator.getTerminalFilter();
+        ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) container.getTerminalFilter();
 
         byte[] value = tlv.getValue().getData();
         extensibleMatchFilter.setMatchValue( new Value( value ) );
 
         // unstack the filters if needed
-        decorator.unstackFilters( container );
+        container.unstackFilters();
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleDnAttributes.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleDnAttributes.java
index f17be9e..f9842d9 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleDnAttributes.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleDnAttributes.java
@@ -27,9 +27,9 @@ import org.apache.directory.api.asn1.ber.tlv.BooleanDecoder;
 import org.apache.directory.api.asn1.ber.tlv.BooleanDecoderException;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -48,7 +48,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreMatchingRuleDnAttributes extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreMatchingRuleDnAttributes extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreMatchingRuleDnAttributes.class );
@@ -62,14 +62,12 @@ public class StoreMatchingRuleDnAttributes extends GrammarAction<LdapMessageCont
     }
 
 
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequest = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value.
-        ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) searchRequest.getTerminalFilter();
+        ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) container.getTerminalFilter();
 
         // We get the value. If it's a 0, it's a FALSE. If it's
         // a FF, it's a TRUE. Any other value should be an error,
@@ -97,6 +95,6 @@ public class StoreMatchingRuleDnAttributes extends GrammarAction<LdapMessageCont
         }
 
         // unstack the filters if needed
-        searchRequest.unstackFilters( container );
+        container.unstackFilters();
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreTypeMatchingRule.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleId.java
similarity index 64%
copy from ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreTypeMatchingRule.java
copy to ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleId.java
index 76dfeed..20c6ca8 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreTypeMatchingRule.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleId.java
@@ -17,68 +17,63 @@
  *  under the License. 
  *  
  */
-package org.apache.directory.api.ldap.codec.actions.request.search;
+package org.apache.directory.api.ldap.codec.actions.request.search.filter;
 
 
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 
 /**
- * The action used to store a type matching rule
+ * The action used to store a type matching ID
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreTypeMatchingRule extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreMatchingRuleId extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
 
     /** The logger. */
-    private static final Logger LOG = LoggerFactory.getLogger( StoreTypeMatchingRule.class );
+    private static final Logger LOG = LoggerFactory.getLogger( StoreMatchingRuleId.class );
 
     /**
      * Instantiates a new store type matching rule action.
      */
-    public StoreTypeMatchingRule()
+    public StoreMatchingRuleId()
     {
-        super( "Store matching type Value" );
+        super( "Store matching rule Value" );
     }
 
 
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequest = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
+        // Store the value.
+        ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter )
+            container.getTerminalFilter();
+
         if ( tlv.getLength() == 0 )
         {
-            String msg = I18n.err( I18n.ERR_05141_NULL_MATCHING_RULE_ASSERTION_TYPE );
+            String msg = I18n.err( I18n.ERR_05001_EMPTY_MATCHING_RULE );
             LOG.error( msg );
+
+            // It will generate a PROTOCOL_ERROR
             throw new DecoderException( msg );
         }
         else
         {
-            // Store the value.
-            ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) searchRequest.getTerminalFilter();
-
-            String type = Strings.utf8ToString( tlv.getValue().getData() );
-            extensibleMatchFilter.setType( type );
-
-            if ( LOG.isDebugEnabled() )
-            {
-                LOG.debug( I18n.msg( I18n.MSG_05166_STORED_TYPE_MATCHING_RULE, type ) );
-            }
+            extensibleMatchFilter.setMatchingRule( Strings.utf8ToString( tlv.getValue().getData() ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreTypeMatchingRule.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleType.java
similarity index 83%
rename from ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreTypeMatchingRule.java
rename to ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleType.java
index 76dfeed..58631be 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/StoreTypeMatchingRule.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreMatchingRuleType.java
@@ -17,16 +17,16 @@
  *  under the License. 
  *  
  */
-package org.apache.directory.api.ldap.codec.actions.request.search;
+package org.apache.directory.api.ldap.codec.actions.request.search.filter;
 
 
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.ExtensibleMatchFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,16 +37,16 @@ import org.slf4j.LoggerFactory;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreTypeMatchingRule extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreMatchingRuleType extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
 
     /** The logger. */
-    private static final Logger LOG = LoggerFactory.getLogger( StoreTypeMatchingRule.class );
+    private static final Logger LOG = LoggerFactory.getLogger( StoreMatchingRuleType.class );
 
     /**
      * Instantiates a new store type matching rule action.
      */
-    public StoreTypeMatchingRule()
+    public StoreMatchingRuleType()
     {
         super( "Store matching type Value" );
     }
@@ -55,10 +55,8 @@ public class StoreTypeMatchingRule extends GrammarAction<LdapMessageContainer<Se
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequest = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         if ( tlv.getLength() == 0 )
@@ -70,7 +68,7 @@ public class StoreTypeMatchingRule extends GrammarAction<LdapMessageContainer<Se
         else
         {
             // Store the value.
-            ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) searchRequest.getTerminalFilter();
+            ExtensibleMatchFilter extensibleMatchFilter = ( ExtensibleMatchFilter ) container.getTerminalFilter();
 
             String type = Strings.utf8ToString( tlv.getValue().getData() );
             extensibleMatchFilter.setType( type );
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreSubstringFilterType.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreSubstringFilterType.java
index 35c2fa1..586e3ac 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreSubstringFilterType.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/search/filter/StoreSubstringFilterType.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.codec.search.SubstringFilter;
+import org.apache.directory.api.ldap.model.message.SearchRequest;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -46,7 +46,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSubstringFilterType extends GrammarAction<LdapMessageContainer<SearchRequestDecorator>>
+public class StoreSubstringFilterType extends GrammarAction<LdapMessageContainerDirect<SearchRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSubstringFilterType.class );
@@ -64,14 +64,12 @@ public class StoreSubstringFilterType extends GrammarAction<LdapMessageContainer
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchRequest> container ) throws DecoderException
     {
-        SearchRequestDecorator searchRequestDecorator = container.getMessage();
-
         TLV tlv = container.getCurrentTLV();
 
         // Store the value.
-        SubstringFilter substringFilter = ( SubstringFilter ) searchRequestDecorator.getTerminalFilter();
+        SubstringFilter substringFilter = ( SubstringFilter ) container.getTerminalFilter();
 
         if ( tlv.getLength() == 0 )
         {
@@ -86,7 +84,7 @@ public class StoreSubstringFilterType extends GrammarAction<LdapMessageContainer
 
             // We now have to get back to the nearest filter which
             // is not terminal.
-            searchRequestDecorator.setTerminalFilter( substringFilter );
+            container.setTerminalFilter( substringFilter );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/unbind/InitUnbindRequest.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/unbind/InitUnbindRequest.java
index 21bae55..b9281b7 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/unbind/InitUnbindRequest.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/request/unbind/InitUnbindRequest.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.UnbindRequestDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.UnbindRequest;
 import org.apache.directory.api.ldap.model.message.UnbindRequestImpl;
 import org.slf4j.Logger;
@@ -40,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitUnbindRequest extends GrammarAction<LdapMessageContainer<UnbindRequestDecorator>>
+public class InitUnbindRequest extends GrammarAction<LdapMessageContainerDirect<UnbindRequest>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitUnbindRequest.class );
@@ -58,13 +57,11 @@ public class InitUnbindRequest extends GrammarAction<LdapMessageContainer<Unbind
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<UnbindRequestDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<UnbindRequest> container ) throws DecoderException
     {
         // Create the UnbindRequest LdapMessage instance and store it in the container
-        UnbindRequest unbindRequestInternal = new UnbindRequestImpl();
-        unbindRequestInternal.setMessageId( container.getMessageId() );
-        UnbindRequestDecorator unbindRequest = new UnbindRequestDecorator(
-            container.getLdapCodecService(), unbindRequestInternal );
+        UnbindRequest unbindRequest = new UnbindRequestImpl();
+        unbindRequest.setMessageId( container.getMessageId() );
         container.setMessage( unbindRequest );
 
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/add/InitAddResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/add/InitAddResponse.java
index ec64bc8..646a456 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/add/InitAddResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/add/InitAddResponse.java
@@ -24,8 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.AddResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.AddResponse;
 import org.apache.directory.api.ldap.model.message.AddResponseImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitAddResponse extends GrammarAction<LdapMessageContainer<AddResponseDecorator>>
+public class InitAddResponse extends GrammarAction<LdapMessageContainerDirect<AddResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitAddResponse.class );
@@ -57,11 +57,10 @@ public class InitAddResponse extends GrammarAction<LdapMessageContainer<AddRespo
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<AddResponseDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<AddResponse> container ) throws DecoderException
     {
         // Now, we can allocate the AddResponse Object
-        AddResponseDecorator addResponse = new AddResponseDecorator(
-            container.getLdapCodecService(), new AddResponseImpl( container.getMessageId() ) );
+        AddResponse addResponse = new AddResponseImpl( container.getMessageId() );
         container.setMessage( addResponse );
 
         // We will check that the request is not null
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/InitBindResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/InitBindResponse.java
index ef5cdfd..09df893 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/InitBindResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/InitBindResponse.java
@@ -21,8 +21,8 @@ package org.apache.directory.api.ldap.codec.actions.response.bind;
 
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.BindResponse;
 import org.apache.directory.api.ldap.model.message.BindResponseImpl;
 
 
@@ -34,7 +34,7 @@ import org.apache.directory.api.ldap.model.message.BindResponseImpl;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitBindResponse extends GrammarAction<LdapMessageContainer<BindResponseDecorator>>
+public class InitBindResponse extends GrammarAction<LdapMessageContainerDirect<BindResponse>>
 {
     /**
      * Instantiates a new action.
@@ -48,11 +48,10 @@ public class InitBindResponse extends GrammarAction<LdapMessageContainer<BindRes
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<BindResponseDecorator> container )
+    public void action( LdapMessageContainerDirect<BindResponse> container )
     {
         // Now, we can allocate the BindResponse Object
-        BindResponseDecorator bindResponse = new BindResponseDecorator(
-            container.getLdapCodecService(), new BindResponseImpl( container.getMessageId() ) );
+        BindResponse bindResponse = new BindResponseImpl( container.getMessageId() );
         container.setMessage( bindResponse );
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/StoreServerSASLCreds.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/StoreServerSASLCreds.java
index 4a4e080..7de81da 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/StoreServerSASLCreds.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/bind/StoreServerSASLCreds.java
@@ -23,8 +23,7 @@ package org.apache.directory.api.ldap.codec.actions.response.bind;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.BindResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.BindResponse;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -40,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreServerSASLCreds extends GrammarAction<LdapMessageContainer<BindResponseDecorator>>
+public class StoreServerSASLCreds extends GrammarAction<LdapMessageContainerDirect<BindResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreServerSASLCreds.class );
@@ -57,7 +56,7 @@ public class StoreServerSASLCreds extends GrammarAction<LdapMessageContainer<Bin
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<BindResponseDecorator> container )
+    public void action( LdapMessageContainerDirect<BindResponse> container )
     {
         // Get the Value and store it in the BindRequest
         TLV tlv = container.getCurrentTLV();
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/compare/InitCompareResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/compare/InitCompareResponse.java
index 1757edc..64681c5 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/compare/InitCompareResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/compare/InitCompareResponse.java
@@ -24,8 +24,8 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.CompareResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.CompareResponse;
 import org.apache.directory.api.ldap.model.message.CompareResponseImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitCompareResponse extends GrammarAction<LdapMessageContainer<CompareResponseDecorator>>
+public class InitCompareResponse extends GrammarAction<LdapMessageContainerDirect<CompareResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitCompareResponse.class );
@@ -57,11 +57,10 @@ public class InitCompareResponse extends GrammarAction<LdapMessageContainer<Comp
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<CompareResponseDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<CompareResponse> container ) throws DecoderException
     {
         // Now, we can allocate the CompareResponse Object
-        CompareResponseDecorator compareResponse = new CompareResponseDecorator(
-            container.getLdapCodecService(), new CompareResponseImpl( container.getMessageId() ) );
+        CompareResponse compareResponse = new CompareResponseImpl( container.getMessageId() );
         container.setMessage( compareResponse );
 
         // We will check that the request is not null
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/del/InitDelResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/del/InitDelResponse.java
index 41e852d..fa4610b 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/del/InitDelResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/del/InitDelResponse.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.response.del;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.DeleteResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.DeleteResponse;
 import org.apache.directory.api.ldap.model.message.DeleteResponseImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitDelResponse extends GrammarAction<LdapMessageContainer<DeleteResponseDecorator>>
+public class InitDelResponse extends GrammarAction<LdapMessageContainerDirect<DeleteResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitDelResponse.class );
@@ -55,11 +55,10 @@ public class InitDelResponse extends GrammarAction<LdapMessageContainer<DeleteRe
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<DeleteResponseDecorator> container )
+    public void action( LdapMessageContainerDirect<DeleteResponse> container )
     {
         // Now, we can allocate the DelResponse Object
-        DeleteResponseDecorator delResponse = new DeleteResponseDecorator(
-            container.getLdapCodecService(), new DeleteResponseImpl( container.getMessageId() ) );
+        DeleteResponse delResponse = new DeleteResponseImpl( container.getMessageId() );
         container.setMessage( delResponse );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/InitExtendedResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/InitExtendedResponse.java
index 35037c4..2c4b878 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/InitExtendedResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/InitExtendedResponse.java
@@ -22,9 +22,9 @@ package org.apache.directory.api.ldap.codec.actions.response.extended;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedResponseDecorator;
-import org.apache.directory.api.ldap.model.message.ExtendedResponseImpl;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.ExtendedResponse;
+import org.apache.directory.api.ldap.model.message.OpaqueExtendedResponse;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitExtendedResponse extends GrammarAction<LdapMessageContainer<ExtendedResponseDecorator<?>>>
+public class InitExtendedResponse extends GrammarAction<LdapMessageContainerDirect<ExtendedResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitExtendedResponse.class );
@@ -55,11 +55,13 @@ public class InitExtendedResponse extends GrammarAction<LdapMessageContainer<Ext
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<ExtendedResponseDecorator<?>> container )
+    public void action( LdapMessageContainerDirect<ExtendedResponse> container )
     {
         // Now, we can allocate the ExtendedResponse Object ( a generic one)
-        ExtendedResponseDecorator<?> extendedResponse = new ExtendedResponseDecorator<>(
-            container.getLdapCodecService(), new ExtendedResponseImpl( container.getMessageId() ) );
+        // We can't wait as we may have an extended response with no OID,
+        // and not value either.
+        ExtendedResponse extendedResponse = new OpaqueExtendedResponse();
+        extendedResponse.setMessageId( container.getMessageId() );
         container.setMessage( extendedResponse );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseName.java
index 34eea9b..1bd94b5 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseName.java
@@ -25,9 +25,9 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.asn1.util.Oid;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.LdapResultDecorator;
+import org.apache.directory.api.ldap.codec.api.ExtendedOperationFactory;
+import org.apache.directory.api.ldap.codec.api.LdapApiService;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.ExtendedResponse;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -45,7 +45,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreExtendedResponseName extends GrammarAction<LdapMessageContainer<ExtendedResponseDecorator<?>>>
+public class StoreExtendedResponseName extends GrammarAction<LdapMessageContainerDirect<ExtendedResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreExtendedResponseName.class );
@@ -62,12 +62,12 @@ public class StoreExtendedResponseName extends GrammarAction<LdapMessageContaine
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<ExtendedResponseDecorator<?>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<ExtendedResponse> container ) throws DecoderException
     {
-        // We can allocate the ExtendedResponse Object
-        ExtendedResponse extendedResponse;
-
-        // Get the Value and store it in the ExtendedResponse
+        // Get the Name and store it in the ExtendedResponse. That will
+        // allow us to find the proper extended response instance, if it's 
+        // already declared. Otherwise, we will use a default ExtendedResponse
+        // in which the value will be stored un-decoded.
         TLV tlv = container.getCurrentTLV();
 
         // We have to handle the special case of a 0 length matched
@@ -80,23 +80,61 @@ public class StoreExtendedResponseName extends GrammarAction<LdapMessageContaine
         }
         else
         {
-            String responseName = Oid.fromString( Strings.asciiBytesToString( tlv.getValue().getData() ) )
-                .toString();
+            byte[] responseNameBytes = tlv.getValue().getData();
+            String responseName = Strings.asciiBytesToString( responseNameBytes );
+
+            try
+            {
+                // Check the OID first, if it's invalid, reject the operation
+                if ( !Oid.isOid( responseName ) )
+                {
+                    String msg = I18n.err( I18n.ERR_05159_INVALID_RESPONSE_NAME_OID,
+                        responseName, Strings.dumpBytes( responseNameBytes ) );
+                    LOG.error( msg );
+    
+                    // throw an exception, we will get a PROTOCOL_ERROR
+                    throw new DecoderException( msg );
+                }
+    
+                // Get the extended request factory from the LdapApiService, if it's registered
+                LdapApiService codec = container.getLdapCodecService();
+                ExtendedOperationFactory factory = codec.getExtendedResponseFactories().get( responseName );
+                ExtendedResponse extendedResponse = container.getMessage();
+                
+                if ( factory != null )
+                {
+                    // Create the extended request
+                    extendedResponse = factory.newResponse();
+
+                    // Move the LDAPResult in the newly created response
+                    LdapMessageContainerDirect.copyLdapResult( container.getMessage(), extendedResponse );
+                    extendedResponse.setMessageId( container.getMessageId() );
+                    container.setMessage( extendedResponse );
+                }
+                else
+                {
+                   extendedResponse.setResponseName( responseName );
+                }
+
+                container.setExtendedFactory( factory );
+                
+                if ( LOG.isDebugEnabled() )
+                {
+                    LOG.debug( I18n.msg( I18n.MSG_05172_OID_READ, extendedResponse.getResponseName() ) );
+                }
+            }
+            catch ( DecoderException de )
+            {
+                String msg = I18n.err( I18n.ERR_05159_INVALID_RESPONSE_NAME_OID,
+                    responseName, Strings.dumpBytes( responseNameBytes ) );
+                LOG.error( I18n.err( I18n.ERR_05114_ERROR_MESSAGE, msg, de.getMessage() ) );
 
-            extendedResponse = container.getLdapCodecService().newExtendedResponse( responseName,
-                container.getMessageId(), null );
-            
-            ( ( ExtendedResponseDecorator<?> ) extendedResponse ).setLdapResult( ( LdapResultDecorator ) ( container
-                .getMessage().getLdapResult() ) );
-            container.setMessage( ( ExtendedResponseDecorator<?> ) extendedResponse );
+                // Rethrow the exception, we will get a PROTOCOL_ERROR
+                throw de;
+            }
         }
 
         // We can have an END transition
         container.setGrammarEndAllowed( true );
-
-        if ( LOG.isDebugEnabled() )
-        {
-            LOG.debug( I18n.msg( I18n.MSG_05172_OID_READ, extendedResponse.getResponseName() ) );
-        }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseValue.java
index 003fe48..f858023 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/extended/StoreExtendedResponseValue.java
@@ -20,12 +20,14 @@
 package org.apache.directory.api.ldap.codec.actions.response.extended;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.ExtendedOperationFactory;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.ExtendedResponse;
+import org.apache.directory.api.ldap.model.message.OpaqueExtendedResponse;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -40,7 +42,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreExtendedResponseValue extends GrammarAction<LdapMessageContainer<ExtendedResponseDecorator<?>>>
+public class StoreExtendedResponseValue extends GrammarAction<LdapMessageContainerDirect<ExtendedResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreExtendedResponseValue.class );
@@ -57,24 +59,43 @@ public class StoreExtendedResponseValue extends GrammarAction<LdapMessageContain
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<ExtendedResponseDecorator<?>> container )
+    public void action( LdapMessageContainerDirect<ExtendedResponse> container ) throws DecoderException
     {
         // We can allocate the ExtendedResponse Object
-        ExtendedResponseDecorator<?> extendedResponse = container.getMessage();
+        ExtendedResponse extendedResponse = container.getMessage();
 
         // Get the Value and store it in the ExtendedResponse
         TLV tlv = container.getCurrentTLV();
+        
+        ExtendedOperationFactory factory = container.getExtendedFactory();
 
-        // We have to handle the special case of a 0 length matched
-        // OID
-        if ( tlv.getLength() == 0 )
+        // We have to handle the special case of a 0 length matched value
+        try
         {
-            extendedResponse.setResponseValue( Strings.EMPTY_BYTES );
+            if ( factory == null )
+            {
+                if ( tlv.getLength() == 0 )
+                {
+                    ( ( OpaqueExtendedResponse ) extendedResponse ).setResponseValue( Strings.EMPTY_BYTES );
+                }
+                else
+                {
+                    ( ( OpaqueExtendedResponse ) extendedResponse ).setResponseValue( tlv.getValue().getData() );
+                }
+            }
+            else
+            {
+                factory.decodeValue( extendedResponse, tlv.getValue().getData() );
+            }
         }
-        else
+        catch ( DecoderException de )
         {
-            ( ( ExtendedResponseDecorator<ExtendedResponse> ) extendedResponse ).
-                setResponseValue( tlv.getValue().getData() );
+            String msg = I18n.err( I18n.ERR_05158_INVALID_REQUEST_VALUE,
+                Strings.dumpBytes( tlv.getValue().getData() ) );
+            LOG.error( I18n.err( I18n.ERR_05114_ERROR_MESSAGE, msg, de.getMessage() ) );
+
+            // Rethrow the exception, we will get a PROTOCOL_ERROR
+            throw de;
         }
 
         // We can have an END transition
@@ -82,7 +103,7 @@ public class StoreExtendedResponseValue extends GrammarAction<LdapMessageContain
 
         if ( LOG.isDebugEnabled() )
         {
-            LOG.debug( I18n.msg( I18n.MSG_05173_EXTENDED_VALUE, extendedResponse.getResponseValue() ) );
+            LOG.debug( I18n.msg( I18n.MSG_05173_EXTENDED_VALUE, Strings.dumpBytes( tlv.getValue().getData() ) ) );
         }
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/InitIntermediateResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/InitIntermediateResponse.java
index 007cb94..791ffaf 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/InitIntermediateResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/InitIntermediateResponse.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.response.intermediate;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.IntermediateResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.IntermediateResponse;
 import org.apache.directory.api.ldap.model.message.IntermediateResponseImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitIntermediateResponse extends GrammarAction<LdapMessageContainer<IntermediateResponseDecorator<?>>>
+public class InitIntermediateResponse extends GrammarAction<LdapMessageContainerDirect<IntermediateResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitIntermediateResponse.class );
@@ -55,13 +55,10 @@ public class InitIntermediateResponse extends GrammarAction<LdapMessageContainer
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<IntermediateResponseDecorator<?>> container )
+    public void action( LdapMessageContainerDirect<IntermediateResponse> container )
     {
         // Now, we can allocate the IntermediateResponse Object
-        IntermediateResponseDecorator intermediateResponse =
-            new IntermediateResponseDecorator( container.getLdapCodecService(),
-                new IntermediateResponseImpl( container.getMessageId() ) );
-        container.setMessage( intermediateResponse );
+        container.setMessage( new IntermediateResponseImpl( container.getMessageId() ) );
 
         if ( LOG.isDebugEnabled() )
         {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseName.java
index 45c18eb..6d3a64e 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseName.java
@@ -25,8 +25,8 @@ import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.asn1.util.Oid;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.IntermediateResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.IntermediateOperationFactory;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.IntermediateResponse;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -41,7 +41,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreIntermediateResponseName extends GrammarAction<LdapMessageContainer<IntermediateResponseDecorator<?>>>
+public class StoreIntermediateResponseName extends GrammarAction<LdapMessageContainerDirect<IntermediateResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreIntermediateResponseName.class );
@@ -58,7 +58,7 @@ public class StoreIntermediateResponseName extends GrammarAction<LdapMessageCont
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<IntermediateResponseDecorator<?>> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<IntermediateResponse> container ) throws DecoderException
     {
         // We can get the IntermediateResponse Object
         IntermediateResponse intermediateResponse = container.getMessage();
@@ -79,12 +79,27 @@ public class StoreIntermediateResponseName extends GrammarAction<LdapMessageCont
         {
             byte[] responseNameBytes = tlv.getValue().getData();
 
+            // Check if the OID is valid
             String oidStr = Strings.utf8ToString( responseNameBytes );
 
             if ( Oid.isOid( oidStr ) )
             {
-                Oid.isOid( oidStr );
-                intermediateResponse.setResponseName( oidStr );
+                // Get the factory
+                IntermediateOperationFactory intermediateFactory = 
+                    container.getLdapCodecService().getIntermediateResponseFactories().get( oidStr );
+                
+                if ( intermediateFactory != null )
+                {
+                    // Ok, let's create the new operation, which will replace
+                    // the one created during the init phase
+                    container.setMessage( intermediateFactory.newResponse() );
+                    container.setIntermediateFactory( intermediateFactory );
+                }
+                else
+                {
+                    // We simply store the OID in teh existing message
+                    intermediateResponse.setResponseName( oidStr );
+                }
             }
             else
             {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseValue.java
index 0c2d6cb..8a790e6 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/intermediate/StoreIntermediateResponseValue.java
@@ -20,11 +20,12 @@
 package org.apache.directory.api.ldap.codec.actions.response.intermediate;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.IntermediateResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.IntermediateOperationFactory;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.message.IntermediateResponse;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -41,7 +42,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreIntermediateResponseValue extends GrammarAction<LdapMessageContainer<IntermediateResponseDecorator<?>>>
+public class StoreIntermediateResponseValue extends GrammarAction<LdapMessageContainerDirect<IntermediateResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreIntermediateResponseValue.class );
@@ -58,7 +59,7 @@ public class StoreIntermediateResponseValue extends GrammarAction<LdapMessageCon
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<IntermediateResponseDecorator<?>> container )
+    public void action( LdapMessageContainerDirect<IntermediateResponse> container ) throws DecoderException
     {
         // We can get the IntermediateResponse Object
         IntermediateResponse intermediateResponse = container.getMessage();
@@ -68,13 +69,19 @@ public class StoreIntermediateResponseValue extends GrammarAction<LdapMessageCon
 
         // We have to handle the special case of a 0 length matched
         // value
-        if ( tlv.getLength() == 0 )
+        if ( tlv.getLength() >= 0 )
         {
-            intermediateResponse.setResponseValue( Strings.EMPTY_BYTES );
-        }
-        else
-        {
-            intermediateResponse.setResponseValue( tlv.getValue().getData() );
+            // let's decode
+            IntermediateOperationFactory intermediateFactory = container.getIntermediateFactory();
+            
+            if ( intermediateFactory != null )
+            {
+                intermediateFactory.decodeValue( intermediateResponse, tlv.getValue().getData() );
+            }
+            else
+            {
+                intermediateResponse.setResponseValue( tlv.getValue().getData() );
+            }
         }
 
         // We can have an END transition
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modify/InitModifyResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modify/InitModifyResponse.java
index 36be6ce..c383d74 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modify/InitModifyResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modify/InitModifyResponse.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.response.modify;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.ModifyResponse;
 import org.apache.directory.api.ldap.model.message.ModifyResponseImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitModifyResponse extends GrammarAction<LdapMessageContainer<ModifyResponseDecorator>>
+public class InitModifyResponse extends GrammarAction<LdapMessageContainerDirect<ModifyResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitModifyResponse.class );
@@ -55,11 +55,10 @@ public class InitModifyResponse extends GrammarAction<LdapMessageContainer<Modif
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<ModifyResponseDecorator> container )
+    public void action( LdapMessageContainerDirect<ModifyResponse> container )
     {
         // Now, we can allocate the ModifyResponse Object
-        ModifyResponseDecorator modifyResponse = new ModifyResponseDecorator(
-            container.getLdapCodecService(), new ModifyResponseImpl( container.getMessageId() ) );
+        ModifyResponse modifyResponse = new ModifyResponseImpl( container.getMessageId() );
         container.setMessage( modifyResponse );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modifydn/InitModifyDnResponse.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modifydn/InitModifyDnResponse.java
index aa2bea1..d839a1c 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modifydn/InitModifyDnResponse.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/modifydn/InitModifyDnResponse.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.response.modifydn;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnResponseDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.ModifyDnResponse;
 import org.apache.directory.api.ldap.model.message.ModifyDnResponseImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitModifyDnResponse extends GrammarAction<LdapMessageContainer<ModifyDnResponseDecorator>>
+public class InitModifyDnResponse extends GrammarAction<LdapMessageContainerDirect<ModifyDnResponse>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitModifyDnResponse.class );
@@ -54,11 +54,10 @@ public class InitModifyDnResponse extends GrammarAction<LdapMessageContainer<Mod
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<ModifyDnResponseDecorator> container )
+    public void action( LdapMessageContainerDirect<ModifyDnResponse> container )
     {
         // Now, we can allocate the ModifyDnResponse Object
-        ModifyDnResponseDecorator modifyDnResponse = new ModifyDnResponseDecorator(
-            container.getLdapCodecService(), new ModifyDnResponseImpl( container.getMessageId() ) );
+        ModifyDnResponse modifyDnResponse = new ModifyDnResponseImpl( container.getMessageId() );
         container.setMessage( modifyDnResponse );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/done/InitSearchResultDone.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/done/InitSearchResultDone.java
index 7d9242b..0686884 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/done/InitSearchResultDone.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/done/InitSearchResultDone.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.response.search.done;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultDoneDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.SearchResultDone;
 import org.apache.directory.api.ldap.model.message.SearchResultDoneImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSearchResultDone extends GrammarAction<LdapMessageContainer<SearchResultDoneDecorator>>
+public class InitSearchResultDone extends GrammarAction<LdapMessageContainerDirect<SearchResultDone>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitSearchResultDone.class );
@@ -55,11 +55,10 @@ public class InitSearchResultDone extends GrammarAction<LdapMessageContainer<Sea
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultDoneDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchResultDone> container )
     {
         // Now, we can allocate the SearchResultDone Object
-        SearchResultDoneDecorator searchResultDone = new SearchResultDoneDecorator(
-            container.getLdapCodecService(), new SearchResultDoneImpl( container.getMessageId() ) );
+        SearchResultDone searchResultDone = new SearchResultDoneImpl( container.getMessageId() );
         container.setMessage( searchResultDone );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/AddAttributeType.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/AddAttributeType.java
index 7189526..7d73f04 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/AddAttributeType.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/AddAttributeType.java
@@ -24,9 +24,11 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultEntryDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.entry.Attribute;
+import org.apache.directory.api.ldap.model.entry.DefaultAttribute;
 import org.apache.directory.api.ldap.model.exception.LdapException;
+import org.apache.directory.api.ldap.model.message.SearchResultEntry;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -45,7 +47,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AddAttributeType extends GrammarAction<LdapMessageContainer<SearchResultEntryDecorator>>
+public class AddAttributeType extends GrammarAction<LdapMessageContainerDirect<SearchResultEntry>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( AddAttributeType.class );
@@ -62,9 +64,9 @@ public class AddAttributeType extends GrammarAction<LdapMessageContainer<SearchR
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultEntryDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchResultEntry> container ) throws DecoderException
     {
-        SearchResultEntryDecorator searchResultEntry = container.getMessage();
+        SearchResultEntry searchResultEntry = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
@@ -80,7 +82,9 @@ public class AddAttributeType extends GrammarAction<LdapMessageContainer<SearchR
         {
             try
             {
-                searchResultEntry.addAttribute( tlv.getValue().getData() );
+                Attribute attribute = new DefaultAttribute( tlv.getValue().getData() );
+                container.setCurrentAttribute( attribute );
+                searchResultEntry.getEntry().put( attribute );
             }
             catch ( LdapException ine )
             {
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/InitSearchResultEntry.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/InitSearchResultEntry.java
index 72dee8f..875984f 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/InitSearchResultEntry.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/InitSearchResultEntry.java
@@ -21,8 +21,8 @@ package org.apache.directory.api.ldap.codec.actions.response.search.entry;
 
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultEntryDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.SearchResultEntry;
 import org.apache.directory.api.ldap.model.message.SearchResultEntryImpl;
 
 
@@ -34,7 +34,7 @@ import org.apache.directory.api.ldap.model.message.SearchResultEntryImpl;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSearchResultEntry extends GrammarAction<LdapMessageContainer<SearchResultEntryDecorator>>
+public class InitSearchResultEntry extends GrammarAction<LdapMessageContainerDirect<SearchResultEntry>>
 {
     /**
      * Instantiates a new action.
@@ -48,11 +48,10 @@ public class InitSearchResultEntry extends GrammarAction<LdapMessageContainer<Se
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultEntryDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchResultEntry> container )
     {
         // Now, we can allocate the SearchResultEntry Object
-        SearchResultEntryDecorator searchResultEntry = new SearchResultEntryDecorator(
-            container.getLdapCodecService(), new SearchResultEntryImpl( container.getMessageId() ) );
+        SearchResultEntry searchResultEntry = new SearchResultEntryImpl( container.getMessageId() );
         container.setMessage( searchResultEntry );
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultAttributeValue.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultAttributeValue.java
index f3ff2b5..b0a26f5 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultAttributeValue.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultAttributeValue.java
@@ -23,9 +23,10 @@ package org.apache.directory.api.ldap.codec.actions.response.search.entry;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultEntryDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.entry.Attribute;
 import org.apache.directory.api.ldap.model.exception.LdapException;
+import org.apache.directory.api.ldap.model.message.SearchResultEntry;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -42,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchResultAttributeValue extends GrammarAction<LdapMessageContainer<SearchResultEntryDecorator>>
+public class StoreSearchResultAttributeValue extends GrammarAction<LdapMessageContainerDirect<SearchResultEntry>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchResultAttributeValue.class );
@@ -59,20 +60,18 @@ public class StoreSearchResultAttributeValue extends GrammarAction<LdapMessageCo
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultEntryDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchResultEntry> container )
     {
-        SearchResultEntryDecorator searchResultEntry = container.getMessage();
+        Attribute currentAttribute = container.getCurrentAttribute();
 
         TLV tlv = container.getCurrentTLV();
 
         // Store the value
-        Object value = null;
-
         try
         {
             if ( tlv.getLength() == 0 )
             {
-                searchResultEntry.addAttributeValue( "" );
+                currentAttribute.add( "" );
 
                 if ( LOG.isDebugEnabled() )
                 {
@@ -81,9 +80,10 @@ public class StoreSearchResultAttributeValue extends GrammarAction<LdapMessageCo
             }
             else
             {
-                if ( container.isBinary( searchResultEntry.getCurrentAttribute().getId() ) )
+                if ( container.isBinary( container.getCurrentAttribute().getId() ) )
                 {
-                    value = tlv.getValue().getData();
+                    byte[] value = tlv.getValue().getData();
+                    currentAttribute.add( value );
 
                     if ( LOG.isDebugEnabled() )
                     {
@@ -92,7 +92,8 @@ public class StoreSearchResultAttributeValue extends GrammarAction<LdapMessageCo
                 }
                 else
                 {
-                    value = Strings.utf8ToString( tlv.getValue().getData() );
+                    String value = Strings.utf8ToString( tlv.getValue().getData() );
+                    currentAttribute.add( value );
 
                     if ( LOG.isDebugEnabled() )
                     {
@@ -100,7 +101,6 @@ public class StoreSearchResultAttributeValue extends GrammarAction<LdapMessageCo
                     }
                 }
 
-                searchResultEntry.addAttributeValue( value );
             }
         }
         catch ( LdapException le )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultEntryObjectName.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultEntryObjectName.java
index 37dc54e..fd6437a 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultEntryObjectName.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/entry/StoreSearchResultEntryObjectName.java
@@ -24,9 +24,9 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultEntryDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.exception.LdapInvalidDnException;
+import org.apache.directory.api.ldap.model.message.SearchResultEntry;
 import org.apache.directory.api.ldap.model.name.Dn;
 import org.apache.directory.api.util.Strings;
 import org.slf4j.Logger;
@@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreSearchResultEntryObjectName extends GrammarAction<LdapMessageContainer<SearchResultEntryDecorator>>
+public class StoreSearchResultEntryObjectName extends GrammarAction<LdapMessageContainerDirect<SearchResultEntry>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreSearchResultEntryObjectName.class );
@@ -61,18 +61,16 @@ public class StoreSearchResultEntryObjectName extends GrammarAction<LdapMessageC
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultEntryDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchResultEntry> container ) throws DecoderException
     {
-        SearchResultEntryDecorator searchResultEntry = container.getMessage();
+        SearchResultEntry searchResultEntry = container.getMessage();
 
         TLV tlv = container.getCurrentTLV();
 
-        Dn objectName = Dn.EMPTY_DN;
-
         // Store the value.
         if ( tlv.getLength() == 0 )
         {
-            searchResultEntry.setObjectName( objectName );
+            searchResultEntry.setObjectName( Dn.EMPTY_DN );
         }
         else
         {
@@ -81,7 +79,8 @@ public class StoreSearchResultEntryObjectName extends GrammarAction<LdapMessageC
 
             try
             {
-                objectName = new Dn( dnStr );
+                Dn objectName = new Dn( dnStr );
+                searchResultEntry.setObjectName( objectName );
             }
             catch ( LdapInvalidDnException ine )
             {
@@ -90,8 +89,6 @@ public class StoreSearchResultEntryObjectName extends GrammarAction<LdapMessageC
                 LOG.error( I18n.err( I18n.ERR_05114_ERROR_MESSAGE, msg, ine.getMessage() ) );
                 throw new DecoderException( msg, ine );
             }
-
-            searchResultEntry.setObjectName( objectName );
         }
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/InitSearchResultReference.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/InitSearchResultReference.java
index 72b03fc..07ee41a 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/InitSearchResultReference.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/InitSearchResultReference.java
@@ -22,8 +22,8 @@ package org.apache.directory.api.ldap.codec.actions.response.search.reference;
 
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultReferenceDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
+import org.apache.directory.api.ldap.model.message.SearchResultReference;
 import org.apache.directory.api.ldap.model.message.SearchResultReferenceImpl;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class InitSearchResultReference extends GrammarAction<LdapMessageContainer<SearchResultReferenceDecorator>>
+public class InitSearchResultReference extends GrammarAction<LdapMessageContainerDirect<SearchResultReference>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( InitSearchResultReference.class );
@@ -55,11 +55,10 @@ public class InitSearchResultReference extends GrammarAction<LdapMessageContaine
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultReferenceDecorator> container )
+    public void action( LdapMessageContainerDirect<SearchResultReference> container )
     {
         // Now, we can allocate the SearchResultReference Object
-        SearchResultReferenceDecorator searchResultReference = new SearchResultReferenceDecorator(
-            container.getLdapCodecService(), new SearchResultReferenceImpl( container.getMessageId() ) );
+        SearchResultReference searchResultReference = new SearchResultReferenceImpl( container.getMessageId() );
         container.setMessage( searchResultReference );
 
         if ( LOG.isDebugEnabled() )
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/StoreReference.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/StoreReference.java
index 42f4b9c..8586306 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/StoreReference.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/actions/response/search/reference/StoreReference.java
@@ -24,8 +24,7 @@ import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.grammar.GrammarAction;
 import org.apache.directory.api.asn1.ber.tlv.TLV;
 import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.LdapMessageContainer;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultReferenceDecorator;
+import org.apache.directory.api.ldap.codec.api.LdapMessageContainerDirect;
 import org.apache.directory.api.ldap.model.exception.LdapURLEncodingException;
 import org.apache.directory.api.ldap.model.message.Referral;
 import org.apache.directory.api.ldap.model.message.ReferralImpl;
@@ -44,7 +43,7 @@ import org.slf4j.LoggerFactory;
  * </pre>
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class StoreReference extends GrammarAction<LdapMessageContainer<SearchResultReferenceDecorator>>
+public class StoreReference extends GrammarAction<LdapMessageContainerDirect<SearchResultReference>>
 {
     /** The logger */
     private static final Logger LOG = LoggerFactory.getLogger( StoreReference.class );
@@ -61,7 +60,7 @@ public class StoreReference extends GrammarAction<LdapMessageContainer<SearchRes
     /**
      * {@inheritDoc}
      */
-    public void action( LdapMessageContainer<SearchResultReferenceDecorator> container ) throws DecoderException
+    public void action( LdapMessageContainerDirect<SearchResultReference> container ) throws DecoderException
     {
         SearchResultReference searchResultReference = container.getMessage();
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractControlFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractControlFactory.java
index acb7661..8bd4532 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractControlFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractControlFactory.java
@@ -19,6 +19,11 @@
  */
 package org.apache.directory.api.ldap.codec.api;
 
+import java.nio.ByteBuffer;
+
+import org.apache.directory.api.asn1.DecoderException;
+import org.apache.directory.api.asn1.ber.Asn1Container;
+import org.apache.directory.api.asn1.ber.Asn1Decoder;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.model.message.Control;
 
@@ -32,6 +37,9 @@ public abstract class AbstractControlFactory<C extends Control> implements Contr
 {
     /** The LDAP codec responsible for encoding and decoding ManageDsaIT Control */
     protected LdapApiService codec;
+    
+    /** The control's OID */
+    protected String oid;
 
     /**
      *
@@ -39,9 +47,10 @@ public abstract class AbstractControlFactory<C extends Control> implements Contr
      *
      * @param codec The LdapApiSevice instance
      */
-    protected AbstractControlFactory( LdapApiService codec )
+    protected AbstractControlFactory( LdapApiService codec, String oid )
     {
         this.codec = codec;
+        this.oid = oid;
     }
 
 
@@ -49,9 +58,39 @@ public abstract class AbstractControlFactory<C extends Control> implements Contr
      * {@inheritDoc}
      */
     @Override
+    public String getOid()
+    {
+        return oid;
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
     public void encodeValue( Asn1Buffer buffer, Control control )
     {
         // Nothing to do by default
     }
 
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void decodeValue( Control control, byte[] controlBytes ) throws DecoderException
+    {
+        // Nothing to do by default
+    }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void decodeValue( ControlContainer container, Control control, byte[] controlBytes ) throws DecoderException
+    {
+        ByteBuffer buffer = ByteBuffer.wrap( controlBytes );
+        container.setControl( control );
+        new Asn1Decoder().decode( buffer, ( Asn1Container ) container );
+    }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractExtendedOperationFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractExtendedOperationFactory.java
index 6ff23f3..74ec8db 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractExtendedOperationFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractExtendedOperationFactory.java
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.api.ldap.codec.api;
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.model.message.ExtendedRequest;
 import org.apache.directory.api.ldap.model.message.ExtendedResponse;
@@ -32,16 +33,51 @@ public abstract class AbstractExtendedOperationFactory implements ExtendedOperat
 {
     /** The LDAP codec responsible for encoding and decoding */
     protected LdapApiService codec;
+    
+    /** The extended operation OID */
+    protected String oid;
 
     /**
      *
      * Creates a new instance of AbstractExtendedOperationFactory.
      *
      * @param codec The LdapApiService instance
+     * @param oid The extended operation OID
      */
-    protected AbstractExtendedOperationFactory( LdapApiService codec )
+    protected AbstractExtendedOperationFactory( LdapApiService codec, String oid )
     {
         this.codec = codec;
+        this.oid = oid;
+    }
+    
+    
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public String getOid()
+    {
+        return oid;
+    }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public ExtendedRequest newRequest( byte[] value ) throws DecoderException
+    {
+        return null;
+    }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public ExtendedResponse newResponse( byte[] value ) throws DecoderException
+    {
+        return null;
     }
 
 
@@ -59,8 +95,28 @@ public abstract class AbstractExtendedOperationFactory implements ExtendedOperat
      * {@inheritDoc}
      */
     @Override
+    public void decodeValue( ExtendedRequest extendedRequest, byte[] requestValue ) throws DecoderException
+    {
+        // Nothing to do by default
+    }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
     public void encodeValue( Asn1Buffer buffer, ExtendedResponse extendedResponse )
     {
         // Nothing to do by default
     }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void decodeValue( ExtendedResponse extendedResponse, byte[] responseValue ) throws DecoderException
+    {
+        // Nothing to do by default
+    }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractIntermediateOperationFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractIntermediateOperationFactory.java
deleted file mode 100644
index a6d26af..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractIntermediateOperationFactory.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- *   Licensed to the Apache Software Foundation (ASF) under one
- *   or more contributor license agreements.  See the NOTICE file
- *   distributed with this work for additional information
- *   regarding copyright ownership.  The ASF licenses this file
- *   to you under the Apache License, Version 2.0 (the
- *   "License"); you may not use this file except in compliance
- *   with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- *   Unless required by applicable law or agreed to in writing,
- *   software distributed under the License is distributed on an
- *   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *   KIND, either express or implied.  See the License for the
- *   specific language governing permissions and limitations
- *   under the License.
- *
- */
-package org.apache.directory.api.ldap.codec.api;
-
-import org.apache.directory.api.asn1.util.Asn1Buffer;
-import org.apache.directory.api.ldap.model.message.IntermediateResponse;
-
-/**
- * A Factory to encode Intermediate Response message
- * 
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public abstract class AbstractIntermediateOperationFactory implements IntermediateOperationFactory
-{
-    /** The LDAP codec responsible for encoding and decoding Controls */
-    protected LdapApiService codec;
-
-    /**
-     *
-     * Creates a new instance of AbstractIntermediateOperationFactory.
-     *
-     * @param codec The LdapApiService instance
-     */
-    protected AbstractIntermediateOperationFactory( LdapApiService codec )
-    {
-        this.codec = codec;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void encodeValue( Asn1Buffer buffer, IntermediateResponse intermediateResponse )
-    {
-        // Nothing to do by default
-    }
-}
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractMessageDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractMessageDecorator.java
deleted file mode 100644
index f286756..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/AbstractMessageDecorator.java
+++ /dev/null
@@ -1,455 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- *
- */
-package org.apache.directory.api.ldap.codec.api;
-
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.apache.directory.api.ldap.codec.decorators.AbandonRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.AddRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.AddResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.BindRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.BindResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.CompareRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.CompareResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.DeleteRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.DeleteResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.IntermediateResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.ModifyDnResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.ModifyRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.ModifyResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.SearchRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultDoneDecorator;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultEntryDecorator;
-import org.apache.directory.api.ldap.codec.decorators.SearchResultReferenceDecorator;
-import org.apache.directory.api.ldap.codec.decorators.UnbindRequestDecorator;
-import org.apache.directory.api.ldap.model.message.AbandonRequest;
-import org.apache.directory.api.ldap.model.message.AddRequest;
-import org.apache.directory.api.ldap.model.message.AddResponse;
-import org.apache.directory.api.ldap.model.message.BindRequest;
-import org.apache.directory.api.ldap.model.message.BindResponse;
-import org.apache.directory.api.ldap.model.message.CompareRequest;
-import org.apache.directory.api.ldap.model.message.CompareResponse;
-import org.apache.directory.api.ldap.model.message.Control;
-import org.apache.directory.api.ldap.model.message.DeleteRequest;
-import org.apache.directory.api.ldap.model.message.DeleteResponse;
-import org.apache.directory.api.ldap.model.message.ExtendedRequest;
-import org.apache.directory.api.ldap.model.message.ExtendedResponse;
-import org.apache.directory.api.ldap.model.message.IntermediateResponse;
-import org.apache.directory.api.ldap.model.message.Message;
-import org.apache.directory.api.ldap.model.message.MessageTypeEnum;
-import org.apache.directory.api.ldap.model.message.ModifyDnRequest;
-import org.apache.directory.api.ldap.model.message.ModifyDnResponse;
-import org.apache.directory.api.ldap.model.message.ModifyRequest;
-import org.apache.directory.api.ldap.model.message.ModifyResponse;
-import org.apache.directory.api.ldap.model.message.Request;
-import org.apache.directory.api.ldap.model.message.SearchRequest;
-import org.apache.directory.api.ldap.model.message.SearchResultDone;
-import org.apache.directory.api.ldap.model.message.SearchResultEntry;
-import org.apache.directory.api.ldap.model.message.SearchResultReference;
-import org.apache.directory.api.ldap.model.message.UnbindRequest;
-
-
-/**
- * A decorator for the generic LDAP Message
- *
- * @param <E> The message to decorate
- *
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public abstract class AbstractMessageDecorator<E extends Message> implements Message, Decorator<E>
-{
-    /** The decorated Message */
-    protected E decoratedMessage;
-
-    /** Map of message controls using OID Strings for keys and Control values */
-    private final Map<String, Control> controls;
-
-    /** The encoded Message length */
-    protected int messageLength;
-
-    /** The length of the controls */
-    private int controlsLength;
-
-    /** The LdapCodecService */
-    private final LdapApiService codec;
-
-
-    /**
-     * Makes a Message an Decorator object.
-     *
-     * @param codec The LDAP Service instance to use
-     * @param decoratedMessage The message to decorate
-     */
-    protected AbstractMessageDecorator( LdapApiService codec, E decoratedMessage )
-    {
-        this.codec = codec;
-        this.decoratedMessage = decoratedMessage;
-        controls = new HashMap<>();
-
-        Map<String, Control> decoratedControls = decoratedMessage.getControls();
-
-        if ( ( decoratedControls != null ) && !decoratedControls.isEmpty() )
-        {
-            for ( Control control : decoratedControls.values() )
-            {
-                addControl( control );
-            }
-        }
-    }
-
-
-    /**
-     * Gets the decorator associated with a given message
-     *
-     * @param codec The LdapApiService to use
-     * @param decoratedMessage The message to decorate
-     * @return The decorator instance
-     */
-    public static AbstractMessageDecorator<? extends Message> getDecorator( LdapApiService codec, Message decoratedMessage )
-    {
-        if ( decoratedMessage instanceof AbstractMessageDecorator )
-        {
-            return ( AbstractMessageDecorator<?> ) decoratedMessage;
-        }
-
-        AbstractMessageDecorator<?> decorator;
-
-        switch ( decoratedMessage.getType() )
-        {
-            case ABANDON_REQUEST:
-                decorator = new AbandonRequestDecorator( codec, ( AbandonRequest ) decoratedMessage );
-                break;
-
-            case ADD_REQUEST:
-                decorator = new AddRequestDecorator( codec, ( AddRequest ) decoratedMessage );
-                break;
-
-            case ADD_RESPONSE:
-                decorator = new AddResponseDecorator( codec, ( AddResponse ) decoratedMessage );
-                break;
-
-            case BIND_REQUEST:
-                decorator = new BindRequestDecorator( codec, ( BindRequest ) decoratedMessage );
-                break;
-
-            case BIND_RESPONSE:
-                decorator = new BindResponseDecorator( codec, ( BindResponse ) decoratedMessage );
-                break;
-
-            case COMPARE_REQUEST:
-                decorator = new CompareRequestDecorator( codec, ( CompareRequest ) decoratedMessage );
-                break;
-
-            case COMPARE_RESPONSE:
-                decorator = new CompareResponseDecorator( codec, ( CompareResponse ) decoratedMessage );
-                break;
-
-            case DEL_REQUEST:
-                decorator = new DeleteRequestDecorator( codec, ( DeleteRequest ) decoratedMessage );
-                break;
-
-            case DEL_RESPONSE:
-                decorator = new DeleteResponseDecorator( codec, ( DeleteResponse ) decoratedMessage );
-                break;
-
-            case EXTENDED_REQUEST:
-                decorator = codec.decorate( ( ExtendedRequest ) decoratedMessage );
-                break;
-
-            case EXTENDED_RESPONSE:
-                decorator = codec.decorate( ( ExtendedResponse ) decoratedMessage );
-                break;
-
-            case INTERMEDIATE_RESPONSE:
-                decorator = new IntermediateResponseDecorator( codec, ( IntermediateResponse ) decoratedMessage );
-                break;
-
-            case MODIFY_REQUEST:
-                decorator = new ModifyRequestDecorator( codec, ( ModifyRequest ) decoratedMessage );
-                break;
-
-            case MODIFY_RESPONSE:
-                decorator = new ModifyResponseDecorator( codec, ( ModifyResponse ) decoratedMessage );
-                break;
-
-            case MODIFYDN_REQUEST:
-                decorator = new ModifyDnRequestDecorator( codec, ( ModifyDnRequest ) decoratedMessage );
-                break;
-
-            case MODIFYDN_RESPONSE:
-                decorator = new ModifyDnResponseDecorator( codec, ( ModifyDnResponse ) decoratedMessage );
-                break;
-
-            case SEARCH_REQUEST:
-                decorator = new SearchRequestDecorator( codec, ( SearchRequest ) decoratedMessage );
-                break;
-
-            case SEARCH_RESULT_DONE:
-                decorator = new SearchResultDoneDecorator( codec, ( SearchResultDone ) decoratedMessage );
-                break;
-
-            case SEARCH_RESULT_ENTRY:
-                decorator = new SearchResultEntryDecorator( codec, ( SearchResultEntry ) decoratedMessage );
-                break;
-
-            case SEARCH_RESULT_REFERENCE:
-                decorator = new SearchResultReferenceDecorator( codec, ( SearchResultReference ) decoratedMessage );
-                break;
-
-            case UNBIND_REQUEST:
-                decorator = new UnbindRequestDecorator( codec, ( UnbindRequest ) decoratedMessage );
-                break;
-
-            default:
-                return null;
-        }
-
-        Map<String, Control> controls = decoratedMessage.getControls();
-
-        if ( ( controls != null ) && !controls.isEmpty() )
-        {
-            for ( Control control : controls.values() )
-            {
-                decorator.addControl( control );
-            }
-        }
-
-        return decorator;
-    }
-
-
-    /**
-     * @param controlsLength the encoded controls length
-     */
-    public void setControlsLength( int controlsLength )
-    {
-        this.controlsLength = controlsLength;
-    }
-
-
-    /**
-     * @return the encoded controls length
-     */
-    public int getControlsLength()
-    {
-        return controlsLength;
-    }
-
-
-    /**
-     * @param messageLength The encoded message length
-     */
-    public void setMessageLength( int messageLength )
-    {
-        this.messageLength = messageLength;
-    }
-
-
-    /**
-     * @return The encoded message length
-     */
-    public int getMessageLength()
-    {
-        return messageLength;
-    }
-
-
-    //-------------------------------------------------------------------------
-    // The Message methods
-    //-------------------------------------------------------------------------
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public MessageTypeEnum getType()
-    {
-        return decoratedMessage.getType();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Map<String, Control> getControls()
-    {
-        return controls;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Control getControl( String oid )
-    {
-        return controls.get( oid );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public boolean hasControl( String oid )
-    {
-        return controls.containsKey( oid );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @SuppressWarnings("unchecked")
-    @Override
-    public Message addControl( Control control )
-    {
-        Control decorated;
-        CodecControl<? extends Control> controlDecorator;
-
-        if ( control instanceof ControlDecorator )
-        {
-            controlDecorator = ( org.apache.directory.api.ldap.codec.api.CodecControl<? extends Control> ) control;
-            decorated = controlDecorator.getDecorated();
-        }
-        else
-        {
-            if ( this instanceof Request )
-            {
-                controlDecorator = codec.newRequestControl( control );
-            }
-            else
-            {
-                controlDecorator = codec.newResponseControl( control );
-            }
-
-            decorated = control;
-        }
-
-        decoratedMessage.addControl( decorated );
-        controls.put( control.getOid(), controlDecorator );
-
-        return this;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Message addAllControls( Control[] controls )
-    {
-        for ( Control control : controls )
-        {
-            addControl( control );
-        }
-
-        return this;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Message removeControl( Control control )
-    {
-        decoratedMessage.removeControl( control );
-        controls.remove( control.getOid() );
-
-        return this;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public int getMessageId()
-    {
-        return decoratedMessage.getMessageId();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Object get( Object key )
-    {
-        return decoratedMessage.get( key );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Object put( Object key, Object value )
-    {
-        return decoratedMessage.put( key, value );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Message setMessageId( int messageId )
-    {
-        decoratedMessage.setMessageId( messageId );
-
-        return this;
-    }
-
-
-    /**
-     * Delegates to the toString() method of the decorated Message.
-     */
-    @Override
-    public String toString()
-    {
-        return decoratedMessage.toString();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public E getDecorated()
-    {
-        return decoratedMessage;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public LdapApiService getCodecService()
-    {
-        return codec;
-    }
-}
diff --git a/ldap/extras/codec/src/main/java/org/apache/directory/api/ldap/extras/extended/ads_impl/cancel/CancelResponseDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlContainer.java
similarity index 55%
rename from ldap/extras/codec/src/main/java/org/apache/directory/api/ldap/extras/extended/ads_impl/cancel/CancelResponseDecorator.java
rename to ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlContainer.java
index 3e8778d..a259118 100644
--- a/ldap/extras/codec/src/main/java/org/apache/directory/api/ldap/extras/extended/ads_impl/cancel/CancelResponseDecorator.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlContainer.java
@@ -17,29 +17,23 @@
  *   under the License.
  *
  */
-package org.apache.directory.api.ldap.extras.extended.ads_impl.cancel;
-
-
-import org.apache.directory.api.ldap.codec.decorators.ExtendedResponseDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.extras.extended.cancel.CancelResponse;
+package org.apache.directory.api.ldap.codec.api;
 
+import org.apache.directory.api.asn1.ber.Asn1Container;
+import org.apache.directory.api.ldap.model.message.Control;
 
 /**
- * A Decorator for CancelResponses.
- *
+ * An interface for the Control containers
+ * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class CancelResponseDecorator extends ExtendedResponseDecorator<CancelResponse> implements CancelResponse
+public interface ControlContainer extends Asn1Container
 {
     /**
-     * Creates a new instance of CancelResponseDecorator.
-     *
-     * @param codec The LDAP service instance
-     * @param decoratedMessage The decorated message
+     * Set a Control Object into the container. It will be completed by
+     * the ldapDecoder.
+     * 
+     * @param control the Control to set.
      */
-    public CancelResponseDecorator( LdapApiService codec, CancelResponse decoratedMessage )
-    {
-        super( codec, decoratedMessage );
-    }
+    void setControl( Control control );
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlFactory.java
index 1f5605e..8e12289 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ControlFactory.java
@@ -20,6 +20,7 @@
 package org.apache.directory.api.ldap.codec.api;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.model.message.Control;
 
@@ -43,22 +44,11 @@ public interface ControlFactory<C extends Control>
 
 
     /**
-     * Creates and returns a decorated version of the Control.
+     * Creates and returns a version of the Control.
      *
      * @return The {@link CodecControl} decorated version of the Control.
      */
-    CodecControl<C> newCodecControl();
-
-
-    /**
-     * Decorates an existing control. Implementors should check to make sure
-     * the supplied Control has not already been decorated to prevent needless
-     * decorator nesting.
-     *
-     * @param control The {@link Control} to be decorated.
-     * @return The decorator wrapping the Control.
-     */
-    CodecControl<C> newCodecControl( C control );
+    Control newControl();
 
 
     /**
@@ -68,4 +58,25 @@ public interface ControlFactory<C extends Control>
      * @param control The control to encode
      */
     void encodeValue( Asn1Buffer buffer, Control control );
+    
+    
+
+
+    /**
+     * Decode a Control's value. It will feed the Control.
+     * 
+     *  @param container The Asn1Container containing the control to feed
+     *  @param control The control to feed
+     *  @param controlBytes The data to decode
+     */
+    void decodeValue( ControlContainer container, Control control, byte[] controlBytes ) throws DecoderException;
+    
+    
+    /**
+     * Decode a Control's value. It will feed the Control.
+     * 
+     *  @param control The control to feed
+     *  @param controlBytes The data to decode
+     */
+    void decodeValue( Control control, byte[] controlBytes ) throws DecoderException;
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ExtendedOperationFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ExtendedOperationFactory.java
index 8be7ce5..d582226 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ExtendedOperationFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/ExtendedOperationFactory.java
@@ -22,7 +22,6 @@ package org.apache.directory.api.ldap.codec.api;
 
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedRequestDecorator;
 import org.apache.directory.api.ldap.model.message.ExtendedRequest;
 import org.apache.directory.api.ldap.model.message.ExtendedResponse;
 
@@ -45,21 +44,29 @@ public interface ExtendedOperationFactory
 
 
     /**
-     * Returns a new {@link ExtendedRequestDecorator} with the following encoded value.
+     * Returns a new {@link ExtendedRequest} with no value
+     * 
+     * @return the decorator for the extended request type
+     */
+    ExtendedRequest newRequest();
+
+
+    /**
+     * Returns a new {@link ExtendedRequest} with the following encoded value.
      * 
      * @param value the encoded value
      * @return the decorator for the extended request type
+     * @throws DecoderException If we can't decode the response
      */
-    ExtendedRequest newRequest( byte[] value );
+    ExtendedRequest newRequest( byte[] value ) throws DecoderException;
 
 
     /**
-     * Decorates a non-decorated request.
-     *
-     * @param modelRequest the non decorated model request
-     * @return the decorated model request
+     * Creates a new ExtendedResponse, for the ExtendedRequest with no value
+     * 
+     * @return The new ExtendedResponse.
      */
-    ExtendedRequest decorate( ExtendedRequest modelRequest );
+    ExtendedResponse newResponse() throws DecoderException;
 
 
     /**
@@ -74,22 +81,21 @@ public interface ExtendedOperationFactory
 
 
     /**
-     * Decorates an ExtendedResponse which may or may not be of the expected 
-     * type. The factory implementor must check and handle appropriately.
+     * Encode the value part of the extended request operation.
      *
-     * @param decoratedMessage the message to be decorated.
-     * @return The decorated message 
+     * @param buffer The buffer into which to put the encoded value
+     * @param extendedRequest The ExtendedRequest Operation to encode
      */
-    ExtendedResponse decorate( ExtendedResponse decoratedMessage );
+    void encodeValue( Asn1Buffer buffer, ExtendedRequest extendedRequest );
 
 
     /**
-     * Encode the value part of the extended request operation.
+     * Decode the value part of the extended request operation.
      *
-     * @param buffer The buffer into which to put the encoded value
-     * @param extendedRequest The ExtendedRequest Operation to encode
+     * @param extendedRequest The ExtendedRequest Operation to feed
+     * @param requestValue The request value to decode
      */
-    void encodeValue( Asn1Buffer buffer, ExtendedRequest extendedRequest );
+    void decodeValue( ExtendedRequest extendedRequest, byte[] requestValue ) throws DecoderException;
 
 
     /**
@@ -99,4 +105,13 @@ public interface ExtendedOperationFactory
      * @param extendedResponse The ExtendedResponse Operation to encode
      */
     void encodeValue( Asn1Buffer buffer, ExtendedResponse extendedResponse );
+
+
+    /**
+     * Decode the value part of the extended response operation.
+     *
+     * @param extendedResponse The ExtendedResponse Operation to feed
+     * @param responseValue The response value to decode
+     */
+    void decodeValue( ExtendedResponse extendedResponse, byte[] responseValue ) throws DecoderException;
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/IntermediateOperationFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/IntermediateOperationFactory.java
index 4ad6a64..6347680 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/IntermediateOperationFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/IntermediateOperationFactory.java
@@ -20,6 +20,7 @@
 package org.apache.directory.api.ldap.codec.api;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.model.message.IntermediateResponse;
 
@@ -41,23 +42,20 @@ public interface IntermediateOperationFactory
 
 
     /**
-     * Returns a new {@link IntermediateResponse} with the following encoded value.
+     * Returns a new {@link IntermediateResponse} with no value.
      * 
-     * @param value the encoded value
-     * @return the decorator for the extended response type
+     * @return the extended response type
      */
-    IntermediateResponse newResponse( byte[] value );
+    IntermediateResponse newResponse();
 
 
     /**
-     * Decorates an IntermediateResponse which may or may not be of the expected 
-     * type. The factory implementor must check and handle appropriately.
-     *
-     * @param decoratedMessage the message to be decorated.
-     * @return The decorated message 
+     * Returns a new {@link IntermediateResponse} with the following encoded value.
+     * 
+     * @param value the encoded value
+     * @return the extended response type
      */
-    IntermediateResponse decorate( IntermediateResponse decoratedMessage );
-    
+    IntermediateResponse newResponse( byte[] value );
 
 
     /**
@@ -67,4 +65,13 @@ public interface IntermediateOperationFactory
      * @param IntermediateResponse The IntermediateResponse Operation to encode
      */
     void encodeValue( Asn1Buffer buffer, IntermediateResponse intermediateResponse );
+
+
+    /**
+     * Decode the value part of the intermediate response operation.
+     *
+     * @param IntermediateResponse The IntermediateResponse Operation to feed
+     * @param responseValue The response bvalue to decode
+     */
+    void decodeValue( IntermediateResponse intermediateResponse, byte[] responseValue ) throws DecoderException;
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapApiService.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapApiService.java
index f6b4d03..c1c2d1e 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapApiService.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapApiService.java
@@ -25,14 +25,9 @@ import java.util.Map;
 
 import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.asn1.ber.Asn1Container;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedRequestDecorator;
-import org.apache.directory.api.ldap.codec.decorators.ExtendedResponseDecorator;
-import org.apache.directory.api.ldap.codec.decorators.IntermediateResponseDecorator;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.ExtendedRequest;
 import org.apache.directory.api.ldap.model.message.ExtendedResponse;
-import org.apache.directory.api.ldap.model.message.IntermediateResponse;
 import org.apache.mina.filter.codec.ProtocolCodecFactory;
 
 
@@ -116,42 +111,6 @@ public interface LdapApiService
 
 
     /**
-     * Creates a new request codec control decorator of the specified type.
-     *
-     * @param oid The OID of the new control to create.
-     * @return The newly created codec control.
-     */
-    CodecControl<? extends Control> newRequestControl( String oid );
-
-
-    /**
-     * Creates a new response codec control decorator of the specified type.
-     *
-     * @param oid The OID of the new control to create.
-     * @return The newly created codec control.
-     */
-    CodecControl<? extends Control> newResponseControl( String oid );
-
-
-    /**
-     * Creates a new request codec control decorator for the provided control.
-     *
-     * @param control The control the codec control is generated for.
-     * @return The newly created codec control.
-     */
-    CodecControl<? extends Control> newRequestControl( Control control );
-
-
-    /**
-     * Creates a new response codec control decorator for the provided control.
-     *
-     * @param control The control the codec control is generated for.
-     * @return The newly created codec control.
-     */
-    CodecControl<? extends Control> newResponseControl( Control control );
-
-
-    /**
      * Creates a JNDI control from the ldap model's control.
      *
      * @param modelControl The model's control.
@@ -397,81 +356,4 @@ public interface LdapApiService
      * none had been set earlier.
      */
     ProtocolCodecFactory registerProtocolCodecFactory( ProtocolCodecFactory factory );
-
-
-    /**
-     * Creates a new MessageContainer.
-     *
-     * @return The newly created LDAP MessageContainer instance.
-     */
-    Asn1Container newMessageContainer();
-
-
-    /**
-     * Create an instance of a ExtendedResponse, knowing its OID. Inject the payload
-     * into it.
-     *
-     * @param responseName The extendedRespose OID
-     * @param messageId The original message ID
-     * @param serializedResponse The serialized response payload
-     * @param <E> The extended response type
-     * @return The extendedResponse instance
-     *
-     * @throws DecoderException If the payload is incorrect
-     */
-    <E extends ExtendedResponse> E newExtendedResponse( String responseName, int messageId, byte[] serializedResponse )
-        throws DecoderException;
-
-
-    /**
-     * Creates a new ExtendedRequest instance.
-     *
-     * @param oid the extended request's object identifier
-     * @param value the encoded value of the extended request
-     * @return The new extended request
-     */
-    ExtendedRequest newExtendedRequest( String oid, byte[] value );
-
-
-    /**
-     * Create an instance of a IntermediateResponse, knowing its OID. Inject the payload
-     * into it.
-     *
-     * @param responseName The intermediateRespose OID
-     * @param messageId The original message ID
-     * @param serializedResponse The serialized response payload
-     * @param <I> The intermediate response type
-     * @return The intermediateResponse instance
-     *
-     * @throws DecoderException If the payload is incorrect
-     */
-    <I extends IntermediateResponse> I newIntermediateResponse( String responseName, int messageId, byte[] serializedResponse )
-        throws DecoderException;
-
-
-    /**
-     * Decorates an extended request message, ie encapsulate it into a class that do the encoding/decoding
-     *
-     * @param decoratedMessage The extended request to decorate
-     * @return The decorated extended request
-     */
-    ExtendedRequestDecorator<?> decorate( ExtendedRequest decoratedMessage );
-
-
-    /**
-     * Decorates an extended response message, ie encapsulate it into a class that do the encoding/decoding
-     *
-     * @param decoratedMessage The extended response to decorate
-     * @return The decorated extended response
-     */
-    ExtendedResponseDecorator<?> decorate( ExtendedResponse decoratedMessage );
-
-
-    /**
-     * Decorates an intermediate response message, ie encapsulate it into a class that do the encoding/decoding
-     *
-     * @param decoratedMessage The intermediate response to decorate
-     * @return The decorated intermediate response
-     */
-    IntermediateResponseDecorator<?> decorate( IntermediateResponse decoratedMessage );
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapDecoder.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapDecoder.java
index fac893f..1ac99ad 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapDecoder.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapDecoder.java
@@ -70,7 +70,7 @@ public class LdapDecoder
      * @return return The decoded message
      * @throws DecoderException If the decoding failed
      */
-    public Message decode( InputStream in, LdapMessageContainer<AbstractMessageDecorator<? extends Message>> container )
+    public Message decode( InputStream in, LdapMessageContainerDirect<? extends Message> container )
         throws DecoderException
     {
         try
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapEncoder.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapEncoder.java
index 97e0dd6..4fcf42d 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapEncoder.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapEncoder.java
@@ -376,177 +376,6 @@ public final class LdapEncoder
 
 
     /**
-     * Generate the PDU which contains the encoded object.
-     *
-     * The generation is done in two phases :
-     * - first, we compute the length of each part and the
-     * global PDU length
-     * - second, we produce the PDU.
-     *
-     * <pre>
-     * 0x30 L1
-     *   |
-     *   +--&gt; 0x02 L2 MessageId
-     *   +--&gt; ProtocolOp
-     *   +--&gt; Controls
-     *
-     * L2 = Length(MessageId)
-     * L1 = Length(0x02) + Length(L2) + L2 + Length(ProtocolOp) + Length(Controls)
-     * LdapMessageLength = Length(0x30) + Length(L1) + L1
-     * </pre>
-     *
-     * @param message The message to encode
-     * @return A ByteBuffer that contains the PDU
-     * @throws EncoderException If anything goes wrong.
-     */
-    public static ByteBuffer encodeMessage( LdapApiService codec, Message message ) throws EncoderException
-    {
-        AbstractMessageDecorator<? extends Message> decorator = AbstractMessageDecorator.getDecorator( codec, message );
-        int length = computeMessageLength( decorator );
-
-        ByteBuffer buffer = ByteBuffer.allocate( length );
-
-        try
-        {
-            try
-            {
-                // The LdapMessage Sequence
-                buffer.put( UniversalTag.SEQUENCE.getValue() );
-
-                // The length has been calculated by the computeLength method
-                buffer.put( TLV.getBytes( decorator.getMessageLength() ) );
-            }
-            catch ( BufferOverflowException boe )
-            {
-                throw new EncoderException( I18n.err( I18n.ERR_08212_PDU_BUFFER_TOO_SMALL ), boe );
-            }
-
-            // The message Id
-            BerValue.encode( buffer, message.getMessageId() );
-
-            // Add the protocolOp part
-            decorator.encode( buffer );
-
-            // Do the same thing for Controls, if any.
-            Map<String, Control> controls = decorator.getControls();
-
-            if ( ( controls != null ) && ( controls.size() > 0 ) )
-            {
-                // Encode the controls
-                buffer.put( ( byte ) LdapCodecConstants.CONTROLS_TAG );
-                buffer.put( TLV.getBytes( decorator.getControlsLength() ) );
-
-                // Encode each control
-                for ( Control control : controls.values() )
-                {
-                    encodeControl( buffer, control );
-
-                    // The OctetString tag if the value is not null
-                    int controlValueLength = ( ( CodecControl<?> ) control ).computeLength();
-
-                    if ( controlValueLength > 0 )
-                    {
-                        buffer.put( UniversalTag.OCTET_STRING.getValue() );
-                        buffer.put( TLV.getBytes( controlValueLength ) );
-
-                        // And now, the value
-                        ( ( org.apache.directory.api.ldap.codec.api.CodecControl<?> ) control ).encode( buffer );
-                    }
-                }
-            }
-        }
-        catch ( EncoderException ee )
-        {
-            throw new MessageEncoderException( message.getMessageId(), ee.getMessage(), ee );
-        }
-
-        buffer.flip();
-
-        return buffer;
-    }
-
-
-    /**
-     * Compute the LdapMessage length LdapMessage :
-     * <pre>
-     * 0x30 L1
-     *   |
-     *   +--&gt; 0x02 0x0(1-4) [0..2^31-1] (MessageId)
-     *   +--&gt; protocolOp
-     *   [+--&gt; Controls]
-     *
-     * MessageId length = Length(0x02) + length(MessageId) + MessageId.length
-     * L1 = length(ProtocolOp)
-     * LdapMessage length = Length(0x30) + Length(L1) + MessageId length + L1
-     * </pre>
-     *
-     * @param messageDecorator the decorated Message who's length is to be encoded
-     * @return The message length
-     */
-    private static int computeMessageLength( AbstractMessageDecorator<? extends Message> messageDecorator )
-    {
-        // The length of the MessageId. It's the sum of
-        // - the tag (0x02), 1 byte
-        // - the length of the Id length, 1 byte
-        // - the Id length, 1 to 4 bytes
-        int ldapMessageLength = 1 + 1 + BerValue.getNbBytes( messageDecorator.getDecorated().getMessageId() );
-
-        // Get the protocolOp length
-        ldapMessageLength += messageDecorator.computeLength();
-
-        Map<String, Control> controls = messageDecorator.getControls();
-
-        // Do the same thing for Controls, if any.
-        if ( !controls.isEmpty() )
-        {
-            // Controls :
-            // 0xA0 L3
-            //   |
-            //   +--> 0x30 L4
-            //   +--> 0x30 L5
-            //   +--> ...
-            //   +--> 0x30 Li
-            //   +--> ...
-            //   +--> 0x30 Ln
-            //
-            // L3 = Length(0x30) + Length(L5) + L5
-            // + Length(0x30) + Length(L6) + L6
-            // + ...
-            // + Length(0x30) + Length(Li) + Li
-            // + ...
-            // + Length(0x30) + Length(Ln) + Ln
-            //
-            // LdapMessageLength = LdapMessageLength + Length(0x90)
-            // + Length(L3) + L3
-            int controlsSequenceLength = 0;
-
-            // We may have more than one control. ControlsLength is L4.
-            for ( Control control : controls.values() )
-            {
-                int controlLength = computeControlLength( control );
-
-                controlsSequenceLength += 1 + TLV.getNbBytes( controlLength ) + controlLength;
-            }
-
-            // Computes the controls length
-            // 1 + Length.getNbBytes( controlsSequenceLength ) + controlsSequenceLength
-            messageDecorator.setControlsLength( controlsSequenceLength );
-
-            // Now, add the tag and the length of the controls length
-            ldapMessageLength += 1 + TLV.getNbBytes( controlsSequenceLength ) + controlsSequenceLength;
-        }
-
-        // Store the messageLength
-        messageDecorator.setMessageLength( ldapMessageLength );
-
-        // finally, calculate the global message size :
-        // length(Tag) + Length(length) + length
-
-        return 1 + ldapMessageLength + TLV.getNbBytes( ldapMessageLength );
-    }
-
-
-    /**
      * Encode the Referral message to a PDU.
      *
      * @param buffer The buffer where to put the PDU
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainer.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainer.java
index c401f9b..14e0689 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainer.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainer.java
@@ -37,7 +37,7 @@ import org.apache.directory.api.ldap.model.message.Message;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class LdapMessageContainer<E extends AbstractMessageDecorator<? extends Message>> extends AbstractContainer
+public class LdapMessageContainer<E extends Message> extends AbstractContainer
 {
     /** The Message decorator to store various temporary values */
     private E messageDecorator;
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainerDirect.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainerDirect.java
new file mode 100644
index 0000000..fd3f135
--- /dev/null
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/api/LdapMessageContainerDirect.java
@@ -0,0 +1,544 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ * 
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ * 
+ */
+package org.apache.directory.api.ldap.codec.api;
+
+
+import org.apache.directory.api.asn1.DecoderException;
+import org.apache.directory.api.asn1.ber.AbstractContainer;
+import org.apache.directory.api.asn1.ber.tlv.TLV;
+import org.apache.directory.api.ldap.codec.LdapMessageGrammar;
+import org.apache.directory.api.ldap.codec.LdapStatesEnum;
+import org.apache.directory.api.ldap.codec.search.ConnectorFilter;
+import org.apache.directory.api.ldap.codec.search.Filter;
+import org.apache.directory.api.ldap.codec.search.PresentFilter;
+import org.apache.directory.api.ldap.model.entry.Attribute;
+import org.apache.directory.api.ldap.model.entry.Modification;
+import org.apache.directory.api.ldap.model.message.Control;
+import org.apache.directory.api.ldap.model.message.ExtendedResponse;
+import org.apache.directory.api.ldap.model.message.LdapResult;
+import org.apache.directory.api.ldap.model.message.Message;
+import org.apache.directory.api.ldap.model.message.ResultResponse;
+
+
+/**
+ * The LdapMessage container stores all the messages decoded by the Asn1Decoder.
+ * When dealing with an encoding PDU, we will obtain a LdapMessage in the
+ * container.
+ *
+ * @param <E> The decorated message
+ * 
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ */
+public class LdapMessageContainerDirect<E extends Message> extends AbstractContainer
+{
+    /** The Message being decoded */
+    private E message;
+
+    /** checks if attribute is binary */
+    private BinaryAttributeDetector binaryAttributeDetector;
+
+    /** The message ID */
+    private int messageId;
+
+    /** The current control */
+    private Control currentControl;
+    
+    /** The current control factory, if any */
+    private ControlFactory<?> controlFactory;
+    
+    /** The current Intermediate response factory */
+    private IntermediateOperationFactory intermediateFactory;
+    
+    /** The current Extended operation factory */
+    private ExtendedOperationFactory extendedFactory;
+
+    /** The codec service */
+    private final LdapApiService codec;
+    
+    /** The current LdapResult for a response */
+    private LdapResult ldapResult;
+    
+    /** The current attribute being decoded */
+    private Attribute currentAttribute;
+
+    /** A local storage for the MODIFY operation */
+    private Modification currentModification;
+    
+    /** The SearchRequest TLV id */
+    private int tlvId;
+
+    /** A temporary storage for a terminal Filter */
+    private Filter terminalFilter;
+
+    /** The current filter. This is used while decoding a PDU */
+    private Filter currentFilter;
+
+    /** The global filter. This is used while decoding a PDU */
+    private Filter topFilter;
+
+
+    /**
+     * Creates a new LdapMessageContainer object. We will store ten grammars,
+     * it's enough ...
+     * 
+     * @param codec The LDAP service instance
+     */
+    public LdapMessageContainerDirect( LdapApiService codec )
+    {
+        this( codec, new DefaultConfigurableBinaryAttributeDetector() );
+    }
+
+
+    /**
+     * Creates a new LdapMessageContainer object. 
+     *
+     * @param codec The LDAP service instance
+     * @param binaryAttributeDetector checks if an attribute is binary
+     */
+    public LdapMessageContainerDirect( LdapApiService codec, BinaryAttributeDetector binaryAttributeDetector )
+    {
+        super();
+        this.codec = codec;
+        setGrammar( LdapMessageGrammar.getInstance() );
+        this.binaryAttributeDetector = binaryAttributeDetector;
+        setTransition( LdapStatesEnum.START_STATE );
+    }
+
+
+    /**
+     * Gets the {@link LdapApiService} associated with this Container.
+     *
+     * @return The LDAP service instance
+     */
+    public LdapApiService getLdapCodecService()
+    {
+        return codec;
+    }
+
+
+    /**
+     * @return Returns the ldapMessage.
+     */
+    public E getMessage()
+    {
+        return message;
+    }
+
+
+    /**
+     * Set a Message Object into the container. It will be completed by the
+     * ldapDecoder.
+     *
+     * @param message The message to set.
+     */
+    public void setMessage( E message )
+    {
+        this.message = message;
+    }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void clean()
+    {
+        super.clean();
+
+        messageId = -1;
+        tlvId = -1;
+        message = null;
+        ldapResult = null;
+        currentControl = null;
+        currentAttribute = null;
+        currentFilter = null;
+        terminalFilter = null;
+        topFilter = null;
+        controlFactory = null;
+        intermediateFactory = null;
+        extendedFactory = null;
+        setDecodedBytes( 0 );
+    }
+
+
+    /**
+     * @return Returns true if the attribute is binary.
+     * @param id checks if an attribute id is binary
+     */
+    public boolean isBinary( String id )
+    {
+        return binaryAttributeDetector.isBinary( id );
+    }
+
+
+    /**
+     * @return The message ID
+     */
+    public int getMessageId()
+    {
+        return messageId;
+    }
+
+
+    /**
+     * Set the message ID
+     * @param messageId the id of the message
+     */
+    public void setMessageId( int messageId )
+    {
+        this.messageId = messageId;
+    }
+
+
+    /**
+     * @return the current control being created
+     */
+    public Control getCurrentControl()
+    {
+        return currentControl;
+    }
+
+
+    /**
+     * Store a newly created control
+     * @param currentControl The control to store
+     */
+    public void setCurrentControl( Control currentControl )
+    {
+        this.currentControl = currentControl;
+    }
+
+
+    /**
+     * Sets the binary attribute detector
+     * 
+     * @param binaryAttributeDetector the binary attribute detector
+     */
+    public void setBinaryAttributeDetector( BinaryAttributeDetector binaryAttributeDetector )
+    {
+        this.binaryAttributeDetector = binaryAttributeDetector;
+    }
+
+
+    /**
+     * @return the binary attribute detector
+     */
+    public BinaryAttributeDetector getBinaryAttributeDetector()
+    {
+        return binaryAttributeDetector;
+    }
+
+
+    /**
+     * @return the ldapResult
+     */
+    public LdapResult getLdapResult()
+    {
+        return ldapResult;
+    }
+
+
+    /**
+     * @param ldapResult the ldapResult to set
+     */
+    public void setLdapResult( LdapResult ldapResult )
+    {
+        this.ldapResult = ldapResult;
+    }
+
+
+    /**
+     * @return the controlFactory
+     */
+    public ControlFactory<?> getControlFactory()
+    {
+        return controlFactory;
+    }
+
+
+    /**
+     * @param controlFactory the controlFactory to set
+     */
+    public void setControlFactory( ControlFactory<?> controlFactory )
+    {
+        this.controlFactory = controlFactory;
+    }
+
+
+    /**
+     * @return the currentAttribute
+     */
+    public Attribute getCurrentAttribute()
+    {
+        return currentAttribute;
+    }
+
+
+    /**
+     * @param currentAttribute the currentAttribute to set
+     */
+    public void setCurrentAttribute( Attribute currentAttribute )
+    {
+        this.currentAttribute = currentAttribute;
+    }
+
+
+    /**
+     * @return the currentModification
+     */
+    public Modification getCurrentModification()
+    {
+        return currentModification;
+    }
+
+
+    /**
+     * @param currentModification the currentModification to set
+     */
+    public void setCurrentModification( Modification currentModification )
+    {
+        this.currentModification = currentModification;
+    }
+
+
+    /**
+     * Set the SearchRequest PDU TLV's Id
+     * @param tlvId The TLV id
+     */
+    public void setTlvId( int tlvId )
+    {
+        this.tlvId = tlvId;
+    }
+
+
+    /**
+     * @return the terminalFilter
+     */
+    public Filter getTerminalFilter()
+    {
+        return terminalFilter;
+    }
+
+
+    /**
+     * @param terminalFilter the terminalFilter to set
+     */
+    public void setTerminalFilter( Filter terminalFilter )
+    {
+        this.terminalFilter = terminalFilter;
+    }
+
+
+    /**
+     * @return the currentFilter
+     */
+    public Filter getCurrentFilter()
+    {
+        return currentFilter;
+    }
+
+
+    /**
+     * @param currentFilter the currentFilter to set
+     */
+    public void setCurrentFilter( Filter currentFilter )
+    {
+        this.currentFilter = currentFilter;
+    }
+
+
+    /**
+     * Add a current filter. We have two cases :
+     * - there is no previous current filter : the filter
+     * is the top level filter
+     * - there is a previous current filter : the filter is added
+     * to the currentFilter set, and the current filter is changed
+     *
+     * In any case, the previous current filter will always be a
+     * ConnectorFilter when this method is called.
+     *
+     * @param localFilter The filter to set.
+     * @throws DecoderException If the filter is invalid
+     */
+    public void addCurrentFilter( Filter localFilter ) throws DecoderException
+    {
+        if ( currentFilter != null )
+        {
+            // Ok, we have a parent. The new Filter will be added to
+            // this parent, and will become the currentFilter if it's a connector.
+            ( ( ConnectorFilter ) currentFilter ).addFilter( localFilter );
+            localFilter.setParent( currentFilter, currentFilter.getTlvId() );
+
+            if ( localFilter instanceof ConnectorFilter )
+            {
+                currentFilter = localFilter;
+            }
+        }
+        else
+        {
+            // No parent. This Filter will become the root.
+            currentFilter = localFilter;
+            currentFilter.setParent( null, tlvId );
+            topFilter = localFilter;
+        }
+    }
+
+
+    /**
+     * This method is used to clear the filter's stack for terminated elements. An element
+     * is considered as terminated either if :
+     *  - it's a final element (ie an element which cannot contains a Filter)
+     *  - its current length equals its expected length.
+     *
+     * @param container The container being decoded
+     */
+    public void unstackFilters()
+    {
+        TLV tlv = getCurrentTLV();
+        TLV localParent = tlv.getParent();
+        Filter localFilter = terminalFilter;
+
+        // The parent has been completed, so fold it
+        while ( ( localParent != null ) && ( localParent.getExpectedLength() == 0 ) )
+        {
+            int parentTlvId = localFilter.getParent() != null ? localFilter.getParent().getTlvId() : localFilter
+                .getParentTlvId();
+
+            if ( localParent.getId() != parentTlvId )
+            {
+                localParent = localParent.getParent();
+            }
+            else
+            {
+                Filter filterParent = localFilter.getParent();
+
+                // We have a special case with PresentFilter, which has not been
+                // pushed on the stack, so we need to get its parent's parent
+                if ( localFilter instanceof PresentFilter )
+                {
+                    if ( filterParent == null )
+                    {
+                        // We don't have parent, get out
+                        break;
+                    }
+
+                    filterParent = filterParent.getParent();
+                }
+                else
+                {
+                    filterParent = filterParent.getParent();
+                }
+
+                if ( filterParent != null )
+                {
+                    // The parent is a filter ; it will become the new currentFilter
+                    // and we will loop again.
+                    localFilter = currentFilter;
+                    currentFilter = filterParent;
+                    localParent = localParent.getParent();
+                }
+                else
+                {
+                    // We can stop the recursion, we have reached the searchResult Object
+                    break;
+                }
+            }
+        }
+    }
+    
+    
+    /**
+     * Copy the LdapResult element from a opaque response to a newly created 
+     * extendedResponse
+     *  
+     * @param resultResponse The original response
+     * @param extendedResponse The newly created ExtendedResponse
+     */
+    public static void copyLdapResult( ResultResponse resultResponse, ExtendedResponse extendedResponse )
+    {
+        extendedResponse.getLdapResult().setDiagnosticMessage( resultResponse.getLdapResult().getDiagnosticMessage() );
+        extendedResponse.getLdapResult().setMatchedDn( resultResponse.getLdapResult().getMatchedDn() );
+        extendedResponse.getLdapResult().setReferral( resultResponse.getLdapResult().getReferral() );
+        extendedResponse.getLdapResult().setResultCode( resultResponse.getLdapResult().getResultCode() );
+    }
+
+
+    /**
+     * @return the topFilter
+     */
+    public Filter getTopFilter()
+    {
+        return topFilter;
+    }
+
+
+    /**
+     * @param topFilter the topFilter to set
+     */
+    public void setTopFilter( Filter topFilter )
+    {
+        this.topFilter = topFilter;
+    }
+
+
+    /**
+     * @return the tlvId
+     */
+    public int getTlvId()
+    {
+        return tlvId;
+    }
+
+
+    /**
+     * @return the intermediateFactory
+     */
+    public IntermediateOperationFactory getIntermediateFactory()
+    {
+        return intermediateFactory;
+    }
+
+
+    /**
+     * @param intermediateFactory the intermediateFactory to set
+     */
+    public void setIntermediateFactory( IntermediateOperationFactory intermediateFactory )
+    {
+        this.intermediateFactory = intermediateFactory;
+    }
+
+
+    /**
+     * @return the extendedFactory
+     */
+    public ExtendedOperationFactory getExtendedFactory()
+    {
+        return extendedFactory;
+    }
+
+
+    /**
+     * @param extendedFactory the extendedFactory to set
+     */
+    public void setExtendedFactory( ExtendedOperationFactory extendedFactory )
+    {
+        this.extendedFactory = extendedFactory;
+    }
+}
diff --git a/ldap/extras/codec/src/main/java/org/apache/directory/api/ldap/extras/controls/ad_impl/AdShowDeletedFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/OpaqueControlFactory.java
similarity index 60%
copy from ldap/extras/codec/src/main/java/org/apache/directory/api/ldap/extras/controls/ad_impl/AdShowDeletedFactory.java
copy to ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/OpaqueControlFactory.java
index f96e459..77d2720 100644
--- a/ldap/extras/codec/src/main/java/org/apache/directory/api/ldap/extras/controls/ad_impl/AdShowDeletedFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/OpaqueControlFactory.java
@@ -17,72 +17,62 @@
  *   under the License.
  *
  */
-package org.apache.directory.api.ldap.extras.controls.ad_impl;
-
+package org.apache.directory.api.ldap.codec.controls;
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.codec.api.AbstractControlFactory;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.extras.controls.ad.AdShowDeleted;
-import org.apache.directory.api.ldap.extras.controls.ad.AdShowDeletedImpl;
 import org.apache.directory.api.ldap.model.message.Control;
-
+import org.apache.directory.api.ldap.model.message.controls.OpaqueControl;
 
 /**
- * A codec {@link ControlFactory} implementation for {@link AdShowDeleted} controls.
+ * A codec {@link ControlFactory} implementation for {@link Opaque} controls.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class AdShowDeletedFactory extends AbstractControlFactory<AdShowDeleted>
+public class OpaqueControlFactory extends AbstractControlFactory<Control>
 {
-    /**
-     * Creates a new instance of AdDeletedFactory.
+    /** 
+     * Creates a new instance of OpaqueControlFactory.
      *
-     * @param codec The LDAP codec
+     * @param codec The LDAP codec.
+     * @param the control to create
      */
-    public AdShowDeletedFactory( LdapApiService codec )
+    public OpaqueControlFactory( LdapApiService codec, String oid )
     {
-        super( codec );
+        super( codec, oid );
     }
 
-
+    
     /**
      * {@inheritDoc}
      */
     @Override
-    public String getOid()
+    public Control newControl()
     {
-        return AdShowDeleted.OID;
+        return new OpaqueControl( getOid() );
     }
 
-
+    
     /**
      * {@inheritDoc}
      */
     @Override
-    public CodecControl<AdShowDeleted> newCodecControl()
+    public void encodeValue( Asn1Buffer buffer, Control control )
     {
-        return new AdShowDeletedDecorator( codec, new AdShowDeletedImpl() );
+        buffer.put( ( ( OpaqueControl ) control ).getEncodedValue() );
     }
 
-
+    
     /**
      * {@inheritDoc}
      */
     @Override
-    public CodecControl<AdShowDeleted> newCodecControl( AdShowDeleted control )
+    public void decodeValue( Control control, byte[] controlBytes ) throws DecoderException
     {
-        return new AdShowDeletedDecorator( codec, control );
-    }
-
-
-    @Override
-    public void encodeValue( Asn1Buffer buffer, Control control )
-    {
-        // TODO Auto-generated method stub
-
+        ( ( OpaqueControl ) control ).setEncodedValue( controlBytes );
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeDecorator.java
deleted file mode 100644
index 4bf07df..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeDecorator.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *  
- *    http://www.apache.org/licenses/LICENSE-2.0
- *  
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License. 
- *  
- */
-package org.apache.directory.api.ldap.codec.controls.cascade;
-
-
-import java.nio.ByteBuffer;
-
-import org.apache.directory.api.asn1.Asn1Object;
-import org.apache.directory.api.asn1.DecoderException;
-import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.model.message.controls.Cascade;
-
-
-/**
- * The Cascade control decorator.
- * 
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public class CascadeDecorator extends ControlDecorator<Cascade> implements Cascade
-{
-    /**
-     * Default constructor
-     * 
-     * @param codec The LDAP service instance
-     * @param control the Control to decorate
-     */
-    public CascadeDecorator( LdapApiService codec, Cascade control )
-    {
-        super( codec, control );
-    }
-
-
-    /**
-     * @return the control length.
-     */
-    @Override
-    public int computeLength()
-    {
-        return 0;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Asn1Object decode( byte[] controlBytes ) throws DecoderException
-    {
-        return this;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
-    {
-        return buffer;
-    }
-}
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeFactory.java
index d92b4f9..723bdb2 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/cascade/CascadeFactory.java
@@ -21,7 +21,6 @@ package org.apache.directory.api.ldap.codec.controls.cascade;
 
 
 import org.apache.directory.api.ldap.codec.api.AbstractControlFactory;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.message.controls.Cascade;
@@ -43,7 +42,7 @@ public class CascadeFactory extends AbstractControlFactory<Cascade>
      */
     public CascadeFactory( LdapApiService codec )
     {
-        super( codec );
+        super( codec, Cascade.OID );
     }
 
 
@@ -51,28 +50,8 @@ public class CascadeFactory extends AbstractControlFactory<Cascade>
      * {@inheritDoc}
      */
     @Override
-    public String getOid()
+    public Cascade newControl()
     {
-        return Cascade.OID;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<Cascade> newCodecControl()
-    {
-        return new CascadeDecorator( codec, new CascadeImpl() );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<Cascade> newCodecControl( Cascade control )
-    {
-        return new CascadeDecorator( codec, control );
+        return new CascadeImpl();
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITDecorator.java
deleted file mode 100644
index c0e18e6..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITDecorator.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *  
- *    http://www.apache.org/licenses/LICENSE-2.0
- *  
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License. 
- *  
- */
-package org.apache.directory.api.ldap.codec.controls.manageDsaIT;
-
-
-import java.nio.ByteBuffer;
-
-import org.apache.directory.api.asn1.Asn1Object;
-import org.apache.directory.api.asn1.DecoderException;
-import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.model.message.controls.ManageDsaIT;
-
-
-/**
- * A decorating wrapper for a ManageDsaIT Control.
- *
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public class ManageDsaITDecorator extends ControlDecorator<ManageDsaIT> implements ManageDsaIT
-{
-
-    /**
-     * Default constructor
-     * 
-     * @param codec The LDAP service instance
-     * @param control The ManageDsaIT to decorate
-     */
-    public ManageDsaITDecorator( LdapApiService codec, ManageDsaIT control )
-    {
-        super( codec, control );
-    }
-
-
-    /**
-     * @return 0 every time.
-     */
-    @Override
-    public int computeLength()
-    {
-        return 0;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Asn1Object decode( byte[] controlBytes ) throws DecoderException
-    {
-        return this;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
-    {
-        return buffer;
-    }
-}
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITFactory.java
index 38e6208..3fb2acb 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/manageDsaIT/ManageDsaITFactory.java
@@ -21,7 +21,6 @@ package org.apache.directory.api.ldap.codec.controls.manageDsaIT;
 
 
 import org.apache.directory.api.ldap.codec.api.AbstractControlFactory;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.message.controls.ManageDsaIT;
@@ -43,7 +42,7 @@ public class ManageDsaITFactory extends AbstractControlFactory<ManageDsaIT>
      */
     public ManageDsaITFactory( LdapApiService codec )
     {
-        super( codec );
+        super( codec, ManageDsaIT.OID );
     }
 
 
@@ -51,28 +50,8 @@ public class ManageDsaITFactory extends AbstractControlFactory<ManageDsaIT>
      * {@inheritDoc}
      */
     @Override
-    public String getOid()
+    public ManageDsaIT newControl()
     {
-        return ManageDsaIT.OID;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<ManageDsaIT> newCodecControl()
-    {
-        return new ManageDsaITDecorator( codec, new ManageDsaITImpl() );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<ManageDsaIT> newCodecControl( ManageDsaIT control )
-    {
-        return new ManageDsaITDecorator( codec, control );
+        return new ManageDsaITImpl();
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzDecorator.java
deleted file mode 100644
index 83d4471..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzDecorator.java
+++ /dev/null
@@ -1,197 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *  
- *    http://www.apache.org/licenses/LICENSE-2.0
- *  
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License. 
- *  
- */
-package org.apache.directory.api.ldap.codec.controls.proxiedauthz;
-
-
-import java.nio.ByteBuffer;
-
-import org.apache.directory.api.asn1.Asn1Object;
-import org.apache.directory.api.asn1.DecoderException;
-import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.asn1.ber.tlv.BerValue;
-import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.model.message.controls.ProxiedAuthz;
-import org.apache.directory.api.ldap.model.message.controls.ProxiedAuthzImpl;
-import org.apache.directory.api.util.Strings;
-
-
-/**
- * An ProxiedAuthz implementation, that wraps and decorates the Control with codec
- * specific functionality.
- *
- *
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public class ProxiedAuthzDecorator extends ControlDecorator<ProxiedAuthz> implements ProxiedAuthz
-{
-    /** A temporary storage for the authzId */
-    private byte[] authzIdBytes = null;
-
-
-    /**
-     * Creates a new instance of ProxiedAuthzDecoder wrapping a newly created
-     * ProxiedAuthz Control object.
-     * 
-     * @param codec The LDAP service instance
-     */
-    public ProxiedAuthzDecorator( LdapApiService codec )
-    {
-        super( codec, new ProxiedAuthzImpl() );
-    }
-
-
-    /**
-     * Creates a new instance of ProxiedAuthzDecorator wrapping the supplied
-     * ProxiedAuthz Control.
-     *
-     * @param codec The LDAP service instance
-     * @param control The ProxiedAuthz Control to be decorated.
-     */
-    public ProxiedAuthzDecorator( LdapApiService codec, ProxiedAuthz control )
-    {
-        super( codec, control );
-    }
-
-
-    /**
-     * Internally used to not have to cast the decorated Control.
-     *
-     * @return the decorated Control.
-     */
-    private ProxiedAuthz getProxiedAuthz()
-    {
-        return getDecorated();
-    }
-
-
-    /**
-     * Compute the ProxiedAuthzControl length 
-     * <pre>
-     *  0x04 L1 authzId]
-     * </pre>
-     *  
-     * @return the control length.
-     */
-    @Override
-    public int computeLength()
-    {
-        int valueLength = 0;
-
-        if ( getAuthzId() != null )
-        {
-            authzIdBytes = Strings.getBytesUtf8( getAuthzId() );
-            valueLength = authzIdBytes.length;
-        }
-
-        return valueLength;
-    }
-
-
-    /**
-     * Encodes the ProxiedAuthz control.
-     * 
-     * @param buffer The encoded sink
-     * @return A ByteBuffer that contains the encoded PDU
-     * @throws EncoderException If anything goes wrong.
-     */
-    @Override
-    public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
-    {
-        if ( buffer == null )
-        {
-            throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) );
-        }
-
-        if ( getAuthzId() != null )
-        {
-            buffer.put( authzIdBytes );
-        }
-
-        return buffer;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public byte[] getValue()
-    {
-        if ( value == null )
-        {
-            try
-            {
-                computeLength();
-                ByteBuffer buffer = ByteBuffer.allocate( valueLength );
-
-                if ( authzIdBytes != null )
-                {
-                    BerValue.encode( buffer, authzIdBytes );
-                }
-                else
-                {
-                    BerValue.encode( buffer, Strings.EMPTY_BYTES );
-                }
-
-                value = buffer.array();
-            }
-            catch ( Exception e )
-            {
-                return null;
-            }
-        }
-
-        return value;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public String getAuthzId()
-    {
-        return getProxiedAuthz().getAuthzId();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void setAuthzId( String authzId )
-    {
-        getProxiedAuthz().setAuthzId( authzId );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Asn1Object decode( byte[] controlBytes ) throws DecoderException
-    {
-        getProxiedAuthz().setAuthzId( Strings.utf8ToString( controlBytes ) );
-
-        return this;
-    }
-}
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzFactory.java
index 3a1b34d..278da29 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/proxiedauthz/ProxiedAuthzFactory.java
@@ -20,13 +20,14 @@
 package org.apache.directory.api.ldap.codec.controls.proxiedauthz;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.codec.api.AbstractControlFactory;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.controls.ProxiedAuthz;
+import org.apache.directory.api.ldap.model.message.controls.ProxiedAuthzImpl;
 import org.apache.directory.api.util.Strings;
 
 
@@ -45,7 +46,7 @@ public class ProxiedAuthzFactory extends AbstractControlFactory<ProxiedAuthz>
      */
     public ProxiedAuthzFactory( LdapApiService codec )
     {
-        super( codec );
+        super( codec, ProxiedAuthz.OID );
     }
 
 
@@ -53,9 +54,9 @@ public class ProxiedAuthzFactory extends AbstractControlFactory<ProxiedAuthz>
      * {@inheritDoc}
      */
     @Override
-    public String getOid()
+    public ProxiedAuthz newControl()
     {
-        return ProxiedAuthz.OID;
+        return new ProxiedAuthzImpl();
     }
 
 
@@ -63,23 +64,6 @@ public class ProxiedAuthzFactory extends AbstractControlFactory<ProxiedAuthz>
      * {@inheritDoc}
      */
     @Override
-    public CodecControl<ProxiedAuthz> newCodecControl()
-    {
-        return new ProxiedAuthzDecorator( codec );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<ProxiedAuthz> newCodecControl( ProxiedAuthz control )
-    {
-        return new ProxiedAuthzDecorator( codec, control );
-    }
-
-
-    @Override
     public void encodeValue( Asn1Buffer buffer, Control control )
     {
         byte[] authzId = Strings.getBytesUtf8( ( ( ProxiedAuthz ) control ).getAuthzId() );
@@ -89,4 +73,20 @@ public class ProxiedAuthzFactory extends AbstractControlFactory<ProxiedAuthz>
             buffer.put( authzId );
         }
     }
+    
+    
+    /**
+     * {@inheritDoc}
+     */
+    public void decodeValue( Control control, byte[] controlBytes ) throws DecoderException
+    {
+        try
+        {
+            ( ( ProxiedAuthz ) control ).setAuthzId( Strings.utf8ToString( controlBytes ) );
+        }
+        catch ( RuntimeException re )
+        {
+            throw new DecoderException( re.getMessage() );
+        }
+    }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeContainer.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeContainer.java
index e5468fb..bc98f96 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeContainer.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeContainer.java
@@ -21,79 +21,39 @@ package org.apache.directory.api.ldap.codec.controls.search.entryChange;
 
 
 import org.apache.directory.api.asn1.ber.AbstractContainer;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
+import org.apache.directory.api.ldap.codec.api.ControlContainer;
+import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.controls.EntryChange;
 
 
 /**
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class EntryChangeContainer extends AbstractContainer
+public class EntryChangeContainer extends AbstractContainer implements ControlContainer
 {
     /** EntryChangeControl */
-    private EntryChangeDecorator control;
-
-    /** The codec that encodes and decodes */
-    private LdapApiService codec;
-
+    private Control control;
 
     /**
-     * Creates a new EntryChangeContainer object. We will store one
-     * grammar, it's enough ...
-     * 
-     * @param codec The LDAP service instance
+     * Creates a container with a EntryChange control
+     *
+     * @param control The EntryChange Control to store
      */
-    public EntryChangeContainer( LdapApiService codec )
+    public EntryChangeContainer( Control control )
     {
         super();
-        this.codec = codec;
         setGrammar( EntryChangeGrammar.getInstance() );
         setTransition( EntryChangeStates.START_STATE );
-    }
-
-
-    /**
-     * Creates a container with decorator, optionally decorating the supplied
-     * Control if it is not a decorator implementation.
-     *
-     * @param codec The LDAP service instance
-     * @param control The EntryChange ControlDecorator, or a Control to be
-     * wrapped by a new decorator.
-     */
-    public EntryChangeContainer( LdapApiService codec, EntryChange control )
-    {
-        this( codec );
-        decorate( control );
+        this.control = control;
     }
 
 
     /**
      * @return Returns the EntryChangeControl.
      */
-    public EntryChangeDecorator getEntryChangeDecorator()
-    {
-        return control;
-    }
-
-
-    /**
-     * Checks to see if the supplied EntryChange implementation is a decorator
-     * and if so just sets the EntryChangeDecorator to it. Otherwise the supplied
-     * control is decorated by creating a new EntryChangeDecorator to wrap the
-     * object.
-     *
-     * @param control The EntryChange Control to wrap, if it is not a decorator.
-     */
-    public void decorate( EntryChange control )
+    public EntryChange getEntryChange()
     {
-        if ( control instanceof EntryChangeDecorator )
-        {
-            this.control = ( EntryChangeDecorator ) control;
-        }
-        else
-        {
-            this.control = new EntryChangeDecorator( codec, control );
-        }
+        return ( EntryChange ) control;
     }
 
 
@@ -101,9 +61,9 @@ public class EntryChangeContainer extends AbstractContainer
      * Set a EntryChangeControl Object into the container. It will be completed
      * by the ldapDecoder.
      * 
-     * @param control the EntryChangeControl to set.
+     * @param control the EntryChange Control to set.
      */
-    public void setEntryChangeDecorator( EntryChangeDecorator control )
+    public void setControl( Control control )
     {
         this.control = control;
     }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeDecorator.java
deleted file mode 100644
index 3ccb71a..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeDecorator.java
+++ /dev/null
@@ -1,288 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *  
- *    http://www.apache.org/licenses/LICENSE-2.0
- *  
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License. 
- *  
- */
-package org.apache.directory.api.ldap.codec.controls.search.entryChange;
-
-
-import java.nio.ByteBuffer;
-
-import org.apache.directory.api.asn1.Asn1Object;
-import org.apache.directory.api.asn1.DecoderException;
-import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.asn1.ber.Asn1Decoder;
-import org.apache.directory.api.asn1.ber.tlv.BerValue;
-import org.apache.directory.api.asn1.ber.tlv.TLV;
-import org.apache.directory.api.asn1.ber.tlv.UniversalTag;
-import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.model.message.controls.ChangeType;
-import org.apache.directory.api.ldap.model.message.controls.EntryChange;
-import org.apache.directory.api.ldap.model.message.controls.EntryChangeImpl;
-import org.apache.directory.api.ldap.model.name.Dn;
-import org.apache.directory.api.util.Strings;
-
-
-/**
- * An EntryChange implementation, that wraps and decorates the Control with codec
- * specific functionality.
- *
- *
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public class EntryChangeDecorator extends ControlDecorator<EntryChange> implements EntryChange
-{
-    /** Default value when no change number is provided */
-    public static final int UNDEFINED_CHANGE_NUMBER = -1;
-
-    /** A temporary storage for the previous Dn */
-    private byte[] previousDnBytes = null;
-
-    /** The entry change global length */
-    private int eccSeqLength;
-
-    /** An instance of this decoder */
-    private static final Asn1Decoder DECODER = new Asn1Decoder();
-
-
-    /**
-     * Creates a new instance of EntryChangeDecoder wrapping a newly created
-     * EntryChange Control object.
-     * 
-     * @param codec The LDAP service instance
-     */
-    public EntryChangeDecorator( LdapApiService codec )
-    {
-        super( codec, new EntryChangeImpl() );
-    }
-
-
-    /**
-     * Creates a new instance of EntryChangeDecorator wrapping the supplied
-     * EntryChange Control.
-     *
-     * @param codec The LDAP service instance
-     * @param control The EntryChange Control to be decorated.
-     */
-    public EntryChangeDecorator( LdapApiService codec, EntryChange control )
-    {
-        super( codec, control );
-    }
-
-
-    /**
-     * Internally used to not have to cast the decorated Control.
-     *
-     * @return the decorated Control.
-     */
-    private EntryChange getEntryChange()
-    {
-        return getDecorated();
-    }
-
-
-    /**
-     * Compute the EntryChangeControl length 
-     * 
-     * <pre>
-     * 0x30 L1 
-     *   | 
-     *   +--&gt; 0x0A 0x0(1-4) [1|2|4|8] (changeType) 
-     *  [+--&gt; 0x04 L2 previousDN] 
-     *  [+--&gt; 0x02 0x0(1-4) [0..2^63-1] (changeNumber)]
-     *  </pre>
-     *  
-     * @return the control length.
-     */
-    @Override
-    public int computeLength()
-    {
-        int changeTypesLength = 1 + 1 + 1;
-
-        int previousDnLength = 0;
-        int changeNumberLength = 0;
-
-        if ( getPreviousDn() != null )
-        {
-            previousDnBytes = Strings.getBytesUtf8( getPreviousDn().getName() );
-            previousDnLength = 1 + TLV.getNbBytes( previousDnBytes.length ) + previousDnBytes.length;
-        }
-
-        if ( getChangeNumber() != UNDEFINED_CHANGE_NUMBER )
-        {
-            changeNumberLength = 1 + 1 + BerValue.getNbBytes( getChangeNumber() );
-        }
-
-        eccSeqLength = changeTypesLength + previousDnLength + changeNumberLength;
-        valueLength = 1 + TLV.getNbBytes( eccSeqLength ) + eccSeqLength;
-
-        return valueLength;
-    }
-
-
-    /**
-     * Encodes the entry change control.
-     * 
-     * @param buffer The encoded sink
-     * @return A ByteBuffer that contains the encoded PDU
-     * @throws EncoderException If anything goes wrong.
-     */
-    @Override
-    public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
-    {
-        if ( buffer == null )
-        {
-            throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) );
-        }
-
-        buffer.put( UniversalTag.SEQUENCE.getValue() );
-        buffer.put( TLV.getBytes( eccSeqLength ) );
-
-        buffer.put( UniversalTag.ENUMERATED.getValue() );
-        buffer.put( ( byte ) 1 );
-        buffer.put( BerValue.getBytes( getChangeType().getValue() ) );
-
-        if ( getPreviousDn() != null )
-        {
-            BerValue.encode( buffer, previousDnBytes );
-        }
-
-        if ( getChangeNumber() != UNDEFINED_CHANGE_NUMBER )
-        {
-            BerValue.encode( buffer, getChangeNumber() );
-        }
-
-        return buffer;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public byte[] getValue()
-    {
-        if ( value == null )
-        {
-            try
-            {
-                computeLength();
-                ByteBuffer buffer = ByteBuffer.allocate( valueLength );
-
-                buffer.put( UniversalTag.SEQUENCE.getValue() );
-                buffer.put( TLV.getBytes( eccSeqLength ) );
-
-                buffer.put( UniversalTag.ENUMERATED.getValue() );
-                buffer.put( ( byte ) 1 );
-                buffer.put( BerValue.getBytes( getChangeType().getValue() ) );
-
-                if ( getPreviousDn() != null )
-                {
-                    BerValue.encode( buffer, previousDnBytes );
-                }
-
-                if ( getChangeNumber() != UNDEFINED_CHANGE_NUMBER )
-                {
-                    BerValue.encode( buffer, getChangeNumber() );
-                }
-
-                value = buffer.array();
-            }
-            catch ( Exception e )
-            {
-                return null;
-            }
-        }
-
-        return value;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public ChangeType getChangeType()
-    {
-        return getEntryChange().getChangeType();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void setChangeType( ChangeType changeType )
-    {
-        getEntryChange().setChangeType( changeType );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Dn getPreviousDn()
-    {
-        return getEntryChange().getPreviousDn();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void setPreviousDn( Dn previousDn )
-    {
-        getEntryChange().setPreviousDn( previousDn );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public long getChangeNumber()
-    {
-        return getEntryChange().getChangeNumber();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void setChangeNumber( long changeNumber )
-    {
-        getEntryChange().setChangeNumber( changeNumber );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Asn1Object decode( byte[] controlBytes ) throws DecoderException
-    {
-        ByteBuffer bb = ByteBuffer.wrap( controlBytes );
-        EntryChangeContainer container = new EntryChangeContainer( getCodecService(), this );
-        DECODER.decode( bb, container );
-        return this;
-    }
-}
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeFactory.java
index 21cf8d8..7d72cd3 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeFactory.java
@@ -20,14 +20,15 @@
 package org.apache.directory.api.ldap.codec.controls.search.entryChange;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.tlv.BerValue;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.codec.api.AbstractControlFactory;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.controls.EntryChange;
+import org.apache.directory.api.ldap.model.message.controls.EntryChangeImpl;
 
 
 /**
@@ -48,7 +49,7 @@ public class EntryChangeFactory extends AbstractControlFactory<EntryChange>
      */
     public EntryChangeFactory( LdapApiService codec )
     {
-        super( codec );
+        super( codec, EntryChange.OID );
     }
 
 
@@ -56,29 +57,9 @@ public class EntryChangeFactory extends AbstractControlFactory<EntryChange>
      * {@inheritDoc}
      */
     @Override
-    public String getOid()
+    public EntryChange newControl()
     {
-        return EntryChange.OID;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<EntryChange> newCodecControl()
-    {
-        return new EntryChangeDecorator( codec );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<EntryChange> newCodecControl( EntryChange control )
-    {
-        return new EntryChangeDecorator( codec, control );
+        return new EntryChangeImpl();
     }
 
 
@@ -110,4 +91,14 @@ public class EntryChangeFactory extends AbstractControlFactory<EntryChange>
         // The EntryChangeNotification sequence
         BerValue.encodeSequence( buffer, start );
     }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void decodeValue( Control control, byte[] controlBytes ) throws DecoderException
+    {
+        decodeValue( new EntryChangeContainer( control ), control, controlBytes );
+    }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeGrammar.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeGrammar.java
index d7bc995..3ab5c89 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeGrammar.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/entryChange/EntryChangeGrammar.java
@@ -113,7 +113,7 @@ public final class EntryChangeGrammar extends AbstractGrammar<EntryChangeContain
                                         LOG.debug( I18n.msg( I18n.MSG_05300_CHANGE_TYPE, changeType ) );
                                     }
 
-                                    container.getEntryChangeDecorator().setChangeType( changeType );
+                                    container.getEntryChange().setChangeType( changeType );
                                     break;
 
                                 default:
@@ -156,7 +156,7 @@ public final class EntryChangeGrammar extends AbstractGrammar<EntryChangeContain
                 {
                     public void action( EntryChangeContainer container ) throws DecoderException
                     {
-                        ChangeType changeType = container.getEntryChangeDecorator().getChangeType();
+                        ChangeType changeType = container.getEntryChange().getChangeType();
 
                         if ( changeType != ChangeType.MODDN )
                         {
@@ -183,7 +183,7 @@ public final class EntryChangeGrammar extends AbstractGrammar<EntryChangeContain
                                 LOG.debug( I18n.msg( I18n.MSG_05301_PREVIOUS_DN, previousDn ) );
                             }
 
-                            container.getEntryChangeDecorator().setPreviousDn( previousDn );
+                            container.getEntryChange().setPreviousDn( previousDn );
 
                             // We can have an END transition
                             container.setGrammarEndAllowed( true );
@@ -208,7 +208,7 @@ public final class EntryChangeGrammar extends AbstractGrammar<EntryChangeContain
                         LOG.debug( I18n.msg( I18n.MSG_05302_CHANGE_NUMBER, changeNumber ) );
                     }
 
-                    container.getEntryChangeDecorator().setChangeNumber( changeNumber );
+                    container.getEntryChange().setChangeNumber( changeNumber );
 
                     // We can have an END transition
                     container.setGrammarEndAllowed( true );
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsContainer.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsContainer.java
index 5b4ccdc..90ddcfd 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsContainer.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsContainer.java
@@ -21,7 +21,8 @@ package org.apache.directory.api.ldap.codec.controls.search.pagedSearch;
 
 
 import org.apache.directory.api.asn1.ber.AbstractContainer;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
+import org.apache.directory.api.ldap.codec.api.ControlContainer;
+import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.controls.PagedResults;
 
 
@@ -30,80 +31,45 @@ import org.apache.directory.api.ldap.model.message.controls.PagedResults;
  * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class PagedResultsContainer extends AbstractContainer
+public class PagedResultsContainer extends AbstractContainer implements ControlContainer
 {
     /** PagedSearchControl */
-    private PagedResultsDecorator control;
-
-    private LdapApiService codec;
-
+    private Control control;
 
     /**
-     * Creates a new PagedSearchControl container object. We will store one grammar,
-     * it's enough ...
-     * @param codec The encoder decoder for this container
+     * Creates a new PagedSearchControl container object to contain a PagedResults
+     * Control.
+     *
+     * @param control A PagedResults Control to store
      */
-    public PagedResultsContainer( LdapApiService codec )
+    public PagedResultsContainer( Control control )
     {
         super();
-        this.codec = codec;
         setGrammar( PagedResultsGrammar.getInstance() );
         setTransition( PagedResultsStates.START_STATE );
+        this.control = control;
     }
 
 
     /**
-     * Creates a new PagedSearchControl container object to contain a PagedResults
-     * Control, which is optionally decorated if is not a decorator already. If it
-     * is a decorator then it is used as the decorator for this container.
-     *
-     * @param codec The encoder decoder for this container
-     * @param control A PagedResults Control to optionally be wrapped.
-     */
-    public PagedResultsContainer( LdapApiService codec, PagedResults control )
-    {
-        this( codec );
-        decorate( control );
-    }
-
-
-    /**
-     * @return Returns the paged search control.
-     */
-    public PagedResultsDecorator getDecorator()
-    {
-
-        return control;
-    }
-
-
-    /**
-     * Decorate the PageResult control
+     * Set a PagedSearchControl Object into the container. It will be completed by
+     * the ldapDecoder.
      * 
-     * @param control The PageResult control instance
+     * @param control the PagedSearchControl to set.
      */
-    public void decorate( PagedResults control )
+    @Override
+    public void setControl( Control control )
     {
-        if ( control instanceof PagedResultsDecorator )
-        {
-            this.control = ( PagedResultsDecorator ) control;
-        }
-        else
-        {
-            this.control = new PagedResultsDecorator( codec, control );
-        }
+        this.control = control;
     }
 
 
     /**
-     * Set a PagedSearchControl Object into the container. It will be completed by
-     * the ldapDecoder.
-     * 
-     * @param control the PagedSearchControl to set.
+     * @return the control
      */
-    public void setPagedSearchControl( PagedResultsDecorator control )
+    public PagedResults getPagedResults()
     {
-        this.control = control;
+        return ( PagedResults ) control;
     }
 
 
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsDecorator.java
deleted file mode 100644
index 6ebde73..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsDecorator.java
+++ /dev/null
@@ -1,327 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *  
- *    http://www.apache.org/licenses/LICENSE-2.0
- *  
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License. 
- *  
- */
-package org.apache.directory.api.ldap.codec.controls.search.pagedSearch;
-
-
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-
-import org.apache.directory.api.asn1.Asn1Object;
-import org.apache.directory.api.asn1.DecoderException;
-import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.asn1.ber.Asn1Decoder;
-import org.apache.directory.api.asn1.ber.tlv.BerValue;
-import org.apache.directory.api.asn1.ber.tlv.TLV;
-import org.apache.directory.api.asn1.ber.tlv.UniversalTag;
-import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.model.message.controls.PagedResults;
-import org.apache.directory.api.ldap.model.message.controls.PagedResultsImpl;
-import org.apache.directory.api.util.Strings;
-
-
-/**
- * A codec decorator for the {@link PagedResultsImpl}.
- * 
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public class PagedResultsDecorator extends ControlDecorator<PagedResults> implements PagedResults
-{
-    /** The entry change global length */
-    private int pscSeqLength;
-
-    /** An instance of this decoder */
-    private static final Asn1Decoder DECODER = new Asn1Decoder();
-
-
-    /**
-     * Creates a new instance of PagedResultsDecorator with a newly created decorated
-     * PagedResults Control.
-     * 
-     * @param codec The LDAP service instance
-     */
-    public PagedResultsDecorator( LdapApiService codec )
-    {
-        this( codec, new PagedResultsImpl() );
-    }
-
-
-    /**
-     * Creates a new instance of PagedResultsDecorator using the supplied PagedResults
-     * Control to be decorated.
-     *
-     * @param codec The LDAP service instance
-     * @param  pagedResults The PagedResults Control to be decorated.
-     */
-    public PagedResultsDecorator( LdapApiService codec, PagedResults pagedResults )
-    {
-        super( codec, pagedResults );
-    }
-
-
-    /**
-     * Compute the PagedSearchControl length, which is the sum
-     * of the control length and the value length.
-     * 
-     * <pre>
-     * PagedSearchControl value length :
-     * 
-     * 0x30 L1 
-     *   | 
-     *   +--&gt; 0x02 0x0(1-4) [0..2^63-1] (size) 
-     *   +--&gt; 0x04 L2 (cookie)
-     * </pre>
-     *  
-     * @return the control length.
-     */
-    @Override
-    public int computeLength()
-    {
-        int sizeLength = 1 + 1 + BerValue.getNbBytes( getSize() );
-
-        int cookieLength;
-
-        if ( getCookie() != null )
-        {
-            cookieLength = 1 + TLV.getNbBytes( getCookie().length ) + getCookie().length;
-        }
-        else
-        {
-            cookieLength = 1 + 1;
-        }
-
-        pscSeqLength = sizeLength + cookieLength;
-        valueLength = 1 + TLV.getNbBytes( pscSeqLength ) + pscSeqLength;
-
-        return valueLength;
-    }
-
-
-    /**
-     * Encodes the paged search control.
-     * 
-     * @param buffer The encoded sink
-     * @return A ByteBuffer that contains the encoded PDU
-     * @throws EncoderException If anything goes wrong.
-     */
-    @Override
-    public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
-    {
-        if ( buffer == null )
-        {
-            throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) );
-        }
-
-        // Now encode the PagedSearch specific part
-        buffer.put( UniversalTag.SEQUENCE.getValue() );
-        buffer.put( TLV.getBytes( pscSeqLength ) );
-
-        BerValue.encode( buffer, getSize() );
-        BerValue.encode( buffer, getCookie() );
-
-        return buffer;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public byte[] getValue()
-    {
-        if ( value == null )
-        {
-            try
-            {
-                computeLength();
-                ByteBuffer buffer = ByteBuffer.allocate( valueLength );
-
-                // Now encode the PagedSearch specific part
-                buffer.put( UniversalTag.SEQUENCE.getValue() );
-                buffer.put( TLV.getBytes( pscSeqLength ) );
-
-                BerValue.encode( buffer, getSize() );
-                BerValue.encode( buffer, getCookie() );
-
-                value = buffer.array();
-            }
-            catch ( Exception e )
-            {
-                return null;
-            }
-        }
-
-        return value;
-    }
-
-
-    /**
-     * @return The requested or returned number of entries
-     */
-    @Override
-    public int getSize()
-    {
-        return getDecorated().getSize();
-    }
-
-
-    /**
-     * Set the number of entry requested or returned
-     *
-     * @param size The number of entries 
-     */
-    @Override
-    public void setSize( int size )
-    {
-        getDecorated().setSize( size );
-    }
-
-
-    /**
-     * @return The stored cookie
-     */
-    @Override
-    public byte[] getCookie()
-    {
-        return getDecorated().getCookie();
-    }
-
-
-    /**
-     * Set the cookie
-     *
-     * @param cookie The cookie to store in this control
-     */
-    @Override
-    public void setCookie( byte[] cookie )
-    {
-        // Copy the bytes
-        if ( !Strings.isEmpty( cookie ) )
-        {
-            byte[] copy = new byte[cookie.length];
-            System.arraycopy( cookie, 0, copy, 0, cookie.length );
-            getDecorated().setCookie( copy );
-        }
-        else
-        {
-            getDecorated().setCookie( null );
-        }
-    }
-
-
-    /**
-     * @return The integer value for the current cookie
-     */
-    @Override
-    public int getCookieValue()
-    {
-        int value = 0;
-
-        switch ( getCookie().length )
-        {
-            case 1:
-                value = getCookie()[0] & 0x00FF;
-                break;
-
-            case 2:
-                value = ( ( getCookie()[0] & 0x00FF ) << 8 ) + ( getCookie()[1] & 0x00FF );
-                break;
-
-            case 3:
-                value = ( ( getCookie()[0] & 0x00FF ) << 16 ) + ( ( getCookie()[1] & 0x00FF ) << 8 )
-                    + ( getCookie()[2] & 0x00FF );
-                break;
-
-            case 4:
-                value = ( ( getCookie()[0] & 0x00FF ) << 24 ) + ( ( getCookie()[1] & 0x00FF ) << 16 )
-                    + ( ( getCookie()[2] & 0x00FF ) << 8 ) + ( getCookie()[3] & 0x00FF );
-                break;
-
-            default:
-                break;
-
-        }
-
-        return value;
-    }
-
-
-    /**
-     * @see Object#hashCode()
-     */
-    @Override
-    public int hashCode()
-    {
-        int hash = super.hashCode();
-
-        hash = hash * 17 + pscSeqLength;
-
-        return hash;
-    }
-
-
-    /**
-     * @see Object#equals(Object)
-     */
-    @Override
-    public boolean equals( Object o )
-    {
-        if ( !super.equals( o ) )
-        {
-            return false;
-        }
-
-        PagedResults otherControl = ( PagedResults ) o;
-
-        return ( getSize() == otherControl.getSize() ) && Arrays.equals( getCookie(), otherControl.getCookie() );
-    }
-
-
-    /**
-     * Return a String representing this PagedSearchControl.
-     */
-    @Override
-    public String toString()
-    {
-        StringBuilder sb = new StringBuilder();
-
-        sb.append( "    Paged Search Control\n" );
-        sb.append( "        oid : " ).append( getOid() ).append( '\n' );
-        sb.append( "        critical : " ).append( isCritical() ).append( '\n' );
-        sb.append( "        size   : '" ).append( getSize() ).append( "'\n" );
-        sb.append( "        cookie   : '" ).append( Strings.dumpBytes( getCookie() ) ).append( "'\n" );
-
-        return sb.toString();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public Asn1Object decode( byte[] controlBytes ) throws DecoderException
-    {
-        ByteBuffer bb = ByteBuffer.wrap( controlBytes );
-        PagedResultsContainer container = new PagedResultsContainer( getCodecService(), this );
-        DECODER.decode( bb, container );
-        return this;
-    }
-}
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsFactory.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsFactory.java
index 51c4fca..200e21a 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsFactory.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsFactory.java
@@ -20,14 +20,15 @@
 package org.apache.directory.api.ldap.codec.controls.search.pagedSearch;
 
 
+import org.apache.directory.api.asn1.DecoderException;
 import org.apache.directory.api.asn1.ber.tlv.BerValue;
 import org.apache.directory.api.asn1.util.Asn1Buffer;
 import org.apache.directory.api.ldap.codec.api.AbstractControlFactory;
-import org.apache.directory.api.ldap.codec.api.CodecControl;
 import org.apache.directory.api.ldap.codec.api.ControlFactory;
 import org.apache.directory.api.ldap.codec.api.LdapApiService;
 import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.controls.PagedResults;
+import org.apache.directory.api.ldap.model.message.controls.PagedResultsImpl;
 
 
 /**
@@ -45,7 +46,7 @@ public class PagedResultsFactory extends AbstractControlFactory<PagedResults>
      */
     public PagedResultsFactory( LdapApiService codec )
     {
-        super( codec );
+        super( codec, PagedResults.OID );
     }
 
 
@@ -53,29 +54,9 @@ public class PagedResultsFactory extends AbstractControlFactory<PagedResults>
      * {@inheritDoc}
      */
     @Override
-    public String getOid()
+    public PagedResults newControl()
     {
-        return PagedResults.OID;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<PagedResults> newCodecControl()
-    {
-        return new PagedResultsDecorator( codec );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public CodecControl<PagedResults> newCodecControl( PagedResults control )
-    {
-        return new PagedResultsDecorator( codec, control );
+        return new PagedResultsImpl();
     }
 
 
@@ -96,4 +77,14 @@ public class PagedResultsFactory extends AbstractControlFactory<PagedResults>
         // The sequence
         BerValue.encodeSequence( buffer, start );
     }
+
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void decodeValue( Control control, byte[] controlBytes ) throws DecoderException
+    {
+        decodeValue( new PagedResultsContainer( control ), control, controlBytes );
+    }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsGrammar.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsGrammar.java
index cea0a70..5e67386 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsGrammar.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/pagedSearch/PagedResultsGrammar.java
@@ -116,7 +116,7 @@ public final class PagedResultsGrammar extends AbstractGrammar<PagedResultsConta
                                 LOG.debug( I18n.msg( I18n.MSG_05303_SIZE, size ) );
                             }
 
-                            container.getDecorator().setSize( size );
+                            container.getPagedResults().setSize( size );
                         }
                         catch ( IntegerDecoderException ide )
                         {
@@ -147,11 +147,11 @@ public final class PagedResultsGrammar extends AbstractGrammar<PagedResultsConta
 
                         if ( container.getCurrentTLV().getLength() == 0 )
                         {
-                            container.getDecorator().setCookie( Strings.EMPTY_BYTES );
+                            container.getPagedResults().setCookie( Strings.EMPTY_BYTES );
                         }
                         else
                         {
-                            container.getDecorator().setCookie( value.getData() );
+                            container.getPagedResults().setCookie( value.getData() );
                         }
 
                         // We can have an END transition
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchContainer.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchContainer.java
index 1943af5..c57826f 100644
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchContainer.java
+++ b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchContainer.java
@@ -21,77 +21,41 @@ package org.apache.directory.api.ldap.codec.controls.search.persistentSearch;
 
 
 import org.apache.directory.api.asn1.ber.AbstractContainer;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
+import org.apache.directory.api.ldap.codec.api.ControlContainer;
+import org.apache.directory.api.ldap.model.message.Control;
 import org.apache.directory.api.ldap.model.message.controls.PersistentSearch;
 
 
 /**
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class PersistentSearchContainer extends AbstractContainer
+public class PersistentSearchContainer extends AbstractContainer implements ControlContainer
 {
     /** PSearchControl */
-    private PersistentSearchDecorator decorator;
-
-    private LdapApiService codec;
-
+    private Control control;
 
     /**
-     * Creates a new PSearchControlContainer object. We will store one grammar,
-     * it's enough ...
-     * 
-     * @param codec The LDAP service instance
+     * Creates a new PSearchControlContainer object pre-populated with a
+     * PersistentSearch control
+     *
+     * @param control The PersistentSearch Control.
      */
-    public PersistentSearchContainer( LdapApiService codec )
+    public PersistentSearchContainer( Control control )
     {
         super();
-        this.codec = codec;
         setGrammar( PersistentSearchGrammar.getInstance() );
         setTransition( PersistentSearchStates.START_STATE );
-    }
-
-
-    /**
-     * Creates a new PSearchControlContainer object pre-populated with a
-     * decorator wrapping the supplied control, or using the supplied control if
-     * it already is a decorator.
-     *
-     * @param codec The LDAP service instance
-     * @param control The PersistentSearch Control or a decorating wrapper.
-     */
-    public PersistentSearchContainer( LdapApiService codec, PersistentSearch control )
-    {
-        this( codec );
-        decorate( control );
-    }
-
-
-    /**
-     * Conditionally decorates a control if is not a decorator already.
-     *
-     * @param control The PersistentSearch Control to decorate if it already is not
-     * a decorator, if it is then the object is set as this container's decorator.
-     */
-    public void decorate( PersistentSearch control )
-    {
-        if ( control instanceof PersistentSearchDecorator )
-        {
-            this.decorator = ( PersistentSearchDecorator ) control;
-        }
-        else
-        {
-            this.decorator = new PersistentSearchDecorator( codec, control );
-        }
+        this.control = control;
     }
 
 
     /**
      * @return Returns the persistent search decorator.
      */
-    public PersistentSearchDecorator getPersistentSearchDecorator()
+    public PersistentSearch getPersistentSearch()
     {
 
-        return decorator;
+        return ( PersistentSearch ) control;
     }
 
 
@@ -101,9 +65,9 @@ public class PersistentSearchContainer extends AbstractContainer
      * 
      * @param decorator the PSearchControl to set.
      */
-    public void setPersistentSearchDecorator( PersistentSearchDecorator decorator )
+    public void setControl( Control control )
     {
-        this.decorator = decorator;
+        this.control = control;
     }
 
 
@@ -114,6 +78,6 @@ public class PersistentSearchContainer extends AbstractContainer
     public void clean()
     {
         super.clean();
-        decorator = null;
+        control = null;
     }
 }
diff --git a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchDecorator.java b/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchDecorator.java
deleted file mode 100644
index 6e8f0bf..0000000
--- a/ldap/codec/core/src/main/java/org/apache/directory/api/ldap/codec/controls/search/persistentSearch/PersistentSearchDecorator.java
+++ /dev/null
@@ -1,275 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *  
- *    http://www.apache.org/licenses/LICENSE-2.0
- *  
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License. 
- *  
- */
-package org.apache.directory.api.ldap.codec.controls.search.persistentSearch;
-
-
-import java.nio.ByteBuffer;
-
-import org.apache.directory.api.asn1.Asn1Object;
-import org.apache.directory.api.asn1.DecoderException;
-import org.apache.directory.api.asn1.EncoderException;
-import org.apache.directory.api.asn1.ber.Asn1Decoder;
-import org.apache.directory.api.asn1.ber.tlv.BerValue;
-import org.apache.directory.api.asn1.ber.tlv.TLV;
-import org.apache.directory.api.asn1.ber.tlv.UniversalTag;
-import org.apache.directory.api.i18n.I18n;
-import org.apache.directory.api.ldap.codec.api.ControlDecorator;
-import org.apache.directory.api.ldap.codec.api.LdapApiService;
-import org.apache.directory.api.ldap.model.message.controls.ChangeType;
-import org.apache.directory.api.ldap.model.message.controls.PersistentSearch;
-import org.apache.directory.api.ldap.model.message.controls.PersistentSearchImpl;
-
-
-/**
- * A persistence search object
- * 
- * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
- */
-public class PersistentSearchDecorator extends ControlDecorator<PersistentSearch> implements PersistentSearch
-{
-    /** A temporary storage for a psearch length */
-    private int psearchSeqLength;
-
-    /** An instance of this decoder */
-    private static final Asn1Decoder DECODER = new Asn1Decoder();
-
-
-    /**
-     * Default constructor creates a PersistentSearch Control automatically
-     * wrapped in a decorator object inside this container.
-     * 
-     * @param codec The LDAP service instance
-     */
-    public PersistentSearchDecorator( LdapApiService codec )
-    {
-        this( codec, new PersistentSearchImpl() );
-    }
-
-
-    /**
-     * Creates a PersistentSearch Control wrapping a supplied PersistentSearch
-     * Control.
-     *
-     * @param codec The LDAP service instance
-     * @param control The PersistentSearch Control to wrap.
-     */
-    public PersistentSearchDecorator( LdapApiService codec, PersistentSearch control )
-    {
-        super( codec, control );
-    }
-
-
-    /**
-     * Compute the PagedSearchControl length, which is the sum
-     * of the control length and the value length.
-     * 
-     * <pre>
-     * PersistentSearchDecorator value length :
-     * 
-     * 0x30 L1 
-     *   | 
-     *   +--&gt; 0x02 0x0(1-4) [0..2^31-1] (changeTypes) 
-     *   +--&gt; 0x01 0x01 [0x00 | 0xFF] (changeOnly) 
-     *   +--&gt; 0x01 0x01 [0x00 | 0xFF] (returnRCs)
-     * </pre>
-     *  
-     * @return the control length.
-     */
-    @Override
-    public int computeLength()
-    {
-        int changeTypesLength = 1 + 1 + BerValue.getNbBytes( getChangeTypes() );
-        int changesOnlyLength = 1 + 1 + 1;
-        int returnRCsLength = 1 + 1 + 1;
-
-        psearchSeqLength = changeTypesLength + changesOnlyLength + returnRCsLength;
-        
-        return 1 + TLV.getNbBytes( psearchSeqLength ) + psearchSeqLength;
-    }
-
-
-    /**
-     * Encodes the persistent search control.
-     * 
-     * @param buffer The encoded sink
-     * @return A ByteBuffer that contains the encoded PDU
-     * @throws EncoderException If anything goes wrong.
-     */
-    @Override
-    public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException
-    {
-        if ( buffer == null )
-        {
-            throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) );
-        }
-
-        // Now encode the PagedSearch specific part
-        buffer.put( UniversalTag.SEQUENCE.getValue() );
-        buffer.put( TLV.getBytes( psearchSeqLength ) );
-
-        BerValue.encode( buffer, getChangeTypes() );
-        BerValue.encode( buffer, isChangesOnly() );
-        BerValue.encode( buffer, isReturnECs() );
-
-        return buffer;
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public byte[] getValue()
-    {
-        if ( value == null )
-        {
-            try
-            {
-                valueLength = computeLength();
-                ByteBuffer buffer = ByteBuffer.allocate( valueLength );
-
-                // Now encode the PagedSearch specific part
-                buffer.put( UniversalTag.SEQUENCE.getValue() );
-                buffer.put( TLV.getBytes( psearchSeqLength ) );
-
-                BerValue.encode( buffer, getChangeTypes() );
-                BerValue.encode( buffer, isChangesOnly() );
-                BerValue.encode( buffer, isReturnECs() );
-
-                value = buffer.array();
-            }
-            catch ( Exception e )
-            {
-                return null;
-            }
-        }
-
-        return value;
-    }
-
-
-    private PersistentSearch getPersistentSearch()
-    {
-        return getDecorated();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void setChangesOnly( boolean changesOnly )
-    {
-        getPersistentSearch().setChangesOnly( changesOnly );
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public boolean isChangesOnly()
-    {
-        return getPersistentSearch().isChangesOnly();
-    }
-
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void setReturnECs( boolean returnECs )
-    {
... 39078 lines suppressed ...


Mime
View raw message