"Fossies" - the Fresh Open Source Software Archive

Member "opensaf-5.21.09/src/amf/README_LONGDN" (31 May 2021, 2865 Bytes) of package /linux/misc/opensaf-5.21.09.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 #
    2 #      -*- OpenSAF  -*-
    3 #
    4 # (C) Copyright 2016 The OpenSAF Foundation
    5 #
    6 # This program is distributed in the hope that it will be useful, but
    7 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
    8 # or FITNESS FOR A PARTICULAR PURPOSE. This file and program are licensed
    9 # under the GNU Lesser General Public License Version 2.1, February 1999.
   10 # The complete license can be accessed from the following location:
   11 # http://opensource.org/licenses/lgpl-license.php
   12 # See the Copying file included with the OpenSAF distribution for full
   13 # licensing terms.
   14 #
   15 # Author(s): Ericsson AB
   16 #
   17 
   18 GENERAL
   19 -------
   20 
   21 This is a description of how the AMF service supports long DNs.
   22 Ticket: https://sourceforge.net/p/opensaf/tickets/1642
   23 This enhancement is part of the general enhancement for supporting long
   24 DNs in OpenSAF introduced by ticket: #191. Ticket #1642 adds support for
   25 long DNs to AMF.
   26 
   27 CONFIGURATION
   28 -------------
   29 
   30 To enable support for long DNs/RDNs in IMM, the longDnsAllowed
   31 attribute must be enabled using the following command:
   32 
   33 immcfg -a longDnsAllowed=1 opensafImm=opensafImm,safApp=safImmService
   34 
   35 The IMM service will reject attempts to set the longDnsAllowed attribute
   36 back to 0 if the IMM database contains objects with DNs longer than 255 bytes
   37 or RDNs longer than 64 bytes.
   38 
   39 To enable long DN support, an application must follow these things:
   40 - Compile the application with the SA_EXTENDED_NAME_SOURCE preprocessor 
   41 macro defined.
   42 - Set the environment variable SA_ENABLE_EXTENDED_NAMES to 1 before 
   43 the first call to any SAF API.
   44 - Treat the SaNameT type as opaque and use the SaNameT tunnelling primitives
   45 saAisNameLend(), saAisNameBorrow() to manipulate SaNameT variables.
   46 
   47 IMPLEMENTATION DETAILS
   48 ----------------------
   49 
   50 The implementation has been adapted to the "tunnelling" solution provided
   51 by the OpenSAF generic patch (#191).
   52 Please see the document below on how to use the SaNameT tunnelling primitives:
   53     OpenSAF_Extensions_PR.odt
   54 
   55 This implementation also includes following enhancements:
   56 1) Replace internal SaNameT variables with std::string variables in amfd, amfnd.
   57 2) Replace patricia trees with std::map in amfnd.
   58 
   59 saAmfDispatch() may return SA_AIS_ERR_NAME_TOO_LONG if an application which
   60 does not support long DN, receives an AMF callback containing a long DN entity.
   61 An application should not be configured with long DN entities until long DN
   62 support has been added.
   63 
   64 In AMF B.01.01 spec, the application can free extended SaNameT variables in
   65 SaAmfProtectionGroupNotificationBufferT using the example below:
   66     SaAmfProtectionGroupNotificationBufferT buff;
   67     ...
   68     for ( i=0; i<buff.numOfItems; i++) {
   69         if (strlen(saAisNameBorrow(buff.notification[i].member.comp_name)) > 
   70             SA_MAX_UNEXTENDED_NAME_LENGTH)
   71             free(saAisNameBorrow(buff.notification[i].member.comp_name));
   72     }