Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Dec 05 17:43
    unixslayer review_requested #62
  • Dec 05 17:41
    unixslayer synchronize #62
  • Dec 04 20:53

    dgafka on main

    open 1.60-dev (compare)

  • Dec 04 20:53

    dgafka on 1.59.0

    (compare)

  • Dec 04 20:53

    dgafka on main

    prepare release (compare)

  • Dec 04 20:52

    github-actions[bot] on main

    Fixes styling (compare)

  • Dec 04 20:51

    dgafka on main

    Flow Testing (#63) * Add Flow… (compare)

  • Dec 04 20:51
    dgafka closed #63
  • Dec 04 20:44
    dgafka synchronize #63
  • Dec 04 20:44

    dgafka on testing

    phpstan (compare)

  • Dec 04 20:42
    dgafka opened #63
  • Dec 04 20:42

    dgafka on testing

    Add Flow testing Make use of flow testing in tes… (compare)

  • Dec 03 09:51
    dgafka synchronize #62
  • Dec 03 02:44
    wtfzdotnet starred ecotoneframework/ecotone-dev
  • Dec 02 20:43

    dgafka on main

    fix composer.sjon (compare)

  • Dec 02 14:20
    unixslayer opened #62
  • Dec 02 07:25

    dgafka on main

    update readme (compare)

  • Dec 02 07:23

    dgafka on main

    Update Readme (compare)

  • Dec 01 16:50

    dgafka on main

    open 1.59-dev (compare)

  • Dec 01 16:50

    dgafka on 1.58.0

    (compare)

AndreasHeissenberger
@AHeissenberger_twitter
How about a project QueryHandler which is a generator yielding the existing value and all new values on a projection update?
AndreasHeissenberger
@AHeissenberger_twitter
@dgafka the more general question is - how can I run multiple consumers in their own php processes which react to the same event message?
AndreasHeissenberger
@AHeissenberger_twitter
@dgafka Event Sourcing / how can I handle Exception "Error 23000.Error-Info: Duplicate entry" in the aggregate class and create an ErrorEvent for this case. This happens when a new Aggreagate with an existing id is created.
6 replies
Dariusz Gafka
@dgafka

From version 1.27.0 - Ecotone brings possibility to emit events directly from projections.
This will help with Eventual Consistency problems, as end users will be able to subscribe to projection changes :)

https://twitter.com/EcotonePHP/status/1538596340040704000

@AHeissenberger_twitter besides the official demo at the end of documentation page, I've create one for you: https://github.com/dgafka/ecotone-emitting-events :)

As you were asking about Event Subscription, you may achieve it fetching the stream directly.
In here, you can find the example how to make use of EventStore Gateway to get fresh events from events that were published by the Projection:
https://github.com/dgafka/ecotone-emitting-events/blob/main/src/ReadModel/NotificationService.php#L17

Piotr Zając
@unixslayer
@dgafka I have a scenario where my entity lives in more than one contexts. This makes my application to have different aggregate classes for the same entity, both event sourced. Due to events are saved with aggregateType based on class name of an aggregate, I've opened PR introducing an attribute and a mapper which allow to set custom aggregate type the same way as custom stream name. ecotoneframework/event-sourcing#5
3 replies
Dariusz Gafka
@dgafka

New feature, projections with state. (Not yet documented) :)

https://github.com/ecotoneframework/quickstart-examples/tree/master/StatefulProjection

In order calculate result without the need for any extra storage and to pass it between Event Handlers.

2 replies
Dariusz Gafka
@dgafka
angun33
@angun33
Hi @dgafka, I have a question, how do you handle event sourced child entity that's under an aggregate root? For example an aggregate root Part has a Manufacturer entity where the Manufacturer entity that has it's own events, eg 'PartManufacturerWasRenamedEvent'
6 replies
Piotr Zając
@unixslayer
@dgafka I found a bug regarding DBAL dependency. getWrappedConnection() method was not returning expected value. However it was deprecated in all supported versions. Suggested getNativeConnection() method is already returning \PDO instance ecotoneframework/event-sourcing#6
Dariusz Gafka
@dgafka
I would love to hear your feedback guys, what would help you in contributing to Ecotone :) https://github.com/ecotoneframework/ecotone/discussions/24
Sergey
@dostrog

Hi!

When I connect consumer directly to a AMQP Queue (RabbitMQ) is it possible to get some information from message, not only payload ?
For example, routing key ?

