Raised just before a
repository is forked. This event is synchronous, allowing listeners to
perform operations in the same database transaction where the forked repository will be created.
attached to the event is the fork to be created. Its
provides the repository that will be forked to create it. Note that forks can
be created in the same project as their origin or in different one, so the
for the fork and its origin may or may not be the same.
This event is
. A listener may prevent the repository from being forked by
this event. Throwing an exception will not
prevent the repository
from being forked; the exception will be logged and ignored.
Note: The repository attached to the event will not
, as it has not
been created yet, but it will
listener which would like to create associations based on the repository ID must listen for the
instead, which will include it (but will not run in the same transaction).