Is there an easy way to invoke a GWT RPC service endpoint directly from Java code? I mean real Java code, not Java code compiled down into javascript.
I ask because
GWT SyncProxy allows you to access GWT RPC services (e.g methods) from pure Java (not JSNI) code. Thus you can use it to test your RPC interface.
See http://www.gdevelop.com/w/blog/2010/01/10/testing-gwt-rpc-services/ for details.
Are you trying to benchmark the business logic of the service, or how well GWT-RPC itself performs? If you are mostly worried about how well your backend code performs, you could just instantiate the class that implements your service directly:
MyServiceImpl impl = new MyServiceImpl();
impl.doSomething();
If you want to test a greater slice of the stack, including the RPC calls, take a look here. There is a section called "running your test in web mode" that has the following line: 'By default, tests run in hosted mode are run as normal Java bytecode in a JVM'. So if you use the described setup, I think you get your tests to run in java by default. Also on that page is info about GWT's built in profiling tools.
You could use a conventional load testing tool like Grinder to replay post requests to your service. That isn't quite what you are asking but it may be a better way to perform load testing on your application. Grinder can simulate many simultaneous users and so on.