Added Java server side - not all works

Interesting problem is found (apparently, because of Jersey web
server) - when 'curl' performs any request, then WineDAO is
allocated on every request (see line 20 in WineResources.java).

Below is the results of testing by 'curl' utility:

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/json
Content-Length: 177
Date: Fri, 09 May 2014 17:45:39 GMT

[{"name":"DummyName","id":0,"country":"DummyCountry","region":"DummyRegion","year":"DummyYear","description":"DummyDescription","picture":"DummyPicture","grapes":"DummyGrapes"}]

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines/0
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/json
Content-Length: 175
Date: Fri, 09 May 2014 17:45:41 GMT

{"name":"DummyName","id":0,"country":"DummyCountry","region":"DummyRegion","year":"DummyYear","description":"DummyDescription","picture":"DummyPicture","grapes":"DummyGrapes"}

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines -H 'Accept:application/json'
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/json
Content-Length: 177
Date: Fri, 09 May 2014 17:45:53 GMT

[{"name":"DummyName","id":0,"country":"DummyCountry","region":"DummyRegion","year":"DummyYear","description":"DummyDescription","picture":"DummyPicture","grapes":"DummyGrapes"}]

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines -H 'Accept:application/xml'
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/xml
Content-Length: 298
Date: Fri, 09 May 2014 17:45:58 GMT

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><wines><wine><country>DummyCountry</country><description>DummyDescription</description><grapes>DummyGrapes</grapes><id>0</id><name>DummyName</name><picture>DummyPicture</picture><region>DummyRegion</region><year>DummyYear</year></wine></wines>

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines/0 -H 'Accept:application/json'
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/json
Content-Length: 175
Date: Fri, 09 May 2014 17:46:08 GMT

{"name":"DummyName","id":0,"country":"DummyCountry","region":"DummyRegion","year":"DummyYear","description":"DummyDescription","picture":"DummyPicture","grapes":"DummyGrapes"}

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines/0 -H 'Accept:application/xml'
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/xml
Content-Length: 283
Date: Fri, 09 May 2014 17:46:12 GMT

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><wine><country>DummyCountry</country><description>DummyDescription</description><grapes>DummyGrapes</grapes><id>0</id><name>DummyName</name><picture>DummyPicture</picture><region>DummyRegion</region><year>DummyYear</year></wine>

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines/search/DummyName -H 'Accept:application/json'
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/json
Content-Length: 175
Date: Fri, 09 May 2014 17:46:23 GMT

{"name":"DummyName","id":0,"country":"DummyCountry","region":"DummyRegion","year":"DummyYear","description":"DummyDescription","picture":"DummyPicture","grapes":"DummyGrapes"}

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X GET http://localhost:8080/WineCellar/api/wines/search/DummyName -H 'Accept:application/xml'
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: application/xml
Content-Length: 283
Date: Fri, 09 May 2014 17:46:26 GMT

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><wine><country>DummyCountry</country><description>DummyDescription</description><grapes>DummyGrapes</grapes><id>0</id><name>DummyName</name><picture>DummyPicture</picture><region>DummyRegion</region><year>DummyYear</year></wine>

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -i -X DELETE http://localhost:8080/WineCellar/api/wines/0
HTTP/1.1 204 No Content
Server: Apache-Coyote/1.1
Content-Type: application/json
Date: Fri, 09 May 2014 17:48:22 GMT

Olesya@cool-biz-mach /cygdrive/c/Users/Olesya/workspace/WineCellar
$ curl -X POST -H "Content-Type: application/json" -d '{"name":"1stName","id":0,"country":"1stCountry","region":"1stRegion","year":"1stYear","description":"1stDescription","picture":"1stPicture","grapes":"1stGrapes"}' http://localhost:8080/WineCellar/api/wines