summaryrefslogtreecommitdiffhomepage
path: root/cmd/gobgpd/main.go
AgeCommit message (Collapse)Author
2019-08-28Document config API and provide examplesCarl Baldwin
2019-08-28Pass context through configuration codeCarl Baldwin
2019-08-28Rename c to currentConfig to follow naming patternCarl Baldwin
2019-08-28Replace for and select with single for rangeCarl Baldwin
2019-08-28Remove loop functionCarl Baldwin
2019-08-28Move ReadConfigFileOnSighup to gobgpd mainCarl Baldwin
Reloading the config file on SIGHUP is behavior specific to gobgpd. Attempts to expose it through the config API was awkward and could make the api more confusing to use. This change moves that functionality up into the gobgpd main and out of the library.
2019-08-28Remove last remants of internal_cfgCarl Baldwin
2019-08-28Switch away from channel for one-off dry runCarl Baldwin
2019-08-28Split creation of config reading channelCarl Baldwin
2019-08-28Remove a reference to internalCarl Baldwin
2019-08-28config -> internal_configCarl Baldwin
2019-08-28Factor out stopServerCarl Baldwin
2019-08-28Move code to new public config packageCarl Baldwin
2019-08-28Improve logic around applying configurationCarl Baldwin
The initial configuration is only applied once right at the very beginning. Everything after that is an update. This makes that clearer.
2019-08-28Extract methods to apply and update configCarl Baldwin
2019-08-28Create a clearer line between initial config and updating configCarl Baldwin
2019-08-28Factor out helpers for peer group and neighbor configCarl Baldwin
2019-08-28Move assignement of current config to the endCarl Baldwin
Now that `c` is no longer referenced in the block above, its assignement can be moved to later. This allows consolidating the two assignements into one and moving them to the very end to magic the logic clearer.
2019-08-28Use newConfig more consistently when apply initial configurationCarl Baldwin
This block of code has for loops that shadow the variable `c` declared above it. This commit makes the scoping a little clearer by using newConfig where possible to avoid the ambiguity.
2019-06-03Add Versioning supportEmil Palm
2019-05-08zebra: supporting FRRouting version 7Hitoshi Irino
- the "version" parameter (which means ZAPI) 6 in zebra config changes supporting FRRouting version 7 instead of FRRouting version 6. - the "software-name" parameter which supports backward compatibility is added in zebra config. (GoBGP support FRRouting version 6 when "version = 6" and "software-name = frr6" is configured.)
2019-05-02Consolidate duplicate code blocks both updating peer groupsCarl Baldwin
There were only two differences: 1) the first block updates `updatePolicy` and 2) the log statements are a little bit different (`pg.State` vs `pg.Config` and `%v` vs `%s`). To be consistent with the other blocks above it, changed to use `pg.Config` rather than `pg.State`.
2019-03-25support BMP sysName and sysDescr configurationJieJhih Jhang
2019-03-14cmd/gobgp: use sd_notify protocol to notify the status change to systemdRobin Douine
2019-03-14Supporting BGP/MPLS L3VPNs with Frrouting Zebra API 6Hitoshi Irino
- 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")
2019-01-27gobgpd: fix the initial global policy configuration from config fileFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com>
2018-12-23make the usage of type name in protobuf consistentFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com>
2018-11-14Fix Statistics Report in BMPEiichiro Watanabe
2018-11-12Fix intervals for MRTEiichiro Watanabe
2018-11-09make gRPC server privateFUJITA Tomonori
No need to be exported. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-10-28move NewAPIRoutingPolicyFromConfigStruct() from server/FUJITA Tomonori
The config is an internal package so it should not be exported. NewAPIPolicyAssignmentFromTableStruct() is approprate for config/. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-10-28move NewAPIPolicyAssignmentFromTableStruct() from server/FUJITA Tomonori
The table is an internal package so it should not be exported. NewAPIPolicyAssignmentFromTableStruct() is approprate for table/. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-10-28move exported functions to generate api structs from config struct in server/FUJITA Tomonori
NewPeerFromConfigStruct() NewPeerGroupFromConfigStruct() NewGlobalFromConfigStruct() The config is an internal package so they should not be exported. We will remove the usage of the config in server/. This is a part of the goal. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-08-23policy cleanupFUJITA Tomonori
- remove ReplaceDefinedSet and ReplaceStatement APIs; not intutive and should create a new one instead of modifying the existing. - Rename ReplacePolicyAssignment to SetPolicyAssignment API; we use internally SetPolicy() name from the beginning. - Rename UpdatePolicy() to SetPolicies() API; It doesn't update anything so the name is confusing. It discards the all policies and create policies from the argument. - Changes some member names in structures for policy. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-08-18pkg/server: ListPolicyAssignment() returns all assignments by defaultFUJITA Tomonori
Like other ListPolicy*() functions, if no conditions are specified, all assignments are returned. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-08-08rpc cleanupFUJITA Tomonori
- clean up RPC function names - rewrite gobgp command to use the api instead of config package - delete unused client package Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-07-08remove package dependency except for grpc in api/FUJITA Tomonori
Nothing except for protobuf IDL files and files generated by protobuf in api/. Try to make the APIs portable to any languages. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-07-07follow Standard Go Project LayoutFUJITA Tomonori
https://github.com/golang-standards/project-layout Now you can see clearly what are private and public library code. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>