Skip to content

Commit

Permalink
[bugfix] Added access encap feature to the path relationship attribut…
Browse files Browse the repository at this point in the history
…e of the floating svi
  • Loading branch information
shrsr authored and lhercot committed Mar 16, 2023
1 parent 8d48446 commit 176bc10
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion client/l3extVirtualLIfP_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func (sm *ServiceManager) ListVirtualLogicalInterfaceProfile(logical_interface_p
return list, err
}

func (sm *ServiceManager) CreateRelationl3extRsDynPathAttFromLogicalInterfaceProfile(parentDn, tDn, addr, forgedTransmit, macChange, promMode string) error {
func (sm *ServiceManager) CreateRelationl3extRsDynPathAttFromLogicalInterfaceProfile(parentDn, tDn, addr, forgedTransmit, macChange, promMode, encap string) error {
dn := fmt.Sprintf("%s/rsdynPathAtt-[%s]", parentDn, tDn)
containerJSON := []byte(fmt.Sprintf(`{
"%s": {
Expand Down Expand Up @@ -87,6 +87,10 @@ func (sm *ServiceManager) CreateRelationl3extRsDynPathAttFromLogicalInterfacePro
jsonPayload.Set(promMode, "l3extRsDynPathAtt", "attributes", "promMode")
}

if encap != "" {
jsonPayload.Set(encap, "l3extRsDynPathAtt", "attributes", "encap")
}

req, err := sm.client.MakeRestRequest("POST", fmt.Sprintf("%s.json", sm.MOURL), jsonPayload, true)
if err != nil {
return err
Expand Down Expand Up @@ -122,6 +126,7 @@ func (sm *ServiceManager) ReadRelationl3extRsDynPathAttFromLogicalInterfaceProfi
paramMap["forgedTransmit"] = models.G(contItem, "forgedTransmit")
paramMap["macChange"] = models.G(contItem, "macChange")
paramMap["promMode"] = models.G(contItem, "promMode")
paramMap["encap"] = models.G(contItem, "encap")

st = append(st, paramMap)
}
Expand Down

0 comments on commit 176bc10

Please sign in to comment.