Andreas,

Yes my RPC return types are concrete.

please see my project setup below

Proj-gwt (no dependencies)
  Src
    Com
      Acme
          AcmeModel.xml (gwt file saying to only use com/acme/client
as source for gwt, no entry point)
          Client
              AbstractFoo.java
              FooImpl1.java

Proj-Other1 (depends on proj-gwt)
  Src
    Com
      Acme
          Client
              FooImpl2.java  (non gwt compliant class, not meant to be
sent across RPC)

Proj-Other2 (depends on proj-gwt and proj-other1)
  Src
    Com
      Acme
          AcmeServer.xml (gwt.xml file saying to use com/acme/server
as source for gwt + proj-gwt as a module, contains entry point)
          Server
            MyService.java  (non gwt compliant class, not meant to be
sent across RPC)

Right now when I compile Proj-Other2, of course proj-gwt is also
rolled in, but the compiler tries to get FooImpl2 as well which just
an implementation of AbstractFoo. I never asked it to look for
anything in Proj-Other2.

-KD

Andreas Horst wrote:
> Do you use that abstract base class as a RPC parameter? If so, *of
> course*GWT has to look for and try to compile all sub classes and
> implementations
> *since* they might get used in a RPC and hence need to be serializable and
> compilable.
>
> To avoid this you can either:
> - refactor your RPC to use only the concrete types
>
> *or* if you rely on using abstract classes or interfaces in RPC:
> - you might want to configure your sub classes' packages to be part of a
> module's client packages, so that the GWT compiler finds them (your "No
> source found..." error indicates that this is not the case).
>
> I personnaly think your problem is not the behaviour of the GWT compiler but
> your project setup regarding separation into modules. Hope this can help
> you.
>
> 2011/3/16 KD <[email protected]>
>
> > Lets say I have package : com.mycom.model
> >
> > It has following classes
> >
> > com.mycom.model.PlatformMessage (an interface)
> >
> > com.mycom.model.AbstractMessage (an abstract class that implements
> > PlatformMessage)
> >
> > com.mycom.model.QueryMessage (a concrete implementation of
> > AbstractMessage)
> >
> > Now there is another package: com.mycom.app
> >
> > It has the following class...
> >
> > com.mycom.app.StreamMessage (a concrete implementation of
> > AbstractMessage)
> >
> > ONLY com.mycom.model a GWT module.
> >
> > Now when I compile com.mycom.model, why does it need to go and look
> > for all implementations of that abstract class AbstractMessage in
> > OTHER packages (as I later find with many No Source found..."
> > errors)?
> >
> > It seems RPC serializer is trying to serialize/compile all classes
> > that IMPLEMENT an abstract class in my gwt module.
> >
> > Is there way to workaround this?
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to [email protected].
> > To unsubscribe from this group, send email to
> > [email protected].
> > For more options, visit this group at
> > http://groups.google.com/group/google-web-toolkit?hl=en.
> >
> >

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to