Re: test failing on 2.4

23 views
Skip to first unread message

Diego Gil

unread,
Feb 26, 2010, 3:48:50 PM2/26/10
to rest-client
On Fri, Feb 26, 2010 at 5:04 PM, dags <diego...@gmail.com> wrote:
>
> I was using restclient-2.3, -cli and -ui versions, to do some Jersey
> web services tests. Each test has a small groovy script similar to
> script sample.Everything was ok with 2.3 version.
>
> A I wanted to do some automated tersting on Hudson, I code a class to
> run several tests. That class is much the same as the main class of -
> cli main. To do that, I needed restclient-lib jar, so I  downloaded
> and compiled all  the code. That was 2.4 trunk.
>
> The funny part is that the same test .rcq that works OK on 2.3, both -
> cli and -ui, doesn't work on 2.4 -ui neither my test runner class.
>
> After doing some tests, the main different is seems to be the way it
> handles request body content. My web server receives some garbage
> instead of xml data.
>
> Any hints ?
>
> Regards,
> Diego.

I reply to myself:

In 2.3 version request scripts hold body data as plain text. In 2.4
body data is encoded, so using old 2.3 scripts with 2.4 libs doesn't work.
It tries to decode a never encoded data, resulting in body data
corruption.

Hope this help anyone.

Regards,
Diego.

dags

unread,
Feb 26, 2010, 3:04:17 PM2/26/10
to rest-client

sub...@gmail.com

unread,
Mar 1, 2010, 8:05:10 PM3/1/10
to rest-client
2.4 trunk is pretty unstable with lots of experimental features. I am
thinking of removing support for binary types in the body content. I
will keep you posted of the progress.

Subhash.

On Feb 27, 1:48 am, Diego Gil <diego.a....@gmail.com> wrote:

Diego Gil

unread,
Mar 2, 2010, 12:30:44 PM3/2/10
to rest-...@googlegroups.com
On Mon, 2010-03-01 at 17:05 -0800, sub...@gmail.com wrote:
> 2.4 trunk is pretty unstable with lots of experimental features. I am
> thinking of removing support for binary types in the body content. I
> will keep you posted of the progress.
>
> Subhash.
>

Thanks for you info. Meanwhile, I switched back to 2.3, compiling
restclient-lib from the branch.

Anyway, I liked a lot the binary types support in the body content. I
realized later that was just my fault: I was using 2.3 generated scripts
with 2.4 libs. It works exactly the way it was supposed to be: trying to
decode plain text as base64.

Regards,
Diego.

caska...@gmail.com

unread,
Mar 10, 2010, 1:29:35 AM3/10/10
to rest-client
Hi,

I've been using RESTClient for a while now and it's been very useful
so thank you for the hard work. I'd like to extend it to support
Amazon S3 authentication (AWS).

I have downloaded the trunk and have had a series of problems with
getting the build to run and debug using maven/eclipse. For one I was
unable to find the dependency wiztools-commons-lib:0.1.0-SNAPSHOT. I
could only find version 0.1.1 on the website. I thought at first the
test errors I was seeing was the result of a library incompatibility
but perhaps not. When I try to start the app with Eclipse' debugger I
get an ClassNotFoundException as it looks for org.mortbay.jetty.
Ultimately i'm just looking for a stable version of the program I can
develop against. Since the source control doesn't appear to be broken
up into the usual tags/branches/trunk is there a revision number of
some sort I can sync to that is stable?

Cheers,

Jean-Philippe Steinmetz

Subhash Chandran

unread,
Mar 10, 2010, 1:51:34 AM3/10/10
to rest-...@googlegroups.com
Today evening I will commit my changes. After that some of the issues will be solved.

The problem is I decided on too many features for 2.4 and have not been able to develop them. Sorry of the inconvenience.

Subhash.

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




--
Regards,
Subhash Chandran S

Founder http://FileIt.in/

Subhash Chandran

unread,
Mar 10, 2010, 9:47:19 AM3/10/10
to rest-...@googlegroups.com
I have committed the latest changes to make the trunk buildable. Try now.

Subhash.

Jean-Philippe Steinmetz

unread,
Mar 11, 2010, 5:23:27 PM3/11/10
to rest-...@googlegroups.com
I started fresh with latest and I can build now (although there's still a broken unit test in restclient-lib). When I run the jar I get no body from a GET request. I believe this is covered in another thread though. The error I get the following error...

Exception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsException: 7
        at org.wiztools.restclient.ui.ResponseHeaderTableModel.setHeaders(ResponseHeaderTableModel.java:24)
        at org.wiztools.restclient.ui.RESTView.setUIFromResponse(RESTView.java:1509)
        at org.wiztools.restclient.ui.RESTView$27.run(RESTView.java:1139)
        at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

When I try and run through Eclipse's debugger I get the following error at startup that prevents the app from running at all.

Exception in thread "AWT-EventQueue-0" java.lang.Error: Unresolved compilation problem:
    The method getFrame() of type RESTMain must override a superclass method

    at org.wiztools.restclient.ui.RESTMain.getFrame(RESTMain.java:77)
    at org.wiztools.restclient.ui.RESTView.init(RESTView.java:858)
    at org.wiztools.restclient.ui.RESTView.<init>(RESTView.java:208)
    at org.wiztools.restclient.ui.RESTMain.init(RESTMain.java:329)
    at org.wiztools.restclient.ui.RESTMain.<init>(RESTMain.java:68)
    at org.wiztools.restclient.ui.Main$1.run(Main.java:55)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Reply all
Reply to author
Forward
0 new messages