MINOR: applet: No longer set EOI on the SC
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 21 Mar 2023 10:52:16 +0000 (11:52 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 5 Apr 2023 06:57:05 +0000 (08:57 +0200)
Thanks to the previous patch, it is now possible for applets to not set the
CF_EOI flag on the channels. On this point, the applets get closer to the
muxes.

addons/promex/service-prometheus.c
src/cache.c
src/hlua.c
src/http_client.c
src/stats.c

index e4cc469..bc88a7b 100644 (file)
@@ -1591,7 +1591,6 @@ static void promex_appctx_handle_io(struct appctx *appctx)
                                channel_add_input(res, 1);
                        }
                        res_htx->flags |= HTX_FL_EOM;
-                       res->flags |= CF_EOI;
                        se_fl_set(appctx->sedesc, SE_FL_EOI);
                        appctx->st0 = PROMEX_ST_END;
                        __fallthrough;
index ae57ce5..36ecf18 100644 (file)
@@ -1526,7 +1526,6 @@ static void http_cache_io_handler(struct appctx *appctx)
        if (appctx->st0 == HTX_CACHE_EOM) {
                 /* no more data are expected. */
                res_htx->flags |= HTX_FL_EOM;
-               res->flags |= CF_EOI;
                se_fl_set(appctx->sedesc, SE_FL_EOI);
                appctx->st0 = HTX_CACHE_END;
        }
index cc8624c..8cafff8 100644 (file)
@@ -9713,7 +9713,6 @@ void hlua_applet_http_fct(struct appctx *ctx)
                }
 
                res_htx->flags |= HTX_FL_EOM;
-               res->flags |= CF_EOI;
                se_fl_set(ctx->sedesc, SE_FL_EOI);
                strm->txn->status = http_ctx->status;
                http_ctx->flags |= APPLET_RSP_SENT;
index c146bd2..40d5ab6 100644 (file)
@@ -787,7 +787,6 @@ static void httpclient_applet_io_handler(struct appctx *appctx)
 
                                        /* if the request contains the HTX_FL_EOM, we finished the request part. */
                                        if (htx->flags & HTX_FL_EOM) {
-                                               req->flags |= CF_EOI;
                                                se_fl_set(appctx->sedesc, SE_FL_EOI);
                                                appctx->st0 = HTTPCLIENT_S_RES_STLINE;
                                        }
index 3e1b90b..2bc471c 100644 (file)
@@ -4500,7 +4500,6 @@ static void http_stats_io_handler(struct appctx *appctx)
                        channel_add_input(res, 1);
                }
                res_htx->flags |= HTX_FL_EOM;
-               res->flags |= CF_EOI;
                se_fl_set(appctx->sedesc, SE_FL_EOI);
                appctx->st0 = STAT_HTTP_END;
        }