Geeks With Blogs

News My Blog has been MOVED to
Michael Freidgeim's OLD Blog My Blog has been MOVED to

There is a thread: Role SynchronizationMode that asked what the meaning of the parameter in core AddRole method.
I investigated ability to syncronize roles from custom database to DNN and can post answer for this question(according to 4.0.2 core).

Parameter SynchronizationMode is used to implement “lazy” synchronization for roles.

If new role has been added to AspNet_Roles DNN calls synchronization to update satellite dnn_Roles table.


Parameter SynchronizationMode is used in RoleController.AddRole to indicate whether the role should be added to both the AspNet_Roles and dnn_Roles(SynchronizationMode=false) or to dnn_Roles only (SynchronizationMode=true).

The common use is to call AddRole(ByVal objRoleInfo As RoleInfo) overload, which corresponds to SynchronizationMode=false.


The call stack for syncronization (SynchronizationMode=true )is the following:

DotNetNuke\admin\Security\Roles.ascx.vb: BindData ->

RoleController.GetPortalRoles(PortalId, True)->


objRoleController.AddRole(objRoleInfo, True)


There is also method

RoleController.GetRoleByName(ByVal PortalId As Integer, ByVal RoleName As String, ByVal SynchronizeRoles As Boolean) that also can be called to synchronize roles,  

but I didn’t find that is is called from anywhere with SynchronizeRoles=true.


Posted on Tuesday, May 30, 2006 9:24 AM DotNetNuke | Back to top

Comments on this post: Lazy roles Synchronization in DotNetNuke.

# re: Lazy roles Synchronization in DotNetNuke.
Requesting Gravatar...
That was inspiring,

it is better than using the configuring management

Left by web development company on Aug 11, 2009 5:10 AM

Your comment:
 (will show your gravatar)

Copyright © Michael Freidgeim | Powered by: