Patent ID: 8000327

Claim:
A method comprising: with a router, building forwarding information for forwarding packets along a Multiprotocol Label Switching (MPLS) label switched path (LSP) of a first type, wherein the router is an intermediate router on the LSP of the first type positioned between an ingress router and an egress router of the LSP of the first type; with the router, building forwarding information for forwarding packets along an MPLS LSP of a second type, wherein the router is an ingress router of the LSP of the second type; receiving the packets on the LSP of the first type at the router, wherein the packets include MPLS labels having a label value that corresponds to the LSP of the first type, and wherein each of the MPLS packets includes MPLS Experimental (EXP) bits that have been defined to identify a class of service to which a respective packet belongs; for each of the packets, accessing the forwarding information at the router to determine whether to forward the packet along the LSP of the first type or to forward the packet along the LSP of the second type based on (1) an MPLS label of the packet and (2) the class of service specified in an EXP bit of the packet; determining whether the forwarding information includes an entry corresponding to both: (1) the label value corresponding to the MPLS LSP from which the packet was received, and (2) the class of service specified by the EXP bits; when no entry exists, accessing routing information maintained by the router for the specified class of service and dynamically updating the forwarding information based on the routing information to include an entry that maps the label value corresponding to the MPLS LSP and the specified class of service to the LSP of the second type; from the router, forwarding packets associated with a first class of service along the LSP of the first type in accordance with the forwarding information; and from the router, forwarding packets associated with a second class of service along the LSP of the second type in accordance with the forwarding information.