SQL Server User data synchronous plugin#
Features#
- ServerThe pattern implements the SQL through the standard SCIM interface Users and organizations in the Server database
- ClientThe mode is implemented. Users and organizations in Server, Synchronous to SQL In Server database
Configure two SQL Synchronous database between the Server database#
Create two databases and tables#
-
Create a Server database that provides synchronous data,Establishusers, groupssurface, And the intermediate table of the Groups of userusers_groups, users_groupsUser in the middle table_ID key associated Users (ID), group_ID key associated Groups (ID)
Hint
In this example, the relationship between the User and Group is the relationship between Manytomany, If the user belongs to only one group,allowableusersDefinition group in the table_id,GROUPS (ID)
-
Create a client database,Used to synchronize the data provided by the server database to the Client database
Notice
Convenient for demonstration,The table definition in the client database is the same as the Server database,The actual production environment may be different
Configure SQL Server Source database#
Hint
If the user and group are more paired,Need to be filled inUser table group outer key field If the user and group are more to the relationship,Need to be filled inUsers and organizations are more to multi -relationship tables, User Organic Relationship Table User outer key field, User Organic Relationship Form Group outer key field groupThe fields associated between superiors need to be set upOrganization table Parent outer key field Targets must exist in user and organizational attribute mapping lists_ATTR is a mapping of ID, The ID of the user and group in the SCIM protocol here
Configure from the source database synchronous data to the client database#
Hint
If the user and group are more paired,Need to be filled inUser table group outer key field If the user and group are more to the relationship,Need to be filled inUsers and organizations are more to multi -relationship tables, User Organic Relationship Table User outer key field, User Organic Relationship Form Group outer key field groupThe fields associated between superiors need to be set upOrganization table Parent outer key field Source must exist in the user and organizational attribute mapping list_ATTR is a mapping of ID,Used to match the data in the Server and Client database, Determine whether the data has been synchronized