]> git.sur5r.net Git - openldap/commitdiff
Add CSN syntax, matching rules (to support inequality indexing)
authorHoward Chu <hyc@openldap.org>
Thu, 2 Dec 2004 09:05:26 +0000 (09:05 +0000)
committerHoward Chu <hyc@openldap.org>
Thu, 2 Dec 2004 09:05:26 +0000 (09:05 +0000)
servers/slapd/schema_init.c
servers/slapd/schema_prep.c

index a63f3492ddd99833b34dd3f56f18b0c82dec6e21..b5cf4bdfdab3028aa477d68732f92faba0bfb65c 100644 (file)
@@ -3196,6 +3196,11 @@ static slap_syntax_defs_rec syntax_defs[] = {
        {"( 1.3.6.1.4.1.4203.666.2.6 DESC 'UUID' )",
                SLAP_SYNTAX_HIDE, UUIDValidate, NULL},
 
+       {"( 1.3.6.1.4.1.4203.666.11.2.1 DESC 'CSN' )",
+               SLAP_SYNTAX_HIDE,
+               blobValidate,   /* THIS WILL CHANGE */
+               NULL},
+
        /* OpenLDAP Void Syntax */
        {"( 1.3.6.1.4.1.4203.1.1.1 DESC 'OpenLDAP void' )" ,
                SLAP_SYNTAX_HIDE, inValidate, NULL},
@@ -3630,6 +3635,20 @@ static slap_mrule_defs_rec mrule_defs[] = {
                octetStringIndexer, octetStringFilter,
                "UUIDMatch"},
 
+       {"( 1.3.6.1.4.1.4203.666.11.2.2 NAME 'CSNMatch' "
+               "SYNTAX 1.3.6.1.4.1.4203.666.11.2.1 )",
+               SLAP_MR_HIDE | SLAP_MR_EQUALITY | SLAP_MR_ORDERED_INDEX, NULL,
+               NULL, NULL, octetStringMatch,
+               generalizedTimeIndexer, generalizedTimeFilter,
+               NULL},
+
+       {"( 1.3.6.1.4.1.4203.666.11.2.3 NAME 'CSNOrderingMatch' "
+               "SYNTAX 1.3.6.1.4.1.4203.666.11.2.1 )",
+               SLAP_MR_HIDE | SLAP_MR_ORDERING | SLAP_MR_ORDERED_INDEX, NULL,
+               NULL, NULL, octetStringOrderingMatch,
+               NULL, NULL,
+               "CSNMatch" },
+
        {NULL, SLAP_MR_NONE, NULL,
                NULL, NULL, NULL, NULL, NULL,
                NULL }
index ce794edc4a42329b272b2f090974b3eafd6ea8b9..4eca5045cc746db488411e7f2c49cb90c5ecc3e1 100644 (file)
@@ -547,9 +547,9 @@ static struct slap_schema_ad_map {
                offsetof(struct slap_internal_schema, si_ad_entryUUID) },
        { "entryCSN", "( 1.3.6.1.4.1.4203.666.1.7 NAME 'entryCSN' "
                        "DESC 'change sequence number of the entry content' "
-                       "EQUALITY octetStringMatch "
-                       "ORDERING octetStringOrderingMatch "
-                       "SYNTAX 1.3.6.1.4.1.1466.115.121.1.40{64} "
+                       "EQUALITY CSNMatch "
+                       "ORDERING CSNOrderingMatch "
+                       "SYNTAX 1.3.6.1.4.1.4203.666.11.2.1{64} "
                        "SINGLE-VALUE NO-USER-MODIFICATION USAGE directoryOperation )",
                NULL, SLAP_AT_HIDE,
                NULL, NULL,
@@ -557,9 +557,9 @@ static struct slap_schema_ad_map {
                offsetof(struct slap_internal_schema, si_ad_entryCSN) },
        { "namingCSN", "( 1.3.6.1.4.1.4203.666.1.13 NAME 'namingCSN' "
                        "DESC 'change sequence number of the entry naming (RDN)' "
-                       "EQUALITY octetStringMatch "
-                       "ORDERING octetStringOrderingMatch "
-                       "SYNTAX 1.3.6.1.4.1.1466.115.121.1.40{64} "
+                       "EQUALITY CSNMatch "
+                       "ORDERING CSNOrderingMatch "
+                       "SYNTAX 1.3.6.1.4.1.4203.666.11.2.1{64} "
                        "SINGLE-VALUE NO-USER-MODIFICATION USAGE directoryOperation )",
                NULL, SLAP_AT_HIDE,
                NULL, NULL,
@@ -593,9 +593,9 @@ static struct slap_schema_ad_map {
        { "contextCSN", "( 1.3.6.1.4.1.4203.666.1.25 "
                        "NAME 'contextCSN' "
                        "DESC 'the largest committed CSN of a context' "
-                       "EQUALITY octetStringMatch "
-                       "ORDERING octetStringOrderingMatch "
-                       "SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 "
+                       "EQUALITY CSNMatch "
+                       "ORDERING CSNOrderingMatch "
+                       "SYNTAX 1.3.6.1.4.1.4203.666.11.2.1{64} "
                        "SINGLE-VALUE NO-USER-MODIFICATION USAGE dSAOperation )",
                NULL, SLAP_AT_HIDE,
                NULL, NULL,