summaryrefslogtreecommitdiffstats
path: root/src/plugins/hs_apps
AgeCommit message (Collapse)AuthorFilesLines
2024-08-29vcl: add support to write segmentsAritra Basu2-5/+34
Type: improvement Change-Id: Icfdaed6b70b83668127656930afcb4ac3c63b234 Signed-off-by: Aritra Basu <aritrbas@cisco.com>
2024-08-28hsa: http_cli coverity fixMatus Fabian1-1/+1
Type: fix Change-Id: I23c55e6be08cc02332da9375d2eb19b74b79427c Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-08-28http: http_state_wait_app_reply improvementMatus Fabian1-0/+8
set http status according to whether app also sent the body Type: improvement Change-Id: Ia41603cc21b410ca6929ec3d3e7c4c6808305769 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-08-06http: client POST methodMatus Fabian2-0/+570
Type: improvement Change-Id: Iaa70abcee02866f9a6426a6e8e4709eeba0e8114 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-07-29http: client code improvementMatus Fabian3-40/+72
Client app can sends request target, custom header and body to HTTP layer. In response it receives all bytes as received from transport, aditionally we provide offset and length of headers and body. In addtion client app is now able to receive response with all status codes and Host header field is set in request at protocol layer. Type: improvement Change-Id: I8c8e2c8f99cdf500126b7c2c722aebc254aa0d9f Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-07-23http: state machine fixMatus Fabian2-0/+172
When client sends second request without waiting for response of the first request http_ts_rx_callback should drop request (pipelining is not supported) instead of invoking return to state machine which can lead to erroneous state, e.g. reading random data from server app fifo. Added simple http static server url handler for testing to simulate long running request processing, for now hardcoded delay 5 seconds. Type: fix Change-Id: Ied9f7e2e4ee64c982f045c0f7f99a2dc5d7a2108 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-07-23http: return more than data from server appMatus Fabian2-17/+82
Server app could return headers in front of body/data buffer. Offers apis for building and serialization of headers section. HTTP layer now only add Date, Server and Content-Lengths headers, rest is up to app. Well known header names are predefined. Type: improvement Change-Id: If778bdfc9acf6b0d11a48f0a745a3a56c96c2436 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-06-13http: return more than url to server appMatus Fabian2-35/+103
Provide all bytes as received from transport as data in the http message to server. Additionally provide offset and length of target path, target query, headers and body. Offers apis for parsing of headers, percent decoding, target path/query syntax verification. Type: improvement Change-Id: Idbe6f13afa378650cc5212ea7d3f9319183ebbbe Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-05-14http: notify client when connection failedMatus Fabian1-0/+6
Type: fix Change-Id: I87054e9667fe990d9a2dc3950bc3ce348460018a Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-05-14http: fix server sending all status codesMatus Fabian1-0/+7
Type: fix Change-Id: I4bc748e3091c2fbe0142d1b74d21a543a62c4ce0 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-05-07http: notify client on request errorMatus Fabian1-2/+16
Notify client app that we errored out while trying to generate request. Type: fix Change-Id: I3e20fe22d8a927ae8e9bf8391297e10c974dc941 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-05-01http: fix client receiving large dataFilip Tehlar1-5/+8
HTTP client was relying on synchronous rx notifications to the client app when moving lage data from underlying transport proto. Recent change in session layer made such notifications asynchronous making http client not working. This patch fixes the issue. Type: fix Change-Id: I4b24c6185a594a0fe8d5d87c149c53d3b40d7110 Signed-off-by: Filip Tehlar <ftehlar@cisco.com> Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-04-25hsa: Link against libepoll-shimTom Jones1-2/+2
Type: improvement Change-Id: I08610ce71282f10c587d956b27e0f572a812bedd Signed-off-by: Tom Jones <thj@freebsd.org>
2024-04-24hsa: fix http client error handlingMatus Fabian1-1/+1
Type: fix Change-Id: I5595260b903e3e1f15caccd168914f33f7161b59 Signed-off-by: Matus Fabian <matfabia@cisco.com>
2024-03-12misc: remove GNU Indent directivesDamjan Marion5-12/+0
Type: refactor Change-Id: I5235bf3e9aff58af6ba2c14e8c6529c4fc9ec86c Signed-off-by: Damjan Marion <damarion@cisco.com>
2024-02-26hsa: Undef libepoll-shims close on FreeBSDTom Jones1-0/+11
libepoll-shim has some hacks to enable functionality, one of these redefines close as a macro. This conflicts with a close call back. On FreeBSD undefine this macro at point of use. Type: improvement Change-Id: I7b4f7cd874f3451d76c580cf999369426d9e89c2 Signed-off-by: Tom Jones <thj@freebsd.org>
2024-01-02http: unify client/server state machinesFilip Tehlar1-2/+13
Type: improvement Change-Id: I57a816fbed8b681dec201edc8d5950a34a555a2b Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2023-10-31hsa: use common app session interface in echo testsFilip Tehlar4-86/+56
Type: test Change-Id: Ib320cfb5e20f12614c013a92ac15490f8ca3a7ce Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2023-10-30hsa: preallocate sessions on server sideFilip Tehlar1-107/+110
Type: test Change-Id: Ib809f5a6c9e2f08d87f0070231df04d5f0040ca0 Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2023-10-27hsa: fix coverity warningFilip Tehlar1-0/+5
Type: test Change-Id: Iba94edb7eb439ddc994d9a16cb52108373d052ce Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2023-10-26hsa: unify echo test setupFilip Tehlar10-544/+1026
Type: test Change-Id: I8665492c2f7755901a428aacdb27e98329ff557a Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2023-09-13hsa: fix coverity issue CID-313635Dave Wallace2-2/+8
Type: fix Change-Id: Ieb50ab548bb34bdbb44d973037ee452d48f412ea Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2023-09-04session: fix allocation of proxy fifosFlorin Coras1-20/+40
Fifos need to be synchronously allocated once a transport like tcp accepts a session. Since events are now delivered asynchronously, proxy apps must explicitly register a cb function that manages fifo allocation prior to being notified of connect event. Type: fix Fixes: 0242d30 Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I7df973b7014e53e0766ea2bdc61e9871160bc18b
2023-08-09session: async rx event notificationsFlorin Coras2-4/+4
Move from synchronous flushing of io and ctrl events from transports to applications to an async model via a new session_input input node that runs in interrupt mode. Events are coalesced per application worker. On the one hand, this helps by minimizing message queue locking churn. And on the other, it opens the possibility for further optimizations of event message generation, obviates need for rx rescheduling rpcs and is a first step towards a fully async data/io rx path. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id6bebcb65fc9feef8aa02ddf1af6d9ba6f6745ce
2023-07-27hsa: add total bytes parameter to vcl_test_clientFilip Tehlar1-1/+17
Type: test Change-Id: Ib1131eedb8eeaa9adfed9cfc47beeb1c7c8adb5c Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2023-07-13hsa: fix echo client initFlorin Coras1-1/+2
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ieb2d1e6e0949844a70c81b218ca7dc83690776ca
2023-05-20hsa: add an option to configure ns in http cliFilip Tehlar1-1/+16
Type: feature Signed-off-by: Filip Tehlar <ftehlar@cisco.com> Change-Id: Ia81f1d8e706dbce9e57319d993bff595e6ba6f03
2023-05-19hsa: make http cli client thread safeFilip Tehlar1-6/+29
Type: fix Signed-off-by: Filip Tehlar <ftehlar@cisco.com> Change-Id: I9e6fd29c0e09406e48215f06977b2d4678650669
2023-05-16hsa: detach app on unsuccessful listenFilip Tehlar1-0/+12
Type: fix Signed-off-by: Filip Tehlar <ftehlar@cisco.com> Change-Id: Idba74f880a251dbeec2205ee41e16b40d4799b06
2022-12-23hsa: fix echo client workers initializationBenoît Ganne1-5/+4
We were creating an additional worker not backed by any VPP threads, leading off-by-1 access in the session main workers vector. Also uses vec_elt_at_index() when accessing session main workers vector elements to catch those errors more easily. Type: fix Change-Id: I6059116b7b64ae6b26ad83c1fcf55df8522868ad Signed-off-by: Benoît Ganne <bganne@cisco.com>
2022-12-02session: move connects to first workerFlorin Coras1-6/+2
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I035e3fdbb52eca010ad7b2c20ca2930cb1645978
2022-11-30hsa: session rpc for echo client cli notificationsFlorin Coras1-7/+12
Also, use connected udp for builtin echo apps Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ie24d7e97f4f27b67df9ceff3c268954485255c2d
2022-11-10http: support client connectFilip Tehlar3-0/+531
Type: feature Signed-off-by: Filip Tehlar <ftehlar@cisco.com> Change-Id: I0738c0aefb41ab6c0ff717cfccd1df75ddb481fa
2022-11-05hsa: echo client crash when it fails to connect to remoteSteven Luong1-1/+1
When echo client fails to connect to remote, it should quit. Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: I787423bdc61a58eea48bab7bd8b73137626c02b4
2022-11-03misc: fix failing TestNs/TestHttpTps test in hstfMaros Ondrejicka1-1/+6
Type: fix Signed-off-by: Maros Ondrejicka <maros.ondrejicka@pantheon.tech> Change-Id: I03cbd05d6d887d2ce8e7b7d20522e04012c5fe7a
2022-09-29api: deprecate vl_msg_api_set_handlersDamjan Marion1-5/+12
Type: refactor Change-Id: I7b7ca9ec62cb70243c5b7e87968eab1338d67ec8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-09-26api: replace print functions wth formatDamjan Marion1-7/+5
Type: improvement Change-Id: I7f7050c19453a69a7fb6c5e62f8f57db847d9144 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-06-29hsa: reduce number of preallocated vcl test server sessionsFlorin Coras2-1/+2
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I7afc6116ca9a609992f26d9e78084732bba1b2ea
2022-06-10hsa: allow first segments larger than 4g for proxyFlorin Coras2-14/+5
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I9c502a491ff56806a2e631f7a4c18903a2e93ab2
2022-06-03hsa: dealloc proxy fifos on right threadFlorin Coras2-1/+46
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ia66c12e1da126d0d8d101b645e6dc8454c3826d6
2022-06-03hsa: refactor proxy session lookup and cleanupFlorin Coras2-103/+52
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Ic68627bbca676cc78b0be05bc1fa0f386f5d27fa
2022-04-21hsa: vcl test client epoll worker loopFlorin Coras3-15/+301
Supports more connections and track connect time. Can be used to measure CPS. Only works in unidirectional mode for now. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I70bc6a271996407dd16a96115f509bd680a0f302
2022-04-16hsa: vcl test client allow non-blocking connectsFlorin Coras3-45/+66
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: If7dd56e76efc31ed66b865e2c7231d22ec2322b4
2022-04-15hsa: support configurable vcl client wrk loopFlorin Coras1-69/+128
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I5e49f43b18ff011ce0b7259ed58854d81f910826
2022-04-12hsa: fix coverity warningFlorin Coras1-0/+1
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I9cf21ee7ad363dd1af5ca75f07bfe38d8fe749f9
2022-04-12hsa: vcl test client option to close only clientFlorin Coras2-2/+12
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I45c63e0a7d7179a0f27ca3f093bd3cf7458a12d3
2022-04-04vppinfra: make _vec_len() read-onlyDamjan Marion2-3/+3
Use of _vec_len() to set vector length breaks address sanitizer. Users should use vec_set_len(), vec_inc_len(), vec_dec_len () instead. Type: improvement Change-Id: I441ae948771eb21c23a61f3ff9163bdad74a2cb8 Signed-off-by: Damjan Marion <damarion@cisco.com>
2022-03-29hsa: refactor echo clientsFlorin Coras2-318/+319
Type: refactor Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I30cc31c438d357d48576fba84e54809455960eaa
2022-03-25hsa: echo client connects as rpcFlorin Coras2-31/+36
Do connects in an session layer rpc instead of doing cli process sleeps. Performance with 4 workers goes from ~120k/180k first run/warmed up to ~135k/240k Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id184913e9898f8db099e29a605f3a9b1fc67be63
2022-03-23vppinfra: change vlib_register_node so it takes format string for node nameDamjan Marion1-5/+1
This allows specifying both c string and vector for node name and removes need for crafting temporary string. Type: improvement Change-Id: I0b016cd70aeda0f68eb6f9171c5152f303be7369 Signed-off-by: Damjan Marion <damarion@cisco.com>