[forge-dev] Firing ResourceEvents before CommandExecuted event?
Lincoln Baxter, III
lincolnbaxter at gmail.com
Tue Jun 19 17:08:34 EDT 2012
That line is to ensure proper ClassLoading while running in a modular
Before I answer this, it might be better to ask why you want to fire
ResourceEvents before CommandExecuted event. I think I agree with the
change to fire CommandExecuted after, but I just want to know to be sure.
I think that introducing a second event might be useful if what you are
trying to do is capture all changed resources:
EnteredWaitState to notify when the shell is again waiting for user input.
There may be an event like this already. Also, is it possible to do what
you need without the resource events entirely? Just a thought. Doesn't GIT
already tell you which files have changed somehow?
On Tue, Jun 19, 2012 at 3:48 PM, Jevgeni Zelenkov <
jevgeni.zelenkov at googlemail.com> wrote:
> Hi guys,
> I am having an issue with Events in Forge. I would like to get a list
> of Resources modified by a forge command, after a forge command has
> been executed.
> Fortunately, forge fires events when command execution completes
> (either successfully, or unsuccessfully) and when resources are
> created/modified/deteled/etc. Sadly, it fires CommandExecuted event
> before any of ResourceEvents. (EventBusInvoker listens to
> CommandExecuted event and fires all ResourceEvents queued in the
> I expect ResourceEvents to be fired before the CommandExecuted event
> (which would correspond to what actually happends). I tried commenting
> out code inside of EventBusInvoker's fire method and adding
> "bus.fireAll();" into Execution class (right before firing
> CommandExecuted event) but that doesn't seem to work.
> How could I fire ResourceEvents before CommandExecuted event? Or is
> there another way to get a list of modified resources during forge
> command exection?
> What does this line do? Is forge multi-threaded?
> forge-dev mailing list
> forge-dev at lists.jboss.org
Lincoln Baxter, III
"Simpler is better."
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the forge-dev