Re: The RequestFactory ValidationTool must be run for the RequestFactory type

2012-01-14 Thread TULC
I'm still stuck on this.  Some projects I've ported to 2.4 now work,
but others still just won't budge.  I have tried all the additional
steps, but my *DeobfuscatorBuilder.java just won't appear in those
projects (event thought the .apt_generated folder does, and is
replaced if I change the name).  I have noticed some (though not all)
of those projects are now giving me the error build.properties does
not exist, which may or may not be related.

I'm frustrated to the point I'm considering ditching GWT altogether; I
haven't been able to proceed with any GWT development since the 2.4
upgrade.  Like the man said, I'm good, really I am, but I just can't
figure this one out, and it really shouldn't be this hard.  Thanks for
the breaking change.

Evan


On Dec 14 2011, 12:12 pm, dparish dpar...@gmail.com wrote:
 I had the same problem. There are two other possible reasons you see
 this:

 1. Your java compliance level in the project is set to 1.5
 2. Your classes are already compiled.  I don't know why, but touching
 the my RequestContext classes had NO affect until I deleted the
 classes that were compiled before I added annotations.  Now it all
 works just fine.

 Attention Google:
 This stuff is w tooo complicated.  I'm good. really I am, but
 this is just misdirection at it's worst.

 On Nov 20, 5:47 pm, oerten25 ozgur.er...@gmail.com wrote:







  I've been getting the same error and tried the things mentioned in the
  discussion without any luck. Finally i realised that i don't have the
  apt_generated folder. So i changed the generated source directory
  option to something other than apt_generated in Annotation
  Processing setting. That fixed it.

  On Oct 2, 11:29 pm, TULC evan.a.te...@gmail.com wrote:

   I just get the sameerroras posted by Eric at the beginning of the
   thread, but I have copied/pasted the full dump below.

   Thomas, I'm not sure what you mean about the .apt_generated being in
   my build path?

   Thanks for the help, guys...
   Evan

   Console:
   log4j:WARN No appenders could be found for logger
   (org.apache.jasper.compiler.Js
   pRuntimeContext).
   log4j:WARN Please initialize the log4j system properly.
   log4j:WARN Seehttp://logging.apache.org/log4j/1.2/faq.html#noconfig
   for more in
   fo.
   03/10/2011 8:24:49 AM
   com.google.web.bindery.requestfactory.server.RequestFactor
   yServlet doPost
   SEVERE: Unexpectederror
   java.lang.RuntimeException: TheRequestFactoryValidationToolmustberunfor th
   e com.google.gwt.sample.dynatablerf.shared.DynaTableRequestFactory
   RequestFactor
   y type
           at com.google.web.bindery.requestfactory.vm.impl.Deobfuscator
   $Builder.load(Deob
   fuscator.java:59)
           at
   com.google.web.bindery.requestfactory.server.ResolverServiceLayer.updateDeo
b
   fuscator(ResolverServiceLayer.java:43)
           at
   com.google.web.bindery.requestfactory.server.ResolverServiceLayer.resolveRe
q
   uestFactory(ResolverServiceLayer.java:176)
           at
   com.google.web.bindery.requestfactory.server.ServiceLayerDecorator.resolveR
e
   questFactory(ServiceLayerDecorator.java:172)
           at
   com.google.web.bindery.requestfactory.server.ServiceLayerDecorator.resolveR
e
   questFactory(ServiceLayerDecorator.java:172)
           at
   com.google.web.bindery.requestfactory.server.ServiceLayerDecorator.resolveR
e
   questFactory(ServiceLayerDecorator.java:172)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at
   sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
   39
   )
           at
   sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImp
l
   .java:25)
           at java.lang.reflect.Method.invoke(Method.java:597)
           at
   com.google.web.bindery.requestfactory.server.ServiceLayerCache.getOrCache(S
e
   rviceLayerCache.java:233)
           at
   com.google.web.bindery.requestfactory.server.ServiceLayerCache.resolveReque
s
   tFactory(ServiceLayerCache.java:198)
           at
   com.google.web.bindery.requestfactory.server.SimpleRequestProcessor.process
(
   SimpleRequestProcessor.java:207)
           at
   com.google.web.bindery.requestfactory.server.SimpleRequestProcessor.process
(
   SimpleRequestProcessor.java:127)
           at
   com.google.web.bindery.requestfactory.server.RequestFactoryServlet.doPost(R
e
   questFactoryServlet.java:133)
           at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
           at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
           at 
   org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
   487)
           at org.mortbay.jetty.servlet.ServletHandler
   $CachedChain.doFilter(ServletHandler
   .java:1097)
           at
   com.google.gwt.sample.dynatablerf.server.SchoolCalendarService.doFilter(Sch
o
   olCalendarService.java:89)
           at org.mortbay.jetty.servlet.ServletHandler

