diff options
author | Hitoshi Irino <irino@sfc.wide.ad.jp> | 2019-03-02 13:54:38 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@gmail.com> | 2019-03-14 21:20:31 +0900 |
commit | 3a79ad3fdcbb7af0b7911a9c610c6e7af970ad6d (patch) | |
tree | 40911a6e5be205a15752aa11ea3b2e4f7335ebfa /internal/pkg/config | |
parent | dc4d9c6d1b253bc3a381f82941796b6bb8c71384 (diff) |
Supporting BGP/MPLS L3VPNs with Frrouting Zebra API 6
- This commit aims to solve reported problem on issues #1611, #1648 and #1912
- Partial changes of this commit duplicate with changes on PR #1587 (not merged) and PR #1766 (not merged and already closed)
- This commit is tested with only FRRouting version 6.0.2 (which uses Zebra API 6)
- This commit fixes lack of LABEL_MANAGER_CONNECT_ASYNC for ZAPI6.
(This bug is introduced on commit 2bdb76f2dcf24b891f2b6327a57c31b26463b2dd "Supporting Zebra API version 6 which is used in FRRouting version 6")
Diffstat (limited to 'internal/pkg/config')
-rw-r--r-- | internal/pkg/config/bgp_configs.go | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/internal/pkg/config/bgp_configs.go b/internal/pkg/config/bgp_configs.go index 7a533b56..d8b575b0 100644 --- a/internal/pkg/config/bgp_configs.go +++ b/internal/pkg/config/bgp_configs.go @@ -1121,13 +1121,18 @@ type ZebraState struct { // original -> gobgp:redistribute-route-type RedistributeRouteTypeList []string `mapstructure:"redistribute-route-type-list" json:"redistribute-route-type-list,omitempty"` // original -> gobgp:version - // Configure version of zebra protocol. Default is 2. Supported up to 3. + // Configure version of zebra protocol. Default is 2. + // Supported version are 2 or 3 for Quagga and 4, 5 or 6 for FRRouting. Version uint8 `mapstructure:"version" json:"version,omitempty"` // original -> gobgp:nexthop-trigger-enable // gobgp:nexthop-trigger-enable's original type is boolean. NexthopTriggerEnable bool `mapstructure:"nexthop-trigger-enable" json:"nexthop-trigger-enable,omitempty"` // original -> gobgp:nexthop-trigger-delay NexthopTriggerDelay uint8 `mapstructure:"nexthop-trigger-delay" json:"nexthop-trigger-delay,omitempty"` + // original -> gobgp:mpls-label-range-size + // Configure MPLS label range size which will be requested to + // FRR/Zebra. + MplsLabelRangeSize uint32 `mapstructure:"mpls-label-range-size" json:"mpls-label-range-size,omitempty"` } // struct for container gobgp:config. @@ -1142,13 +1147,18 @@ type ZebraConfig struct { // original -> gobgp:redistribute-route-type RedistributeRouteTypeList []string `mapstructure:"redistribute-route-type-list" json:"redistribute-route-type-list,omitempty"` // original -> gobgp:version - // Configure version of zebra protocol. Default is 2. Supported up to 3. + // Configure version of zebra protocol. Default is 2. + // Supported version are 2 or 3 for Quagga and 4, 5 or 6 for FRRouting. Version uint8 `mapstructure:"version" json:"version,omitempty"` // original -> gobgp:nexthop-trigger-enable // gobgp:nexthop-trigger-enable's original type is boolean. NexthopTriggerEnable bool `mapstructure:"nexthop-trigger-enable" json:"nexthop-trigger-enable,omitempty"` // original -> gobgp:nexthop-trigger-delay NexthopTriggerDelay uint8 `mapstructure:"nexthop-trigger-delay" json:"nexthop-trigger-delay,omitempty"` + // original -> gobgp:mpls-label-range-size + // Configure MPLS label range size which will be requested to + // FRR/Zebra. + MplsLabelRangeSize uint32 `mapstructure:"mpls-label-range-size" json:"mpls-label-range-size,omitempty"` } func (lhs *ZebraConfig) Equal(rhs *ZebraConfig) bool { @@ -1178,6 +1188,9 @@ func (lhs *ZebraConfig) Equal(rhs *ZebraConfig) bool { if lhs.NexthopTriggerDelay != rhs.NexthopTriggerDelay { return false } + if lhs.MplsLabelRangeSize != rhs.MplsLabelRangeSize { + return false + } return true } |