1

Is it possible to make only one dynamic table for event source in prooph CQRS + ES, instead of creating a new table for each ID?

I am using this tutorial https://pilsniak.com/cqrs-es-php-prooph/

Dhiraj
  • 106
  • 6

1 Answers1

2

You have to use a SingleStreamStrategy instead of the AggregateStreamStrategy used in the tutorial.

Read more about Persistance Strategies in the docs.

  • Thanks Alexander. The example link https://github.com/prooph/proophessor-do/blob/master/scripts/create_event_stream.php not working. Could you provide me an example? – Dhiraj Jul 14 '18 at 00:56
  • https://github.com/prooph/proophessor-do/blob/master/scripts/create_event_streams.php Just use "event_stream" (or whatever you prefer as name) and use that name in the repository configuration: https://github.com/prooph/proophessor-do/blob/master/config/autoload/prooph.global.php#L47 – Alexander Miertsch Jul 14 '18 at 10:19
  • Thanks a lot, Alexandar. – Dhiraj Jul 14 '18 at 13:25