Share via


Synchronization Across System Definition Model (SDM) Documents

Distributed System Designers keep System Definition Model (SDM) documents and code synchronized as you make changes to them. Distributed system diagrams also visually indicate any issues that arise with these references. Understanding how the different document types relate and synchronize with each other will help you troubleshoot synchronization errors when they occur.

For more information, see the following topics:

The following sections contain information about synchronization across distributed system diagrams:

  • Synchronizing the Application Diagram with System Diagrams

  • Synchronizing the Application Diagram with Code

  • Synchronizing System Diagrams with Other System Diagrams

  • Synchronizing Deployment Diagrams with System Diagrams and Logical Datacenter Diagrams

Synchronizing the Application Diagram with System Diagrams

Visual Studio synchronizes most changes that you make to an application definition on the application diagram with any uses of that definition on system diagrams as long as those system diagrams are open. For example, such changes include editing most properties or adding and deleting endpoints to the application's definition. If a system diagram is not open, Visual Studio synchronizes these changes when you open the system diagram.

However, if you delete an application definition, Visual Studio does not delete its uses from any referencing system diagrams (open or closed). Instead, Visual Studio uses red dashed outlines and squiggly lines to identify those uses as "orphaned" from their missing underlying definition. This makes it possible for you to review the impact of deleting the definition. If you rename an application definition while any system diagrams referencing that definition are closed, Visual Studio will display uses of that definition as "orphaned" when you open those system diagrams.

If you add back the definition or reverse the name change, Visual Studio will remove the outlines and squiggly lines from the orphaned uses. You can also repair individual orphaned uses by associating each of those uses with a different application definition.

For more information, see the following topics:

Synchronizing the Application Diagram with Code

In Distributed System Designers, some application types support implementation. However, simply defining such an application on the application diagram does not immediately generate the corresponding projects, code, and configuration files. First-time code generation is called implementation. For more information, see Implementing Applications on Application Diagrams.

For applications that support implementation, the code becomes the master definition once you implement the application. However, Visual Studio supports full and continuous synchronization between the application definition and the code as long as the application diagram is open. This includes code files and configuration files as well as the corresponding definition on the application diagram. If the application diagram is not open, reopening it will synchronize it with the code, accommodating any changes made while the diagram was closed.

Note

If the application definition (.sdm) file is unavailable for an application that supports implementation when you reopen the application diagram, Visual Studio regenerates that .sdm file. However, the .sdm file will contain only information that Visual Studio can reverse-engineer from code or entries in application configuration files. Visual Studio will not recreate any SDM information or settings whose source is not in code. For example, Visual Studio will not reverse-engineer Web content endpoints on ASP.NET applications from code. If any such endpoints exist on the application diagram when Visual Studio reverse-engineers an ASP.NET application, those endpoints will appear with a red dashed outline. For more information, see Troubleshooting Application Diagrams.

For applications that do not support implementation, their definitions on the application diagram or their corresponding application definition (.sdm) files are the master definitions. If you make changes to these types of .sdm files while the application diagram is closed, such as deleting them, Visual Studio does not regenerate these .sdm files when you reopen the diagram. For example, if you delete any of these types of .sdm files, Visual Studio displays their corresponding application definitions on the application diagram and any uses of those definitions on system diagrams with red dashed outlines to indicate that their definitions are missing. For more information, see Troubleshooting System Diagrams and Application Types and Prototypes for Defining Applications.

Synchronizing System Diagrams with Other System Diagrams

Visual Studio synchronizes most changes that you make to a system definition on a system diagram with any uses of that definition on other system diagrams as long as those referencing system diagrams are open. For example, such changes include adding or deleting proxy endpoints. If the referencing system diagrams are not open, Visual Studio synchronizes these changes when you open the referencing diagrams. For information, see Designing Application Systems with System Designer.

However, if you delete a system definition, Visual Studio does not delete its uses from any referencing system diagrams (open or closed). Instead, Visual Studio uses red dashed outlines and squiggly lines to identify those uses as "orphaned" from their underlying definitions. This makes it possible for you to review the impact of deleting the definition. If you rename a system definition while other system diagrams referencing that definition are closed, Visual Studio will display uses of that definition as "orphaned" when you open those system diagrams. If you add back the definition or reverse the name change, Visual Studio will remove the outlines and squiggly lines from the orphaned uses. You can also repair individual orphaned uses by associating each of those uses with a different system definition. For more information, see Troubleshooting System Diagrams and How to: Repair Orphaned Members in Application Systems.