class Consumer
{
    #[MessageConsumer("consumer")]
    public function execute(string $message) : void
    {
        // do something with Message
        // if you have converter registered you can type hint exact type you expect

        // $message is eq payload in RAW
        // is RabbitMQ's routing key accessible ? 

    }
}
11 replies
Santi_98
@Santiago__1998_twitter
Hello!
Exists a way to separate completely aggregates/entities/handlers from PHP Attributes?
I really want to separate my domain from infrastructure calls trying to implant hexagonal, and I know that Doctrine offers alternatives to attributes and annotations, using XML or yaml definitions. I really appreciate if exists, or will exists in the future.
Thanks.
1 reply
Dariusz Gafka
@dgafka

From today, you may start using Ecotone Pulse. Solution to manage full life cycle of your error messages.

  • Provide way to control error messages for all your services from one place.
  • Allows for listing and debugging error messages
  • Adds possibility to replay and delete error messages.

https://twitter.com/EcotonePHP/status/1574058456381792256

Jakub Tobiasz
@jakubtobiasz
Hi everyone!
Ecotone seems to be a cool tool 😎! I'm going to rewrite my engineer's thesis project to use Ecotone and check it in a battle 👍🏼
Dariusz Gafka
@dgafka
Hey Jakub,
Amazing! Have fun and get back with feedback :)
Dariusz Gafka
@dgafka
New article in relation to Ecotone "Loosely coupled Microservices in PHP": https://dariuszgafka.medium.com/loosely-coupled-microservices-in-php-130699e80344
AndreasHeissenberger
@AHeissenberger_twitter
Hi Dariusz, is there any event sourcing example app (lite) which implements tests for agregates and other parts of the system?
Dariusz Gafka
@dgafka

Hey Andreas,

Currently there is no demo for testing. I will prepare examples and let you know :)

AndreasHeissenberger
@AHeissenberger_twitter
Thank You :-)
2 replies
AndreasHeissenberger
@AHeissenberger_twitter
Is there any support for RabbitMQ Topics
2 replies
AndreasHeissenberger
@AHeissenberger_twitter
What would be a minimal setup with Lite if I only need to send Commands / Messages to the distributed bus from an existing php application?
16 replies
Alessandro Frangioni
@alle
Hi, it seems that blog.ecotone.tech is not reachable.
2 replies
AndreasHeissenberger
@AHeissenberger_twitter
Why is the state of a table projects allways an empty array []
'course','{"App\\\\Domain\\\\Course\\\\Course":3}','[]','idle',NULL
3 replies
AndreasHeissenberger
@AHeissenberger_twitter
Is the package lite-application still a good base? It is not mention in the current documentation for Lite
1 reply
AndreasHeissenberger
@AHeissenberger_twitter
Do I need to define a type for any basic array? Uncaught JMS\Serializer\Exception\RuntimeException: You must define a type for App\Domain\Booking\Event\EventWasCreated::$defaultValues.
class EventWasCreated
{
    public function __construct(
        public readonly int $eventId,
        public readonly int $courseId,
        public readonly array $defaultValues,
    ) {
    }
}
15 replies
AndreasHeissenberger
@AHeissenberger_twitter
Any idea why php 8.1 / enums are not supported by JMS?
Serialization works but deserialization fails Fatal error: Uncaught Doctrine\Instantiator\Exception\InvalidArgumentException: The provided class "App\ValueObjects\PublishState" is an enum, and cannot be instantiated in /vendor/doctrine/instantiator/src/Doctrine/Instantiator/Exception/InvalidArgumentException.php:45
3 replies
AndreasHeissenberger
@AHeissenberger_twitter
How can I check in a command handler if an event sourcing aggregate with a specific ID exists?
1 reply
AndreasHeissenberger
@AHeissenberger_twitter
add Docs - the Search does not index the code samples - e.g. a Search for "AggregateIdentifier" has no result
3 replies
AndreasHeissenberger
@AHeissenberger_twitter
Can Ecotone handle Aggregates with multiple Entity similar to the Axon framework?
https://www.baeldung.com/java-axon-multi-entity-aggregates
9 replies
AndreasHeissenberger
@AHeissenberger_twitter
How should I translate the following requirements in aggregates:
  1. I have entity "Course" with default values for e.g. maxParticipants.
  2. A "Course" can have many "Events" which inherit the maxParticipants from "Course"
  3. The maxParticipant can be overwritten by an event specific value
  4. when a reservationCommand for an event is placed and the value for maxParticipant have not been overwritten I need to use the value for maxParticipants from Courses
    I would like to avoid to place all entities into one big aggregate but the other options are with two aggregate roots:
    A) with query
  5. querying the maxParticipant value from course aggregate
  6. do the business rule which verifies the EventPlaceReservationCommand.
  7. create 2 events as result: EventMaxParticipantUpdated, EventReservationPlaced
    B) saga
    an other option would be to create a saga which keeps a list of open events, reacts to all CourseUpdated events, issuing a EventUpdateMaxParticipant Command for all events related to the course