Re: The RequestFactory ValidationTool must be run for the RequestFactory type

2011-10-02 Thread TULC
)
at com.google.gwt.http.client.RequestBuilder
$1.onReadyStateChange(RequestBuilde
r.java:395)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
39
)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:
103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:
71)
at
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java
:172)
at
com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingFor
Return(BrowserChannelServer.java:337)
at
com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChanne
lServer.java:218)
at
com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:
136
)
at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:
561)
at
com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:
269
)
at
com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.ja
va:91)
at com.google.gwt.core.client.impl.Impl.apply(Impl.java)
at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:213)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
39
)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:
103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:
71)
at
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java
:172)
at
com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannel
Server.java:292)
at
com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChann
elServer.java:546)
at
com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:
363)
at java.lang.Thread.run(Thread.java:619)



On Oct 1, 6:48 pm, Jonas Zumkehr jonas.zumk...@gmail.com wrote:
 When you run the application, you should get errors in the Development
 Mode or Console Tabs. Can you post them?
 You get there some good hints where to look for the problem.

 2011/10/1 TULC evan.a.te...@gmail.com







  I had also assumed the verbose=false line wasn't necessary, but
  unfortunately even with that option I still get the same error.  My
  steps are:

   - enable project specific settings (Java Compiler/Annotation
  Processing)
   - enable annotation processing
   - enable processing in editor
   - .apt_generated is already listed as the generated source directory
   - add verbose=false processor option
   - enable project specific settings (Java Compiler/Annotation
  Processing/Factory Path)
   - add C:\Program Files\Eclipse\Indigo\plugins

  \com.google.gwt.eclipse.sdkbundle_2.4.0.r37v2011083017107\gwt-2.4.0\request 
  factory-
  apt.jar
   - debug as Web Application

  I got quite excited when I read your reply, despite how dumb I would
  feel if that was all it took to fix the problem... I just can't quite
  work out what I'm doing wrong!

  Thanks for your help,
  Evan

  On Sep 23, 5:03 pm, Jonas jonas.zumk...@gmail.com wrote:
   Hi,

   this Wiki entry helped me to solve the problem:
 http://code.google.com/p/google-web-toolkit/wiki/RequestFactoryInterf...
   Do exactly what is shown in the printscreens and it should work.

   If it's not working tell exactly what you did. I almost got crazy and did
   see that they added verbose=false to Annotation Processing. I thought
  this
   isn't necessary as they didn't mention it in the text. I was wrong.

   Jonas

  --
  You received this message because you are subscribed to the Google Groups
  Google Web Toolkit group.
  To post to this group, send email to google-web-toolkit@googlegroups.com.
  To unsubscribe from this group, send email to
  google-web-toolkit+unsubscr...@googlegroups.com.
  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 google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: The RequestFactory ValidationTool must be run for the RequestFactory type

2011-10-01 Thread TULC
I had also assumed the verbose=false line wasn't necessary, but
unfortunately even with that option I still get the same error.  My
steps are:

 - enable project specific settings (Java Compiler/Annotation
Processing)
 - enable annotation processing
 - enable processing in editor
 - .apt_generated is already listed as the generated source directory
 - add verbose=false processor option
 - enable project specific settings (Java Compiler/Annotation
Processing/Factory Path)
 - add C:\Program Files\Eclipse\Indigo\plugins
\com.google.gwt.eclipse.sdkbundle_2.4.0.r37v2011083017107\gwt-2.4.0\requestfactory-
apt.jar
 - debug as Web Application

I got quite excited when I read your reply, despite how dumb I would
feel if that was all it took to fix the problem... I just can't quite
work out what I'm doing wrong!

Thanks for your help,
Evan

On Sep 23, 5:03 pm, Jonas jonas.zumk...@gmail.com wrote:
 Hi,

 this Wiki entry helped me to solve the 
 problem:http://code.google.com/p/google-web-toolkit/wiki/RequestFactoryInterf...
 Do exactly what is shown in the printscreens and it should work.

 If it's not working tell exactly what you did. I almost got crazy and did
 see that they added verbose=false to Annotation Processing. I thought this
 isn't necessary as they didn't mention it in the text. I was wrong.

 Jonas

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



Re: The RequestFactory ValidationTool must be run for the RequestFactory type

2011-09-22 Thread TULC
I have not yet been able to get past this problem...

I am simply trying to run the DynaTableRF from the samples in
eclipse.  I have the latest GPE installed.  I have followed the
instructions at 
http://code.google.com/p/google-web-toolkit/wiki/RequestFactoryInterfaceValidation
for eclipse and have also tried adding requestfactory-apt.jar to the
eclipse project build path manually.  I am not using Maven.  I have
tried adding all the requestfactory-* JARs to the build path, even
though I understand requestfactory-client.jar is supposed to be
included in gwt-user.jar and similarly with requestfactory-server.jar
in gwt-servlet.jar.  I have also tried putting both requestfactory-
server.jar and requestfactory-apt.jar into the WEB-INF/lib directory.
But it keeps failing with this error.

