Skip to content

Pass callback from host to runtime for getting properties from the host #77458

@elinor-fung

Description

@elinor-fung

The host passes information to the runtime via a string to string mapping of properties. Adding a property represents a non-trivial cost, but is currently the only way we have to pass more information from the host to the runtime.

We should add a different mechanism for this. We can pass over a callback (similar to what we currently do BUNDLE_PROBE and PINVOKE_OVERRIDE) for getting properties. Something like:

size_t STDMETHODCALLTYPE get_runtime_property(
    const char* key,
    void* value_buffer,
    size_t value_buffer_size)

The value_buffer actual type would depend on the key, such that we could have structured information.

This would enable us to provide the information necessary to support:

Runtimes need to continue to respect the existing properties, but once the callback exists, it could also be used for existing properties as appropriate. This would be a step towards:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions