7931: Update json field tags on trash/pull requests.
authorTom Clegg <tclegg@veritasgenetics.com>
Fri, 23 Mar 2018 17:18:50 +0000 (13:18 -0400)
committerTom Clegg <tclegg@veritasgenetics.com>
Fri, 23 Mar 2018 17:18:50 +0000 (13:18 -0400)
Arvados-DCO-1.1-Signed-off-by: Tom Clegg <tclegg@veritasgenetics.com>

services/keepstore/handlers.go
services/keepstore/pull_worker_test.go

index 258604ce59c50176a4d4473fd7dbf87c8d66de9c..8b37b906eb7ee11f79813c9749c6de2d3af48623 100644 (file)
@@ -514,7 +514,7 @@ type PullRequest struct {
        Servers []string `json:"servers"`
 
        // Destination mount, or "" for "anywhere"
-       MountUUID string
+       MountUUID string `json:"mount_uuid"`
 }
 
 // PullHandler processes "PUT /pull" requests for the data manager.
@@ -553,7 +553,7 @@ type TrashRequest struct {
        BlockMtime int64  `json:"block_mtime"`
 
        // Target mount, or "" for "everywhere"
-       MountUUID string
+       MountUUID string `json:"mount_uuid"`
 }
 
 // TrashHandler processes /trash requests.
index 7a8297039b513d62b2f8a38ab81ab0f9bc89f187..7b5077c1a7f70dad794e14fc148ae1da7fc60d04 100644 (file)
@@ -127,7 +127,7 @@ func (s *PullWorkerTestSuite) TestSpecifyMountUUID(c *C) {
                        requestBody: []byte(`[{
                                "locator":"acbd18db4cc2f85cedef654fccc4a4d8+3",
                                "servers":["server_1","server_2"],
-                               "mountuuid":"` + spec.sendUUID + `"}]`),
+                               "mount_uuid":"` + spec.sendUUID + `"}]`),
                })
                c.Assert(resp.Code, Equals, http.StatusOK)
                expectEqualWithin(c, time.Second, 0, func() interface{} {