Skip to content

Allow TableNameResolver to be asynchronous #289

Open
@nolde

Description

@nolde

I have separate systems that create and manage hard resources like dynamodb tables, and that use those resources. Normally, I export those variables using different methods, but I wanted to start making my system more robust in the event of changes, including hot switching of tables. To to that, I would have to be able to resolve the name of the table in runtime.

To achieve that, I am exporting SSM parameters with the required names, but I cannot resolve it in runtime, as TableNameResolver does not support an asynchronous function to be set. As aws-sdk is mostly asynchrounous, it makes it quite hard to determine names by accessing external resources. It is achievable, but depends on complex synchronisation code that becomes an overkill.

Therefore, it would be nice if TableNameResolver could support Promise<string> as return value as well, allowing a large range of resolutions to happen.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions