Skip to content

Commit

Permalink
Merge pull request #188 from patchlevel/store-options
Browse files Browse the repository at this point in the history
add store options
  • Loading branch information
DavidBadura authored Apr 20, 2024
2 parents 9dbb79f + 7929a38 commit 7c3fcef
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 9 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
],
"require": {
"php": "~8.1.0 || ~8.2.0 || ~8.3.0",
"patchlevel/event-sourcing": "3.0.0-rc13",
"patchlevel/event-sourcing": "3.0.0-rc14",
"symfony/cache": "^6.4.0|^7.0.0",
"symfony/config": "^6.4.0|^7.0.0",
"symfony/console": "^6.4.1|^7.0.1",
Expand Down
14 changes: 7 additions & 7 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ public function getConfigTreeBuilder(): TreeBuilder
->addDefaultsIfNotSet()
->children()
->booleanNode('merge_orm_schema')->defaultFalse()->end()
->arrayNode('options')->variablePrototype()->end()->end()
->end()
->end()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ private function configureStore(array $config, ContainerBuilder $container): voi
new Reference('event_sourcing.dbal_connection'),
new Reference(EventSerializer::class),
new Reference(HeadersSerializer::class),
$config['store']['options']['table_name'] ?? 'eventstore',
$config['store']['options'],
])
->addTag('event_sourcing.doctrine_schema_configurator');

Expand Down
3 changes: 3 additions & 0 deletions tests/Unit/PatchlevelEventSourcingBundleTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,9 @@ public function testFullBuild(): void
'service' => 'doctrine.dbal.eventstore_connection',
],
'store' => [
'options' => [
'table_name' => 'event_store',
],
],
'clock' => [
'service' => 'clock',
Expand Down

0 comments on commit 7c3fcef

Please sign in to comment.