Since the RESTful style uses straight HTTP standards, on the server side you use a
servlet hosted by something like
Tomcat or any other servlet container.
What you are describing is a simple GET operation.
You just need a doGet method which looks up the Id from the incoming request parameters - does the database search, and returns the result as a
String, XML, JSON whatever format your client needs.
For more complicated stuff you could use the
Restlet or the
Jersey toolkit but I don't think there is any need.
On the client side you would work with the standard java library to make a HttpURLConnection request to the servlet and interpret the response.
Bill
Don't panic, it really is quite simple.