4 replies
AndreasHeissenberger
@AHeissenberger_twitter
How do I handle versioning of events when I e.g. add a new field to an event?
18 replies
AndreasHeissenberger
@AHeissenberger_twitter
@dgafka after upgrading my application could not find the command handlers until I added pathToRootCatalog: __DIR__ to EcotoneLiteApplication::boostrap(pathToRootCatalog: __DIR__) - on older versions this was not needed.
7 replies
Piotr Filipek
@piotrfilipek
Hi! I'm new here and before I ask I want to say hello! :)
Okay, I've stupid question. I'm working on something, suppose that's a store, and I've a Product entity, but what should I do when my entity is going to be too heavy? Should I create a ProductWithPhotos or do something else? It's not necessary to fetching a huge entity when I want to show only a few informations.
4 replies
Dariusz Gafka
@dgafka

Hey,
I am building test support for Ecotone.

Right now, I've support for:

  • Isolating message flows (you may target given set of class to run tests for)
  • Switching from asynchronous to synchronous message handlers only for test scenario
  • Possibility to spy messages (which events were sent to command/query/event bus)
  • enabling in memory repositories (in progress)

Can you tell me what would helpful for you when writing tests?

5 replies
Oitmain, Inc
@Oitmain_twitter
Is there a way to optimize Ecotone? It's too slow for us to use it in production
image.png
Just initializing it takes over 160 ms
90% of our app running time is used for initializing Ecotone
Oitmain, Inc
@Oitmain_twitter
I just answered my own question - $cachedVersion should be true
6 replies
Oitmain, Inc
@Oitmain_twitter
How do we use 'QuickLogger'?
6 replies
Oitmain, Inc
@Oitmain_twitter
image.png
3 replies
Oitmain, Inc
@Oitmain_twitter
Is Ecotone production ready? We are thinking about using it in our project
2 replies
Oitmain, Inc
@Oitmain_twitter
Is running running same async channel simultaneously mutually exclusive?
Example: Run two scripts for 1 hour at the same time. $this->messagingSystem->run("orders")
Is there a change one message will be processed twice?
2 replies
Oitmain, Inc
@Oitmain_twitter
image.png
Oitmain, Inc
@Oitmain_twitter
Is there a feature to delete an aggregate created in the database?
2 replies
Julian Engleheart
@JulianEngleheart

Hello Dariusz, I'm trying to follow the tutorial, but having problems installing ecotone/jms-converter. I'm working from the composer.json provided and am running PHP 8.1.12.
Your requirements could not be resolved to an installable set of packages.

Problem 1

- ecotone/jms-converter[dev-main, v1.x-dev] require symfony/cache ^5.4|^6.1 -> found symfony/cache[v5.4.0-BETA1, ..., 5.4.x-dev, v6.1.0-BETA1, ..., 6.2.x-dev] but the package is fixed to v5.0.11 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
- ecotone/jms-converter 1.53.0 requires ecotone/ecotone 1.53 -> found ecotone/ecotone[1.53.0] but the package is fixed to 1.32.2 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
- ecotone/jms-converter 1.54.x-dev is an alias of ecotone/jms-converter dev-main and thus requires it to be installed too.
- Root composer.json requires ecotone/jms-converter ^1.53 -> satisfiable by ecotone/jms-converter[1.53.0, 1.54.x-dev (alias of dev-main), v1.x-dev].
5 replies
Dariusz Gafka
@dgafka

Hey guys,
I was told few times that gitter does not send notifications or there are problems with opening threads, so I decided to move community channel to different medium. I was looking for options for quite some time and I think I found the best one :)

Community channel is moving to #ddd-cqrs-es discord channel. This is a channel where there is a lot of people involved into CQRS, DDD and Event Sourcing. They will be hosting channel for Ecotone Framework :)

Gitter will no be used from now on :)
So please move here: https://discord.com/channels/514783899440775168/1046488555830120649

Dariusz Gafka
@dgafka
If above invitation does not work for you, use this link instead: https://discord.gg/CctGMcrYnV