Hi Sebastien,
On Tue, Oct 6, 2009 at 6:29 PM, Survivant 00 <survivant00_at_gmail.com> wrote:
> I suggest that we try that after my commit.. like that we will be able to
> play with and find out what we want to refactor in all that.
>
>
+1
> maybe when we will have a roadmap :)
>
>
> 2009/10/6 Hubert Iwaniuk <neotyk_at_kungfoo.pl>
>
>> Hi,
>> It seems to me that if we would use some callback mechanism in deployer
>> api around convert method we would provide more general extension mechanism.
>>
>> Hth,
>> Hubert.
>>
>> -original message-
>> Subject: Re: Discussion about Annotations support in GWSD
>> From: Survivant 00 <survivant00_at_gmail.com>
>> Date: 06-10-2009 15:26
>>
>> ah ok.
>>
>> if your war have Servlet+WebService.. no trouble.. just have to pass a
>> Parser that will handle both annotation, the web.xml will be handle
>> correctly.
>>
>> the problem right now it's just that we don't support all.. Maybe when we
>> will start the next project (web container) we will add the JEE6
>> Annotations
>> :)
>>
>> and yes we could add NotificationHandler..
>>
>> Hubert.. what do you think ?
>>
>>
>> 2009/10/6 Oleksiy Stashok <Oleksiy.Stashok_at_sun.com>
>>
>> > I understand your point, but single war file may have servlet3.0 *and*
>> > webservices inside.
>> > In this situation we will need to deploy single war two times?
>> >
>> > IMO, we can make WarDeployer as some core deployer, where we can
>> register
>> > different containers. Once application (war) gets deployed - we notify
>> each
>> > (?) container about deployed application (war) and let containers
>> process
>> > its configuration + annotations.
>> > Anyway this is very close to what you propose, but just my additional 2
>> > cents :)
>> >
>> > Thank you.
>> >
>> > WBR,
>> > Alexey.
>> >
>> >
>> >
>> >
>> > I never look it that way. I always tought about the Annotation parser
>> for
>> > Deployer, now that we have a WarDeployer, it could change things..
>> >
>> > let me think.
>> >
>> >
>> > Suppose that we want to use the WarDeployer in another application
>> > (embedded.. ), and this applications want to deploy a WebService and one
>> > Servlet (we will forget about EJB now, we don't support ear yet).
>> >
>> > suppose something like (don't know the syntax.. not important)
>> >
>> > new WarDeployer.deploy("/webservice");
>> > new WarDeployer.deploy("/servlet3.0");
>> >
>> > ok..
>> >
>> > we only support servlet 2.5 annotations so it won't be able to find
>> > annotation unless he user provide a Parser that support theses
>> Annotations.
>> >
>> > What I wanted to do if something like
>> >
>> > new WarDeployer.deploy("/webservice", new CustomAnnotationParser());
>> > new WarDeployer.deploy("/servlet3.0", new CustomAnnotationParser2());
>> >
>> > or use the same.. but it will have to be Custom until we add a Parser
>> that
>> > support more Annotations.
>> >
>> > and if the user user GWSD, it will use the default Parser.. no only
>> servlet
>> > 2.5
>> >
>> > Now if it use by another container that already have Annotation support
>> > like Tomcat, GF, Jetty... They already have there WebLoader, and parse
>> the
>> > annotation they support,, I don't see why they would like to use
>> > WarDeployer.
>> >
>> >
>> >
>> >
>> > 2009/10/6 Oleksiy Stashok <Oleksiy.Stashok_at_sun.com>
>> >
>> >> Hmm, please correct if I'm wrong...
>> >> we talk about situation, when WarDeployer could be used by Webservices,
>> >> EJB and other containers?
>> >> If we have 3 containers, let's say Webservices, EJB, Servlet 3.0 we can
>> >> let them share single WarDeployer instance, right? In this case which
>> custom
>> >> annotation parser we need to pass, theoretically we should pass 3
>> parsers,
>> >> one per container?
>> >>
>> >>
>> >> On Oct 6, 2009, at 12:35 , Survivant 00 wrote:
>> >>
>> >> it's not what I mean.
>> >>
>> >> Deployer is not able to detect Annotations others than Servlet 2.5,
>> >> because we didn't want to put ejb or webservice API dependancies in the
>> >> project (not now). So what I wanted to give is the option to load EJB
>> >> annotation at runtime with a customer AnnotationDetecter when the user
>> used
>> >> WarDeployer embedded.
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> 2009/10/6 Oleksiy Stashok <Oleksiy.Stashok_at_sun.com>
>> >>
>> >>> I almost finish the refactoring to enabled annotation into
>> WarDeployer.
>> >>>
>> >>> for testing purpose I add a AnnotationParser there.
>> >>>
>> >>> // if metadata-complete skip annotations
>> >>> if(!webApp.getMetadataComplete()){
>> >>> logger.fine("Will append Annotations to the
>> WebApp");
>> >>> try {
>> >>> AnnotationParser parser = new
>> AnnotationParser();
>> >>> WebApp webAppAnot =
>> >>> parser.parseAnnotation((URLClassLoader)warCL);
>> >>> webApp.mergeWithAnnotations(webAppAnot);
>> >>>
>> >>> } catch (Throwable t) {
>> >>> logger.warning("Unable to load annotations : "
>> +
>> >>> t.getMessage());
>> >>> }
>> >>> } else {
>> >>> logger.info("Skipping Annotation for this URI : "
>> +
>> >>> uri);
>> >>> }
>> >>>
>> >>> but I think it would be best to have one AnnotationParser that can be
>> >>> passed to the WarDeployer, and one by default. We could pass a Parser
>> that
>> >>> support other Annotation wihtou to much trouble.. like Persistance..
>> >>> WebService, Serlvet 3.0 api ...
>> >>>
>> >>> what do you think ?
>> >>>
>> >>>
>> >>> Not sure if there is a sense to pass custom parsers. Theoretically our
>> >>> classes are open, so WebServices, Servlet 3.0 container(s) can parse
>> our
>> >>> classes themselves. What deployer might do - is notify other
>> containers
>> >>> about newly deployed application.
>> >>> Do I miss something?
>> >>>
>> >>>
>> >>>
>> >>
>> >>
>> >> --
>> >>
>> >> Vous pouvez me suivre sur Twitter / You can follow me on Twitter :
>> >> http://twitter.com/survivant
>> >>
>> >>
>> >>
>> >
>> >
>> > --
>> >
>> > Vous pouvez me suivre sur Twitter / You can follow me on Twitter :
>> > http://twitter.com/survivant
>> >
>> >
>> >
>>
>>
>> --
>>
>> Vous pouvez me suivre sur Twitter / You can follow me on Twitter :
>> http://twitter.com/survivant
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe_at_grizzly.dev.java.net
>> For additional commands, e-mail: dev-help_at_grizzly.dev.java.net
>>
>>
>
>
> --
>
> Vous pouvez me suivre sur Twitter / You can follow me on Twitter :
> http://twitter.com/survivant
>