|
90 | 90 | use Patchlevel\EventSourcing\Snapshot\Adapter\Psr6SnapshotAdapter; |
91 | 91 | use Patchlevel\EventSourcing\Snapshot\DefaultSnapshotStore; |
92 | 92 | use Patchlevel\EventSourcing\Snapshot\SnapshotStore; |
93 | | -use Patchlevel\EventSourcing\Store\DoctrineDbalStore; |
94 | 93 | use Patchlevel\EventSourcing\Store\InMemoryStore; |
95 | | -use Patchlevel\EventSourcing\Store\ReadOnlyStore; |
96 | 94 | use Patchlevel\EventSourcing\Store\Store; |
97 | 95 | use Patchlevel\EventSourcing\Store\StreamDoctrineDbalStore; |
98 | 96 | use Patchlevel\EventSourcing\Store\StreamReadOnlyStore; |
|
128 | 126 | use Patchlevel\EventSourcingBundle\RequestListener\SubscriptionRebuildAfterFileChangeListener; |
129 | 127 | use Patchlevel\EventSourcingBundle\Subscription\ResetServicesListener; |
130 | 128 | use Patchlevel\EventSourcingBundle\Subscription\StaticInMemorySubscriptionStoreFactory; |
131 | | -use Patchlevel\EventSourcingBundle\ValueResolver\AggregateRootIdValueResolver; |
| 129 | +use Patchlevel\EventSourcingBundle\ValueResolver\IdentifierValueResolver; |
132 | 130 | use Patchlevel\Hydrator\Cryptography\Cipher\Cipher; |
133 | 131 | use Patchlevel\Hydrator\Cryptography\Cipher\CipherKeyFactory; |
134 | 132 | use Patchlevel\Hydrator\Cryptography\Cipher\OpensslCipher; |
@@ -709,29 +707,6 @@ private function configureStore(array $config, ContainerBuilder $container): voi |
709 | 707 | return; |
710 | 708 | } |
711 | 709 |
|
712 | | - if ($config['store']['type'] === 'dbal_aggregate') { |
713 | | - $container->register(DoctrineDbalStore::class) |
714 | | - ->setArguments([ |
715 | | - new Reference('event_sourcing.dbal_connection'), |
716 | | - new Reference(EventSerializer::class), |
717 | | - new Reference(HeadersSerializer::class), |
718 | | - $config['store']['options'], |
719 | | - ]) |
720 | | - ->addTag('event_sourcing.doctrine_schema_configurator'); |
721 | | - |
722 | | - $container->setAlias(Store::class, DoctrineDbalStore::class); |
723 | | - |
724 | | - if ($config['store']['read_only']) { |
725 | | - $container->register(ReadOnlyStore::class) |
726 | | - ->setDecoratedService(Store::class) |
727 | | - ->setArguments([ |
728 | | - new Reference('.inner'), |
729 | | - ]); |
730 | | - } |
731 | | - |
732 | | - return; |
733 | | - } |
734 | | - |
735 | 710 | if ($config['store']['type'] === 'dbal_stream') { |
736 | 711 | $container->register(StreamDoctrineDbalStore::class) |
737 | 712 | ->setArguments([ |
@@ -795,19 +770,6 @@ private function configureStoreMigration(array $config, ContainerBuilder $contai |
795 | 770 | return; |
796 | 771 | } |
797 | 772 |
|
798 | | - if ($config['store']['migrate_to_new_store']['type'] === 'dbal_aggregate') { |
799 | | - $container->register($id, DoctrineDbalStore::class) |
800 | | - ->setArguments([ |
801 | | - new Reference('event_sourcing.dbal_connection'), |
802 | | - new Reference(EventSerializer::class), |
803 | | - new Reference(HeadersSerializer::class), |
804 | | - $config['store']['migrate_to_new_store']['options'], |
805 | | - ]) |
806 | | - ->addTag('event_sourcing.doctrine_schema_configurator'); |
807 | | - |
808 | | - return; |
809 | | - } |
810 | | - |
811 | 773 | if ($config['store']['migrate_to_new_store']['type'] === 'dbal_stream') { |
812 | 774 | $container->register($id, StreamDoctrineDbalStore::class) |
813 | 775 | ->setArguments([ |
@@ -1175,7 +1137,7 @@ private function configureCryptography(array $config, ContainerBuilder $containe |
1175 | 1137 |
|
1176 | 1138 | private function configureValueResolver(ContainerBuilder $container): void |
1177 | 1139 | { |
1178 | | - $container->register(AggregateRootIdValueResolver::class) |
| 1140 | + $container->register(IdentifierValueResolver::class) |
1179 | 1141 | ->addTag('controller.argument_value_resolver', ['priority' => 200]); |
1180 | 1142 | } |
1181 | 1143 |
|
|
0 commit comments