Hi, the code flow of BGP Update serialization is
https://github.com/osrg/gobgp/blob/master/server/fsm.go#L1036 https://github.com/osrg/gobgp/blob/master/packet/bgp/bgp.go#L7057 https://github.com/osrg/gobgp/blob/master/packet/bgp/bgp.go#L6832 func (p *PathAttributeLocalPref) Serialize() Thanks, Wataru > On Aug 18, 2016, at 8:19 AM, dip <diptanshu.si...@gmail.com> wrote: > > Hi, > > I am new to GoLang, so apologies for such a basic question. > > So, I am trying to understand who is calling the Serialize function > associated with various attributes. For instance, for LocalPref we have > Serialize function and i am trying to trace the Code flow to see who is > calling this, but so far I had no luck and hence the question. > > I am clear on the flow when a BGP MSG Update is received and how the > respective attributes are Parsed. > > func (p *PathAttributeLocalPref) Serialize() ([]byte, error) { > fmt.Println("In LocalPref Item...") > buf := make([]byte, 4) > binary.BigEndian.PutUint32(buf, p.Value) > p.PathAttribute.Value = buf > return p.PathAttribute.Serialize() > } > > Please let me know if my question is not clear and i can provide more details. > > Any help will be appreciated. > > > Thanks > Dip > ------------------------------------------------------------------------------ > _______________________________________________ > gobgp-devel mailing list > gobgp-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gobgp-devel ------------------------------------------------------------------------------ _______________________________________________ gobgp-devel mailing list gobgp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gobgp-devel