Skip to content

WASM cache initialization failure causes all routes with EEP to fail #6159

@guydc

Description

@guydc

Description:

see here #6124 (comment) :

The "Translator" calls buildWasms twice, once in translateEnvoyExtensionPolicyForRoute and once in translateEnvoyExtensionPolicyForGateway both treat a nil as an error

Seems like buildWasms will default all routes with an EEP, regardless of if the EEP even has wasms:

It's always called when processing EEPs:

if wasms, err = t.buildWasms(policy, resources); err != nil {

It returns an error before checking if wasm cache is really needed:

return nil, fmt.Errorf("wasm cache is not initialized")

In other words, if wasm cache fails to start - all routes with EEPs are zeroed-out.

cc @zhaohuabing

Repro steps:

Environment:

Include the environment like gateway version, envoy version and so on.

Logs:

Include the access logs and the Envoy logs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions