
Bei der benutzerbasierten Datenpartitionierung werden Benutzer in verschiedenen Datenquellen abgelegt. In welcher Datenquelle sie abgelegt werden, hängt von den Werten der Benutzerattribute ab.
Marcus Kopp möchte reguläre Benutzer in einem Verzeichnisdienst ablegen, während Servicebenutzer in der Datenbank des SAP NetWeaver Application Server (AS) Java abgelegt werden sollen. Ergebnis:
Beispiel
<dataSource id="PRIVATE_DATASOURCE" className="com.sap.security.core.persistence.datasource.imp.DataBasePersistence" isReadonly="false" isPrimary="true"> <homeFor> <principals> <principal type="USER"> <!-- Substructure specified means home for all principals of type "USER" if they have the namespace attribute value triple ($serviceUser$,SERVICEUSER_ATTRIBUTE,IS_SERVICEUSER) in their initial values --> <nameSpace name="$serviceUser$"> <attribute name="SERVICEUSER_ATTRIBUTE"> <values> <value>IS_SERVICEUSER</value> </values> </attribute> </nameSpace> </principal> </principals> </homeFor> <notHomeFor> </notHomeFor> ... </dataSource> <dataSource id="CORP_LDAP" className="com.sap.security.core.persistence.datasource.imp.LDAPPersistence" isReadonly="false" isPrimary="true"> <homeFor> <principals> <principal type="USER"> <!-- No substructure specified means home for all principals of type "USER" except the ones in notHomeFor Section --> </principal> </principals> </homeFor> <notHomeFor> <principals> <principal type="USER"> <!-- Substructure specified means home for all principals of type "USER", but not if they have the namespace attribute value triple ($serviceUser$,SERVICEUSER_ATTRIBUTE,IS_SERVICEUSER) in their initial values --> <nameSpace name="$serviceUser$"> <attribute name="SERVICEUSER_ATTRIBUTE"> <values> <value>IS_SERVICEUSER</value> </values> </attribute> </nameSpace> </principal> </principals> </notHomeFor> ... </dataSource>