Skip to content

[activation DB agent] add X-OW-EXTRA-LOGGING header #49

@alexkli

Description

@alexkli

Adapt for an upcoming (optional) feature in Openwhisk, which would break the activation DB polling agent (which is lower prio, since the concurrent one is preferred, and if that's not supported, ngrok works better).

The idea of that OW feature is to improve scalability of the activation record system by not storing the activation records in the database anymore for blocking & successful activations. This means that wsk activations list and wsk activation get <id> won’t return anything for these activations.

But it can be forced by setting a header when invoking the action:

X-OW-EXTRA-LOGGING: on

This would have to be set when invoking the helper functions <name>_wskdebug_invoked and <name>_wskdebug_completed .

It might be tricky to add a custom header in openwhisk().actions.invoke(). But looking at the code it might be possible using

actions.invoke()({
    name: "action",
    params: result,
    blocking: true,
    headers: {
        "X-OW-EXTRA-LOGGING": "on"
    }
});

This might just be a side effect, not necessarily a supported way. And this might "clear" the default authorization header, in which case one would have to construct & set it here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions