aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
AgeCommit message (Collapse)AuthorFilesLines
2022-08-02Change module name to go.fd.io/govppHEADv0.6.0-alphamasterNathan Skrzypczak1-1/+1
We are changing the module name from git.fd.io/govpp.git to go.fd.io/govpp to make repository migration easier. Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> Change-Id: Idd6e0d583a92f6b82fe9adeffd026cd6b856038b
2022-05-30binapi: remove internal/testbinapiNathan Skrzypczak1-7/+1
This patch is a proposal to remove the necessity to version two versions of the generated api. We would rely on `./binapi/` for 'internal' logic, making the dependancy on VPP a bit stronger, but removing a folder and a .json file we don't upgrade regularly. Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> Change-Id: I99063ed571eb193271b3cda805d692155ac90f61
2022-05-30Update generated binapi to v22.02 & makefile changesNathan Skrzypczak1-28/+44
This patch does some small updates to the Makefile. * `make gen-binapi-from-code` is removed, and moves to `gen-binapi-local` * `make build` is patched to build cmd & examples * `make binapi-generator` to build the api-generator without other binaries, as they typically require its output to build. * `make gen-binapi-local` runs the locally built binapi-generator to update the local bindings. It expects ${VPP_DIR} to be set and to point to a local vpp repository checked out with the right version * `make gen-binapi-internal` runs the locally built binapi-generator to update the bindings in `internal/testbinapi/binapi2001` Regarding VPP, notable changes when moving to v22.02 are : - ControlPing moved from vpe to memclnt - CliInband went from vpe to vlib Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> Change-Id: Ie5cd2d5ded7ecaffd9abc3ca675df40be272b1fa
2020-10-02Check retval value and convert to error in generated RPC client codeOndrej Fabry1-40/+27
Change-Id: I816b4802cb5fc46239f6db0480fa4cf3645fe2f0 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-09-03Improve doc & fix import orderingNathan Skrzypczak1-3/+25
This also updates /binapi and adds a new make command to generate api files out of a local vpp repo clone Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com> Change-Id: Iff7965388a74ecd21af80f10b5a59d4ed8da6340
2020-08-04Add SetLogger for setting global loggerOndrej Fabry1-2/+2
- list prerequisites in README - avoid calling go list by hard-coding module path Change-Id: Ib8af1934f55b7e112a8124a20f1f4d39ce651133 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-07-22Fix binapigen decoding and minor improvementsOndrej Fabry1-3/+4
- fixed allocating byte slices before copying decoded data - simplified encoding functions - several minor improvements Change-Id: I6669424b89eb86333805cb1b57e4551169980cc2 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-07-17Improve binapi generatorOndrej Fabry1-8/+8
- simplified Size/Marshal/Unmarshal methods - replace struc in unions with custom marshal/unmarshal - fix imports in generated files - fix mock adapter - generate rpc service using low-level stream API (dumps generate control ping or stream msg..) - move examples/binapi to binapi and generate all API for latest release - add binapigen.Plugin for developing custom generator plugins - optionally generate HTTP handlers (REST API) for RPC services - add govpp program for browsing VPP API Change-Id: I092e9ed2b0c17972b3476463c3d4b14dd76ed42b Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-06-24Fix codec fallback and generate type importsOndrej Fabry1-1/+1
Change-Id: Idd76c7f19d952939caf153928ac60175845078ff Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-06-22Refactored binapi generator with message encodingOndrej Fabry1-1/+2
Change-Id: I5a6abb68b9d058866f94818169300e5c2fc43895 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-06-16Optimize socketclient adapter and add various code improvementsOndrej Fabry1-1/+1
This commit includes: Features - optimized [socketclient](adapter/socketclient) adapter and add method to set client name - added list of compatible messages to `CompatibilityError` Fixes - `MsgCodec` will recover panic occurring during a message decoding - calling `Unsubscibe` will close the notification channel Other - improved log messages to provide more relevant info Examples - added more code samples of working with unions in [union example](examples/union-example) - added profiling mode to [perf bench](examples/perf-bench) example - improved [simple client](examples/simple-client) example to work properly even with multiple runs Dependencies - updated `github.com/sirupsen/logrus` dep to `v1.6.0` - updated `github.com/lunixbochs/struc` dep to `v0.0.0-20200521075829-a4cb8d33dbbe` Change-Id: I136a3968ccf9e93760d7ee2b9902fc7e6390a09d Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-04-17Format generated Go source code in-processv0.3.4Ondrej Fabry1-1/+0
This commit: - removes dependency on gofmt tool - cleans up package imports - re-generates binapi for VPP 20.01 Change-Id: Ie4347720f92a87eb278be66c9f9ed9719c7bbbc3 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2020-03-18Release 0.3.0v0.3.0Ondrej Fabry1-4/+11
- regenerate examples/binapi for latest VPP from stable/2001 - add import-prefix flag to set custom prefix (fallbacks to using go list) Change-Id: Ib09f134cf9662e348be2575448964de2b9e5c1ee Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2019-11-05Begin development of next release 0.3.0Ondrej Fabry1-58/+72
- update info in package ./version - update to Go 1.13 - regenerate ./examples/binapi for latest VPP: 19.08.1-release - clean code in proxy - refactor Makefile Change-Id: Ibf5c2682c2f4b3cbbea4aa1e35d3f02175d40a9b Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2019-10-03Optimizations for statsclientOndrej Fabry1-6/+10
- this dramatically improves performance for stats data collection - memory allocation is now done only when stat dirs change - updating prepared stat dir does not need to allocate memory - created integration test for testing stats client - added NumWorkerThreads and VectorRatePerWorker to SystemStats - added ReduceSimpleCounterStatIndex, ReduceCombinedCounterStatIndex for aggregating specific index Change-Id: I702731a69024ab5dd0832bb5cfe2773a987359e5 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2019-08-02Migrate to modules, refactor Makefile and use Travis for CIOndrej Fabry1-45/+71
- migrate to Go modules and remove vendor - refactor Makefile - add version package and store version - split extras from the rest - use travis for CI Change-Id: I81b35220653b0f7c9a0fcdd4c527d691ec1e96c1 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2019-06-06Add various generator improvementsOndrej Fabry1-1/+1
- generate service implementation for modules - generate conversion maps and String() method for enums - generate module name and version as constants - rename Union_data field to XXX_UnionData for consistency - generate constant GoVppAPIPackageIsVersionN for checking compatibility with API - add example for using service clients - add some documentation to socketclient adapter - cleanup gen.go file used for generating binapi - regenerate binapi with latest VPP release (19.04.1) - change global variables Messages into a function AllMessages Change-Id: Id1ef97764570759eaa3e5a4dc14ecda7a168ee39 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2019-04-04fix govpp, add more checks to makefileVladimir Lavor1-1/+1
Change-Id: Ie118b0c254e5d70e66d5cb4a5f6eb8fa852f0ed8 Signed-off-by: Vladimir Lavor <vlavor@cisco.com>
2019-02-08Generator improvements and cleanupOndrej Fabry1-10/+12
- generator now supports include-comments flag (as opt-in) - minor code cleanup in binapi-generator - remove obsolete unit tests - flatten examples from examples/cmd folder - introduce constant for checking compatibility in future versions Change-Id: I3545f2ba4b869a3b51d6d0de7e742f3f1e1be392 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2019-01-10Add support for string typesOndrej Fabry1-0/+12
- strings are now generated as two fields for length and string itself - aliases are now sorted by name to prevent generating different code - dependencies are now managed by dep - binapi files are regenerated using VPP 19.01-rc0~622-g7b01e9e8 - old stats binary api has been deprecated and removed from VPP Change-Id: Ieb8515c73021339a45f407386f8e3d87dcf4469e Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2018-10-03Omit message factory and line numbers from generated outputOndrej Fabry1-22/+40
Change-Id: Ie48cc0a641242625daf55caf00ab630e78aa86b7 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2018-08-24Simplify subscribing to events and fix eventsOndrej Fabry1-1/+0
- there is no need for sending subscription requests through channels, since all the messages are registered and no communication with VPP is needed Change-Id: Ibc29957be02a32e26309f66c369a071559b822a9 Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
2018-07-16Merge "Add support for jumbo frames to libmemif"Rastislav Szabo1-0/+1
2018-07-09Merge "make api.Channel as interface"Rastislav Szabo1-1/+0
2018-07-06Add support for jumbo frames to libmemifTomas Slusny1-0/+1
Add support for frames larger than maximum buffer size to libmemif adapter. Change-Id: I8b2d9fe7e05328194cd0aafd6e3ab40392ebbfed Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
2018-07-06make api.Channel as interfaceVladimir Lavor1-1/+0
Change-Id: I052d241ab09043b1195beebeee99df4d8536621f Signed-off-by: Vladimir Lavor <vlavor@cisco.com>
2018-07-02Add gopacket adapter for libmemifTomas Slusny1-0/+1
Add simple PacketHandle adapter for gopacket PacketDataSource + add writePacketData convenience method to it. Change-Id: I2280db33076c497c9b63fd107b6d77ecf85dd23b Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
2017-10-13ODPM 266: Go-libmemif + 2 examples.Milan Lenco1-1/+7
Change-Id: Icdb9b9eb2314eff6c96afe7996fcf2728291de4a Signed-off-by: Milan Lenco <milan.lenco@pantheon.tech>
2017-07-11added performance benchmark exampleRastislav Szabo1-0/+2
Change-Id: Ia0fea0569be3da7fadac9ef32d5f12c0b6de0089 Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-25added async connect API, new structure of examplesRastislav Szabo1-3/+5
Change-Id: Iab9bce174596c30998981e02b7030c248c423384 Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-22binapi-generator renamed & moved, finished documentationRastislav Szabo1-4/+6
Change-Id: I7d3b53fa238e822b36a6a82c61ffb792da3898bf Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-22fixed golint issuesRastislav Szabo1-1/+1
Change-Id: I325fa618d8db7a9f1783ec7d208fd7b6e853d9a3 Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-05added lint make targetRastislav Szabo1-0/+3
Change-Id: I994f45837f9e5ac6aba21ad42c6eff083e8aad23 Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-04re-generate core & example binary APIsRastislav Szabo1-1/+5
Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-04modified test make targetRastislav Szabo1-2/+2
Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-04modified test make targetRastislav Szabo1-2/+2
Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-04modified test make targetRastislav Szabo1-1/+3
Signed-off-by: Rastislav Szabo <raszabo@cisco.com>
2017-05-04added MakefileRastislav Szabo1-0/+13
Signed-off-by: Rastislav Szabo <raszabo@cisco.com>