Can anyone help me??

Cheers,

Evan

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



Abstraction in RequestFactory

2011-03-10 Thread TULC
Hi all,

I am using RequestFactory with JPA and am attempting to abstract some
of the common methods.  However, whenever I abstract a method that
takes a List or Set parameter, I get errors such as:

Line 3: The type BaseEntityServiceImpl must implement the inherited
abstract method BaseEntityService.findPage(int, int, List, List)
Line 16: Name clash: The method findPage(int, int, ListString,
ListBoolean) of type BaseEntityServiceImpl has the same erasure as
findPage(int, int, List, List) of type BaseEntityService but does not
override it

I am having trouble seeing what I'm doing wrong, since those errors
relate to GWT-generated code.

I have:

public class BaseEntity {
...
public T extends BaseEntity ListT findPage(int start, int
length) {
return JPAImpl.getEntities(this.getClass(), start, length);
}
public T extends BaseEntity ListT findPage(int start, int
length, ListString sortFields, ListBoolean sortDirs) {
// code to create MapString, Boolean sort using [sortFields:
sortDirs]
return JPAImpl.getEntities(this.getClass(), start, length,
sort);
}
...
}

@ProxyFor (value = BaseEntity.class, locator =
BaseEntityLocator.class)
public interface BaseEntityProxy extends EntityProxy {
...
}

@Service (value = BaseEntity.class, locator =
BaseEntityServiceLocator.class)
public interface BaseEntityServiceE extends BaseEntityProxy extends
RequestContext {
...
public RequestListE findPage(int start, int length);
public RequestListE findPage(int start, int length,
ListString sortFields, ListBoolean sortDirs);
...
}

public class TestEntity extends BaseEntity {...}

@ProxyFor (value = TestEntity.class, locator =
BaseEntityLocator.class)
public interface TestProxy extends BaseEntityProxy {...}

@Service (value = TestEntity.class, locator =
BaseEntityServiceLocator.class)
public interface TestService extends BaseEntityServiceTestProxy
{...}

If I comment out the second method from the service interface, it all
works fine.  I can call findPage(int, int) and get my list of entity
proxies, which are of the parameterised type.  However, as soon as I
add the second method, I get the failure:

Line 3: The type BaseEntityServiceImpl must implement the inherited
abstract method BaseEntityService.findPage(int, int, List, List)
Line 16: Name clash: The method findPage(int, int, ListString,
ListBoolean) of type BaseEntityServiceImpl has the same erasure as
findPage(int, int, List, List) of type BaseEntityService but does not
override it

Looking at the generated code snapshot, it all looks ok (to me):

public class BaseEntityServiceImpl extends
com.google.gwt.requestfactory.shared.impl.AbstractRequestContext
implements sandbox.server.BaseEntityService {
  public
BaseEntityServiceImpl(com.google.gwt.requestfactory.shared.impl.AbstractRequestFactory
requestFactory) {super(requestFactory);}
  ...
  public
com.google.gwt.requestfactory.shared.Requestjava.util.Listsandbox.shared.TestProxy
findPage(final int arg0,final int arg1,final
java.util.Listjava.lang.String arg2,final
java.util.Listjava.lang.Boolean arg3) {
class X extends
com.google.gwt.requestfactory.shared.impl.AbstractRequestjava.util.Listsandbox.shared.TestProxy
implements
com.google.gwt.requestfactory.shared.Requestjava.util.Listsandbox.shared.TestProxy
{
  public X() { super(BaseEntityServiceImpl.this);}
  @Override public X with(String... paths) {super.with(paths);
return this;}
  @Override protected
com.google.gwt.requestfactory.shared.impl.RequestData
makeRequestData() {
return new
com.google.gwt.requestfactory.shared.impl.RequestData(sandbox.server.EntityService::findPage,
new Object[] {arg0,arg1,arg2,arg3}, propertyRefs,
java.util.List.class, sandbox.shared.TestProxy.class);
  }
}
X x = new X();
addInvocation(x);
return x;
  }
  ...
}

In fact, any method in an abstracted service with a List or Set
parameter gives me this error.  If I write the method directly into
the concrete service (i.e. into TestService without parameterisation),
it works fine.  The abstracted methods without List or Set work fine,
however, which leads me to believe what I'm trying to do is possible,
I'm just missing something.

Java is not my strongest language so I can't tell where I'm failing,
as the parameterisation doesn't seem ambiguous to me.  However, I'm
struggling to debug because so much of the request factory framework
is generated code.  Can anyone see where my error is?  Is it as simple
as the generated code not including the @Override annotation, or am I
missing something bigger?

Any help would be greatly appreciated!!

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at