Age | Commit message (Collapse) | Author | Files | Lines |
|
- 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>
|
|
vpp cleans up socket clients when the socket closes. I verified that
sending a correctly-marshalled sockclnt_delete message results in
duplicate close complaints.
The marshalling code wasn't right - the (important) client_index field
is in a non-standard position - and there's no point in sending
a message we don't need to send.
Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Ia32980b08a99cc878835f5db21f64de391759fa4
|
|
* use generated Marshall/Unmarshall for socket client connection
messages instead of the generic wrapper
Change-Id: Ie1049e080630dbc60085debc6875e17962e93a0e
Signed-off-by: Vladimir Lavor <vlavor@cisco.com>
|
|
* added example showing management of 2 VPP instances with different sockets
* updated changelog
Change-Id: I531eda8f055cc2a24ba2210217e70a8ad42a47c0
Signed-off-by: Vladimir Lavor <vlavor@cisco.com>
|
|
README.md needs further cleanup
Signed-off-by: Dave Barach <dave@barachs.net>
Change-Id: Iee170f909b57548d53f8a5fa67cd387652ccac99
|
|
* Many aliases removed, aliased types reference original types via import instead
* Added various helper methods for simpler conversion between go and vpp types
Change-Id: I7999ac8d524cece4da03e6447b13421659765095
Signed-off-by: Vladimir Lavor <vlavor@cisco.com>
|
|
Change-Id: I2698e11b76ff55d9730b47d4fee990be93349516
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: Idd76c7f19d952939caf153928ac60175845078ff
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I5a6abb68b9d058866f94818169300e5c2fc43895
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
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>
|
|
Change-Id: I14aa5446ad218f06a06b9e40e0adde6ca81e4819
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- fixes panic occurring when updating error counters
- fixes stat data length errors when updating stats
Change-Id: If2d4bcb7df084bf1999ba469f128b7a01aa6be5e
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
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>
|
|
Change-Id: Icd4173edc55d83b1766f204184eb818b859e648e
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- this change fixes panic that was occurring with recent VPP that was caused by incorrectly calculated vector length
- converting returned vector length from uint64 to uint32 results in correct length value
Change-Id: I76a4b9d147c3df3bea9d3e5ef5853e2809dc42e8
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I6af1ae2778b73f37be09c64a2948417e576f02ab
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- 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>
|
|
Change-Id: I2e6ad9fb51e1cf55a52267720f2394e792946f7e
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I10dfbaa38de67835a84f5112d6b16bbe466c3bfe
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: Ibfc1f97e299256809978cb84f1685aa6729e898c
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- added CompatibilityError to api package to represent error with
list of incompatible messages
- added UnknownMsgError to adapter package to represent error for
unknown message
- added list of registered message types
Change-Id: I2623b45135521d52612ba91e4605fc064a7fc76e
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- 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>
|
|
Change-Id: Ifed742e75a48d065987d945c8667af2bdedb876a
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Signed-off-by: Matus Mrekaj <matus.mrekaj@pantheon.tech>
Change-Id: I932d560548ee816e28683243a7318a2a7fbbb24a
|
|
Signed-off-by: Matus Mrekaj <matus.mrekaj@pantheon.tech>
Change-Id: I1ab9efb9e575e7993501e7774628cbb60d16ec43
|
|
Change-Id: I54cd9ca6fb6607a70031ba5e6318a9ea58db7e6c
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- proxy server defines RPC service for proxying binapi/stats to VPP
- use cmd/vpp-proxy for proxy server/client
Change-Id: I6e698e166ecf6db7109ae5adf8a93f308d3f3f2a
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- 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>
|
|
Change-Id: I12285c77c9cf09a24c957a777b26ae54f082f317
Signed-off-by: Ravi Raju <ravir@employees.org>
|
|
- fixed generator for new string types
- update simple client example
- regenerate examples binapi for VPP 19.08
Change-Id: If4fe78c130d95641f35f75cd0262b35b032acaf8
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I1a6839e3bbb8d599fcbdbc2b1aff7c81f7d263c9
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
There is a problem to use upstream govpp with vpp 18.04 because of
lack stat_client.h file. Build tag allows to exclude stat client
from old vpp versions.
Signed-off-by: Rinat Baygildin <bayrinat@yandex-team.ru>
Change-Id: Ic39029b0c4577f88ff8796dfd14e6a2696f85f4c
|
|
- 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>
|
|
Change-Id: I49e0ec8420cf2563b77ec2b5a9cf9674286d5e5d
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: If9da8381212273f8f2655d7b0a3077b5ba32921f
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: Ibdbfcb78b05cf80945a93ed424a7a2a03b6ea06d
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- in VPP 19.08 the socket type has changed to STREAM and data has to
be writtento VPP with single flush, otherwise msg might get mixed
with next header and cause VPP to stop responding
- this also fixes WaitReady for socketclient and vppapiclient
Change-Id: I022724c0c09c9b92d4c695d1cf2be15994fff717
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I2d6f5eacae0cc71e659f904aa604ff0519daa79c
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I87251362668bbe9a31f52c1b5e9b3ab596f7b2f3
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- .api.json input files from VPP now sometimes contain duplicate objects
- parsing is skipped if type is already known
Change-Id: Ibf28f5baa68f6cfb40aeb75e1bde72241120ac23
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- omit entries with empty/invalid names
- change log level to debug for invalid entries
- remove some excessive debug logs
- improve log message when falling back to old stat segment version
Change-Id: If9ceae9a42e586172bbec130452fba9dfbab2cd7
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- RPC service client implementation for dumps requests
now streams responses
- RPC service generation is now enabled by default
- examples now allow setting binapi socket address
- input dir flag for binapi-generator will recursively look
into dirs to support core/plugins in /usr/share/vpp/api
- minor improvements in debug logs
- add support for VPP 19.04 for statsclient
Change-Id: I0939ee3aa6e9f850d073fc5c87aff4ccc56b0d70
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: Ia5bab652c6089378697459f477f9060dc7a53e90
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- method GetCrcString() was also removed from DataType interface
- fix generated comment for services
- fix permissions for created files and directories
Change-Id: If0b7a57e01f1128b5ba574fc5ee13b6a7c6aa6fd
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- 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>
|
|
- this also fixed proper alphabetical order for struct tags
- env var DEBUG_BINAPI_GENERATOR=y can be used to enable debug mode
Change-Id: I5b08a696ad2ff2a297872f231f9229cd956ee443
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
- this fixes compilation error for VPP 19.08 and keeps
backwards compatibility with previous versions
Change-Id: Ib58557a090caa5e8342c0cb21de8af684cb18137
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
|
|
Change-Id: Id0164d36727d070e395a522000f2e09ee5444bd0
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|
|
Change-Id: I16ae8dbb5214e022304f4e8ae60798b370567fc8
Signed-off-by: Ondrej Fabry <ofabry@cisco.com>
|