From 37395322c5046e5b7714c0b4697d328f3352a375 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Fri, 14 Oct 2016 15:43:46 +1300 Subject: dsdb: specify attributes when loading schema The LDB code performs better when the required attributes are listed, even when it is almost all the attributes Signed-off-by: Andrew Bartlett Reviewed-by: Garming Sam --- source4/dsdb/schema/schema.h | 51 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) (limited to 'source4/dsdb/schema/schema.h') diff --git a/source4/dsdb/schema/schema.h b/source4/dsdb/schema/schema.h index ee2b850530d..75e4886b027 100644 --- a/source4/dsdb/schema/schema.h +++ b/source4/dsdb/schema/schema.h @@ -266,6 +266,57 @@ struct dsdb_schema { bool resolving_in_progress; }; +#define DSDB_SCHEMA_COMMON_ATTRS \ + "objectClass", \ + "cn", \ + "lDAPDisplayName", \ + "schemaIDGUID", \ + "objectGUID", \ + "systemFlags", \ + "schemaFlagsEx", \ + "msDs-Schema-Extensions", \ + "showInAdvancedViewOnly", \ + "adminDisplayName", \ + "adminDescription", \ + "isDefunct", \ + "systemOnly" + +#define DSDB_SCHEMA_ATTR_ATTRS \ + "attributeID", \ + "msDS-IntId", \ + "mAPIID", \ + "attributeSecurityGUID", \ + "searchFlags", \ + "isMemberOfPartialAttributeSet", \ + "linkID", \ + "attributeSyntax", \ + "oMSyntax", \ + "oMObjectClass", \ + "isSingleValued", \ + "rangeLower", \ + "rangeUpper", \ + "extendedCharsAllowed", \ + "classDisplayName", \ + "isEphemeral" + +#define DSDB_SCHEMA_CLASS_ATTRS \ + "governsID", \ + "objectClassCategory", \ + "rDNAttID", \ + "defaultObjectCategory", \ + "subClassOf", \ + "systemAuxiliaryClass", \ + "auxiliaryClass", \ + "systemMustContain", \ + "systemMayContain", \ + "mustContain", \ + "mayContain", \ + "systemPossSuperiors", \ + "possSuperiors", \ + "defaultSecurityDescriptor", \ + "classDisplayName", \ + "defaultHidingValue" + enum dsdb_attr_list_query { DSDB_SCHEMA_ALL_MAY, DSDB_SCHEMA_ALL_MUST, -- cgit v1.2.1