-
May 29th, 2012, 05:54 AM
#1
How to reduce the URI for my RESTFul service of GET having 10 parameters
Hi:
We are developing RESTFul webservice for our project using Spring MVC 3.0.5.
We have a resource which can be identified by 10 different parameters, if I add all these parameters as URI query parameters, the URI is becoming too big and all the parameters are visible.
Is there any way to shorten the URI like by using HttpMessage Headers.
currently the URI looks some thing like"http://localhost:/rest/myresource?param1=abc¶m2=xyz¶m3=123...&par am10=lastparam.
Please let me know if anybody has an answer
Regards
Sreedhar
-
May 30th, 2012, 12:04 PM
#2
Hi Sreedhar,
first I would like to note the kind of URI you're using is not much REST-friendly. Here you have some good design tips.
Here is a post you can check about where to put parameters.
Best,
Carlos
-
Jun 1st, 2012, 08:18 AM
#3
Hi Carlos
Thanks for the link, the service is like a search where in it can be identified by around 5 parameters.
We have some generic values, which we will be passing through Request Header.
/Sreedhar
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules