AltraMayor / AltraMayor/gatekeeper

struct flow_entry should have a single state: GK_BPF

未关闭
#602 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement
主要语言
C
星标
1.6k
派生
252
PR 合并指标
30 天内没有已合并 PR

描述

The states of a flow entry are `enum { GK_REQUEST, GK_GRANTED, GK_DECLINED, GK_BPF }`.

The states `GK_GRANTED` and `GK_DECLINED` have long been implemented as BPF programs, so their removal should not affect anyone. The downside of no longer having a way to compare the performance between built-in programs (i.e., the states `GK_GRANTED` and `GK_DECLINED`) and BPF programs is okay since that dropping the code associated with these deprecated states translates into a cleanup of the code of GK blocks.

Moving the state `GK_REQUEST` into a BPF program requires an extension of the running environment of the BPF programs. For example, the request BPF will need a way to update the expiration of flow entries and a mechanism to send packets to SOL blocks. A positive side effect of having a request BPF is to lower the effort to explore new strategies to prioritize undecided flows.

This streamline of `struct flow_entry` would be a preparation to integrate with [future SmartNICs that support running BPF programs](https://github.com/AltraMayor/gatekeeper/issues/599#issuecomment-1238302884).

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。