Skip to content

Introduce behaviours #91

Closed
Closed
@sagikazarmark

Description

@sagikazarmark
Q A
Bug? no
New Feature? yes

At the moment we support flexible client and methods client via options of the client definition with simple flags set to true. However this makes it harder to nest these client behaviors (even if it might not make too much sense at the moment). Instead of these flags, I propose the following:

httplug:
    client:
        acme:
            factory: 'acme_client_factory'
            behaviors:
                - flexible
                - something_else
                - batch

This would allow to nest multiple behavioral clients into each other. Of course we have to take care of type safety (behavioral clients might be sync or async clients (or both), but we need to check that before each nesting to see what the next behavior supports)

This would also ensure futureproof flexibility.

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