Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jersey-dev] [External] : which storage example
  • From: Jan Supol <jan.supol@xxxxxxxxxx>
  • Date: Wed, 7 Apr 2021 20:17:04 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=IQH9gtQIjWHLPxXGSG6qS8QO7zqzjqCtOOXmOtWaquc=; b=HXB1Y82d7A53xlf/DimquVEQHaxCdxcqk4hOKXEpfQKNu9KItHD0g7PRNntSTo0FVpfW4sUFE2lUnxPMQyEwiqfZpUUCESZApgc7YWzsyYRBraGn54NA9pHqUUOFOKwlgFS4dWiwofFL05d4KvvZ+FdbK9qYCRS4waIMPBxsGqgNFfcIYYHwu/bM1YMi5brRlBwAKpMmiwa5V1P3ukXfkEeDt1ybOWkskXOuH0yNdlOsEdfocRaYgY32GMf84huR5uQS6xk9bsEk0ZSee0XxyF6m4koH63//9cX6CiO8lhKPAg64es8X4WpUMG9OwCUYfQjQZmiga8kPOCzEDhBWWg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=i9m4U5GuEdAupx232sb5H1FAUAEUhO8Yaa3spXXOC13kmnDnvJ8AWhlhB+cvKeHSthxUaRPif639l60yTNUPnQw3AGO/wzh+ijuhfhoMoYJAcoTncYqd5qLnShaQcr8NmDYmX9wg3iCoQ8n7LlMhlCXQGr4bPPgDcyDN6TSza8hHl/Jtm2fwmQ4n4KN5Hxy0Lc1KjBflEtUbnVOVkkp5ZNXRWs32sJLGxkH91h+DOEXivR6O4FcecV4Bi+f1R8hULPVXKGsTtHiNX0jlXnbVVkMeSwuWZMSHTJk4Zr2C1PU9H29PVMNUNyFeo4dVBFaYTgfK3IhrNdagUiow7M52qw==
  • Delivered-to: jersey-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/jersey-dev/>
  • List-help: <mailto:jersey-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/jersey-dev>, <mailto:jersey-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/jersey-dev>, <mailto:jersey-dev-request@eclipse.org?subject=unsubscribe>
  • Thread-index: AQHXK+YVI0xNvuoEr0+amDi2DJLfr6qpfHWU
  • Thread-topic: [External] : [jersey-dev] which storage example

Hi,
This particular sample originates in the old Jersey 1 repo and it can be found here: https://github.com/javaee/jersey-1.x/tree/master/samples/storage-service.

For some reason, it did not make it to Jersey 2 repository. The documentation might contain a better PUT example, thank you for letting us know.

-- Jan

From: jersey-dev <jersey-dev-bounces@xxxxxxxxxxx> on behalf of Dana whitelow <DanaWhitelow@xxxxxxxx>
Sent: Wednesday, April 7, 2021 9:41 PM
To: jersey-dev@xxxxxxxxxxx <jersey-dev@xxxxxxxxxxx>
Subject: [External] : [jersey-dev] which storage example
 

Hi,

I did a search to find the example being referred  to from the  jakarta jersey examples but my search  negative.

$ grep -RiIl 'MemoryStore.MS.hasContainer(c))'
docs/src/main/docbook/jaxrs-resources.xml

which  strorage service example  is being to referred in the sentence below ?

The following example is an extract from the storage service sample that shows the use of the PUT method to create or update a storage container:

Example 3.3. PUT method

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
@PUT
public Response putContainer() {
    System.out.println("PUT CONTAINER " + container);
 
    URI uri = uriInfo.getAbsolutePath();
    Container c = new Container(container, uri.toString());
 
    Response r;
    if (!MemoryStore.MS.hasContainer(c)) {
        r = Response.created(uri).build();
    } else {
        r = Response.noContent().build();
    }
 
    MemoryStore.MS.createContainer(c);
    return r;
}

 


Back to the top