[jbosstools-dev] Re: Seam Project Wizard

Snjezana Peco snjezana.peco at redhat.com
Wed Jan 21 14:57:58 EST 2009


Alexey Kazakov wrote:
> Snjezana Peco wrote:
>> I have noticed that the New Seam wizard is being executed in the 
>> following order:
>>
>> - Seam Install delegate creates  Seam facet, WAR project ...
>> - Seam Post Install delegate registers (and publishes) the project on 
>> the server and registers a database profile
>> - SeamProjectCreator.execute() configures a test project (EJB and EAR 
>> projects for EAR deployment)
>>
>> It could happen that the project is registered (and published) before 
>> it is configured completely.
> Hm... yes it could :(
> Is there particular issue already in JIRA?
>

I haven't seen any.

>>
>> My proposal is the following:
>> - moving SeamProjectCreator.execute() to Seam Install delegate
> SeamProjectCreator is used be New Seam Wizard Project.
> If user just add Seam facet to existed project then we must not to use 
> SeamProjectCreator.
> We can check the wizard that installs Seam facet but I'm not sure this 
> is the best solution...
>

We could set some property when installing facet using New Seam Wizard 
Project and call SeamProjectCreator.execute() only if this property is 
set. If we execute SeamProjectCreator.execute() within Seam Install 
delegate, we will execute a complete configuration within the same 
workspace job.

>> - registering and publishing a project should be done in a job within 
>> Seam Post Install delegate or within Seam Install delegate . This job 
>> would wait for the project to be built. After that, it would register 
>> the project on the server.
>>
> Sounds better for me. Is there any chance that registering will be 
> before eclipse starts building project created by SeamProjectCreator?
>

Yes, there is. We could create a separate build job that would register 
the server, build the project, wait for the project to be built, publish 
the project.
I have to check if it is possible to separate registering and 
publishing. If that is impossible, a better solution would be 
register/publish the project after building the project.
Publishing before building will cause errors on the server when all the 
classes/resources aren't created.




More information about the jbosstools-dev mailing list