+

Search Tips   |   Advanced Search

Synchronize remote application data with the Communities database

If we identify data inconsistencies between communities and their remote applications, to synchronize remote applications with the current state of communities, run...

Be sure that all remote applications are running and the widget lifecycle retry queue is empty.

We can synchronize the following types of information from the community to the remote applications:

There are four commands for synchronizing remote application data with the Communities database:

These commands can result in a loss of data if misused. Therefore, use these commands under the following circumstances only:

  1. Start the Communities Jython script interpreter

  2. Enter the following command to synchronize remote applications with a single community:

    CommunitiesRemoteAppService.resyncRemoteAppsForCommunity("communityUuid")

    We can obtain the UUID for a community or subcommunity by doing one of the following actions:

    • Use a browser, open the community or subcommunity you want and copy the UUID from the URL.

    • Run the CommunitiesService.fetchAllComm() wsadmin command to fetch all communities and subcommunities on the server. Copy the UUID from the output.

    For example:

    CommunitiesRemoteAppService.resyncRemoteAppsForCommunity("59d8e5a7-ba0e-488f-8bcd-1f79a994e419")

    If the community with UUID: 59d8e5a7-ba0e-488f-8bcd-1f79a994e419, contains the Activities, Status Update and Files widgets, the command resynchronizes communities data to these three remote applications.

  3. Enter the following command to synchronize remote applications with a single community and widget: CommunitiesRemoteAppService.resyncRemoteAppsForCommunityAndWidget("communityUuid","widgetDefId") Valid input values for widgetDefId are :

    • Activities

    • Blog

    • IdeationBlog
    • Files

    • Forum

    • Library

    • StatusUpdates

    • Wiki

    widgetDefId values are case-sensitive, we must enter these values as shown. For example:

    CommunitiesRemoteAppService.resyncRemoteAppsForCommunityAndWidget("c0281270-44a9-4be0-a9d6-db64f63d", "Forum")

    One widget (Forum) in one community is resynchronized.

  4. Enter the following command to synchronize remote applications with all communities:

    CommunitiesRemoteAppService.resyncRemoteAppsForAllCommunities("widgetDefId")

    The command outputs the UUID of the last community it synchronized, and updates every 10 communities. It ends with "Done"when all communities are resynchronized on the server.

    Here is a sample of the type of response you receive when we synchronize a remote wiki with all communities:

    wsadmin>CommunitiesRemoteAppService.resyncRemoteAppsForAllCommunities("Wiki")
    Total Processed: 10   Last processed communityUuid: 048d011f-e2c1-4d11-975e-b3afb474c8db
    Total Processed: 20   Last processed communityUuid: 0af8a947-7de9-424f-9f88-c984ebe169f7
    .
    .
    .
    Total Processed: 270   Last processed communityUuid: 554d79ae-0e81-4f54-a4b8-6a2c4497ba5c
    Done.

  5. If a network or server outage causes resyncRemoteAppsForAllCommunities() to fail to restart the synchronization beginning where the last synchronization step failed. CommunitiesRemoteAppService.restartResyncRemoteAppsForAllCommunities("lastCommunityUuid", "widgetDefId")

    For example:

    CommunitiesRemoteAppService.restartResyncRemoteAppsForAllCommunities("44f52a77-bccd-433c-bdf9-2d19f42d944b", "Wiki")


Parent topic:
Recover from a database failure


Related:

Synchronize user data


Related:

Recovering remote Connections applications

Related reference:

Communities administrative commands