Synchronizing Deployment Diagrams with System Diagrams and Logical Datacenter Diagrams

A deployment diagram always references a particular system diagram and a logical datacenter diagram and contains a series of binding references. Each binding reference describes the binding of an application on the system diagram to a logical server on the logical datacenter diagram. Changes to the logical datacenter diagram, system diagram, or any of the underlying application definitions can affect the integrity of the deployment diagram. If you edit the system diagram or logical datacenter diagram while a related deployment diagram is open, Visual Studio propagates these changes to the deployment diagram immediately. However, if the deployment diagram is not open, Visual Studio displays error alert states for certain types of changes on the deployment diagram to indicate the changes you made on the system or logical datacenter diagram. For more information, see Evaluating System Deployment with Deployment Designer.

For example, suppose you delete applications from a system diagram, and the binding references for those applications exist on an associated but closed deployment diagram. In addition, suppose you delete a logical server from the associated logical datacenter diagram. When you open the deployment diagram, these binding references will appear with red error (X) icons. The deleted applications will no longer appear in the System View window. The logical server that you deleted from the logical datacenter diagram remains on the deployment diagram and displays a red dashed outline.

For more information, see Troubleshooting Deployment Diagrams.

Synchronizing Deployment Diagrams with System Diagrams

If you create a deployment diagram from the application diagram, the deployment diagram employs an automatically-designed "default system" that you cannot view or edit by using System Designer and does not exist on any system diagram. This default system contains all the applications and connections on the application diagram. Visual Studio will synchronize this default system with any changes that you make on the application diagram. If you create a deployment diagram that uses this default system, the System View window in Deployment Designer displays all the applications available in this default system. Visual Studio will synchronize the deployment diagram and in the System View window with any changes that you make to the application definitions on the application diagram.

If you create a deployment diagram from a manually created system diagram and then make changes to the system diagram, these changes will also affect the System View window and the deployment diagram, provided that you bound those applications on the deployment diagram. For example, if you delete applications from the referenced system diagram, Visual Studio deletes the corresponding binding references on the deployment diagram for the deleted applications.

For more information, see Evaluating System Deployment with Deployment Designer.

Synchronizing Deployment Diagrams with Logical Datacenter Diagrams

If you delete logical servers from a logical datacenter diagram, Visual Studio synchronizes those changes with any open deployment diagrams that reference that logical datacenter diagram. Visual Studio also removes the binding references for the applications bound to those logical servers. You must rebind those applications to other logical servers.

If you add or delete a logical server or zone from a logical datacenter diagram, Visual Studio adds or removes it from any open deployment diagrams that reference that logical datacenter diagram. Visual Studio also moves any logical servers or zones on the deployment diagram that you re-parent on the referenced logical datacenter diagram.

If the associated deployment diagram is closed when you change the referenced system diagram or logical datacenter diagram, then the following occurs when you reopen that deployment diagram:

  • Applications that you added to the referenced system diagram appear as unbound in the System View window.

  • Applications that were bound to logical servers on the deployment diagram remain bound when you delete them from the referenced system diagram. However, their binding references indicate that the applications are no longer unavailable.

    Note

    You must delete these references from the deployment diagram.

  • Logical servers that you delete from a logical datacenter diagram remain on the deployment diagram. However, they appear with dashed red outlines indicating their definitions are missing.

    Note

    You can only delete these references from the deployment diagram as you cannot examine their properties or bind applications to them. You can individually unbind applications that are bound to these logical servers. If you delete the logical server from the deployment diagram, Visual Studio unbinds any applications bound to that server and makes them available for binding to other logical servers.

If the deployment diagram is not open when you make changes to a referenced logical datacenter diagram, you must synchronize the deployment diagram with those changes. Synchronizing the deployment diagram updates it to reflect the current state of the logical datacenter diagram without losing any of the binding information and removes any references to logical servers deleted from the logical datacenter diagram.

For more information, see the following topics:

See Also

Concepts

Workflow Across Distributed System Designers

Distributed System Designers Terminology Overview

Other Resources

Distributed System Designer Overviews