Skip to content

[Plugin] Add configuration for VCR plugin #330

@GaryPEGEOT

Description

@GaryPEGEOT
Q A
Bug? no
New Feature? yes
Version master

Actual Behavior

No easy way to configure the VCR plugin

Expected Behavior

Same configuration pattern as the other plugins

Possible Solutions

Either a kind of "all-in-one" implementation:

// config.yml
httplug:
    clients:
        acme:
            # ...
            plugins:
                # ...
                - record_and_replay: # or vcr
                    mode: record # record | replay | replay_or_record
                    recorder: filesystem # optionnal
                    naming_strategy: service_id.of.naming_strategy # optionnal

Or a more explicit way, ie be defining a record plugin, and a replay plugin

// config.yml
httplug:
    clients:
        acme:
            # ...
            plugins:
                # ...
                - replay:
                    throw_on_missing: false # Default to true
                - record: ~
    plugins:
        record_and_replay: # or vcr
            recorder: filesystem # optionnal
            naming_strategy: service_id.of.naming_strategy # optionnal

Taking the risk that people put record before replay.

Any design preference @dbu?

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