Skip to content

Move the code from Command execute to separate services #3748

Open
@LOBsTerr

Description

Issue title

We should use commands just to get input from users and pass it to the services which will handle the rest of the job for us

Problem/Motivation

It is the first thing recommended by the community of Symfony console to keep the Commands classes thin. It is kind of Controller in MVC pattern. Logic should be written in the separate services.
It will

  • reduce dependencies between the Command classes
  • reduce a responsibility of Command class
  • increase reusability of the common services and decrease code duplication as result

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions