Patent attributes
Some embodiments provide a method for defining a logical network (LN) that spans multiple sites and is managed at each site by a local manager. At a global manager that manages the logical network, the method creates a tree from a definition of the LN that spans the sites. The tree includes nodes representing elements in the LN and connections between the nodes to express relationships between the elements. Each of at least a subset of nodes has a span attribute identifying sites spanned by an LN element corresponding to the node. The method uses the span attributes to create a parsed tree for each site. Based on the parsed tree of each site, the method identifies a portion of the LN definition that is relevant for the site. The method provides, to the local manager of each site, the portion of the LN definition identified for the site.