[ARVADOS] updated: 5a7951a1684382e5bdb04d4e8ef945a6ced19cee

git at public.curoverse.com git at public.curoverse.com
Fri Oct 9 18:03:16 EDT 2015


Summary of changes:
 apps/workbench/app/helpers/version_helper.rb       |  28 +----
 .../views/application/_report_issue_popup.html.erb |  15 +--
 apps/workbench/config/application.default.yml      |  48 +--------
 apps/workbench/config/application.rb               |   1 +
 apps/workbench/lib/app_version.rb                  |  53 +++++++++
 sdk/cwl/setup.py                                   |   2 +-
 sdk/go/keepclient/keepclient.go                    |  20 ++--
 sdk/go/keepclient/perms.go                         | 119 ++++++++-------------
 sdk/go/keepclient/perms_test.go                    |  10 +-
 sdk/go/keepclient/support.go                       |  12 ++-
 .../controllers/arvados/v1/schema_controller.rb    |   2 +-
 services/api/config/application.default.yml        |  48 +--------
 services/api/config/initializers/app_version.rb    |   1 +
 services/api/lib/app_version.rb                    |  52 +++++++++
 services/api/lib/tasks/config_check.rake           |   3 +-
 .../arvados/v1/schema_controller_test.rb           |  22 ++++
 services/api/test/unit/app_version_test.rb         |  43 ++++++++
 services/keepstore/keepstore_test.go               |   2 +-
 services/keepstore/perms.go                        |  51 ++-------
 services/keepstore/perms_test.go                   | 102 ++++--------------
 20 files changed, 294 insertions(+), 340 deletions(-)
 create mode 100644 apps/workbench/lib/app_version.rb
 create mode 100644 services/api/config/initializers/app_version.rb
 create mode 100644 services/api/lib/app_version.rb
 create mode 100644 services/api/test/unit/app_version_test.rb

       via  5a7951a1684382e5bdb04d4e8ef945a6ced19cee (commit)
       via  1841871773da24d4a743bf9083e1fa461a510125 (commit)
       via  e55f6e9fcb652a2b1505364b34d9d48e79adaeaf (commit)
       via  e9a7e33f90106db0d36d8d45f1929483662c7168 (commit)
       via  f814b4b5d0c6168c95d2eda87a45c87df07c72c9 (commit)
       via  5e2bf20f75a532625719f0f779d1e26f9d4466c4 (commit)
       via  5b80941723d6be1fd22589026635a43b33e6cf20 (commit)
       via  5089c3bb94101d32028d0fc06283f43fd70af53c (commit)
       via  38576187f1f1198afe0a8b6a62f7bf1388bd339d (commit)
       via  db728a63e741c61f93a200129997c74fdc3065b7 (commit)
       via  2f3634990e8c2d9b374c99d7432a188f43175a35 (commit)
       via  20c5b73d598463a7dfb4ce711993480d56e23838 (commit)
       via  3ee62426a5ebfc056f58cd0655ba1e9f7ed0a722 (commit)
       via  b8afbe378247ba5cb81b067f37a35350726f038b (commit)
       via  8ff3305a11a7effb73ad9cfe2c55ba572e56f6b0 (commit)
       via  a084ddc8af3f05ffe35392a86cf2400c5bbe2176 (commit)
       via  1d73ebb1fb2f2f50144de4f74b3aa77616a5d4f2 (commit)
       via  15e0b0671b04a81a8e8fa289002655d28d7efb50 (commit)
       via  b598910bb715d9f4803a2ca1c0f84492c5761ed7 (commit)
       via  966b17d66eafb2d1707c5b5119ba0c87fcdae44a (commit)
       via  8a3fb7961809da1a2aeca4bfd26c012f794379e3 (commit)
       via  e88cbab376ec5e26266ed021193b9d387b14dfa7 (commit)
      from  5790a95b32d3a2268feea07d5ae580e28235bd4c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 5a7951a1684382e5bdb04d4e8ef945a6ced19cee
Merge: db728a6 1841871
Author: radhika <radhika at curoverse.com>
Date:   Fri Oct 9 18:01:14 2015 -0400

    Merge branch '7167-keep-rsync-test-setup' into 7167-keep-rsync


commit 1841871773da24d4a743bf9083e1fa461a510125
Merge: 2f36349 e55f6e9
Author: radhika <radhika at curoverse.com>
Date:   Fri Oct 9 18:00:56 2015 -0400

    Merge branch 'master' into 7167-keep-rsync-test-setup
    
    Conflicts:
    	sdk/go/keepclient/perms.go
    	sdk/go/keepclient/perms_test.go
    	services/keepstore/perms.go
    	services/keepstore/perms_test.go


commit db728a63e741c61f93a200129997c74fdc3065b7
Merge: 5790a95 2f36349
Author: radhika <radhika at curoverse.com>
Date:   Fri Oct 9 08:44:46 2015 -0400

    Merge branch '7167-keep-rsync-test-setup' into 7167-keep-rsync


commit 2f3634990e8c2d9b374c99d7432a188f43175a35
Author: radhika <radhika at curoverse.com>
Date:   Fri Oct 9 08:43:37 2015 -0400

    7167: default replications count from discovery doc test updates.

diff --git a/tools/keep-rsync/keep-rsync_test.go b/tools/keep-rsync/keep-rsync_test.go
index 6bc0cb7..81b64ff 100644
--- a/tools/keep-rsync/keep-rsync_test.go
+++ b/tools/keep-rsync/keep-rsync_test.go
@@ -40,10 +40,10 @@ func (s *ServerRequiredSuite) TearDownSuite(c *C) {
 }
 
 // Testing keep-rsync needs two sets of keep services: src and dst.
-// The test setup hence tweaks keep-rsync initialzation to achieve this.
-// First invoke initializeKeepRsync and then invoke StartKeepAdditional
+// The test setup hence tweaks keep-rsync initialization to achieve this.
+// First invoke initializeKeepRsync and then invoke StartKeepWithParams
 // to create the keep servers to be used as destination.
-func setupRsync(c *C, enforcePermissions bool) {
+func setupRsync(c *C, enforcePermissions bool, overwriteReplications bool) {
 	// srcConfig
 	srcConfig.APIHost = os.Getenv("ARVADOS_API_HOST")
 	srcConfig.APIToken = os.Getenv("ARVADOS_API_TOKEN")
@@ -69,7 +69,12 @@ func setupRsync(c *C, enforcePermissions bool) {
 	// Create two more keep servers to be used as destination
 	arvadostest.StartKeepWithParams(true, enforcePermissions)
 
-	// load kcDst; set Want_replicas as 1 since that is how many keep servers are created for dst.
+	// set replications to 1 since those many keep servers were created for dst.
+	if overwriteReplications {
+		replications = 1
+	}
+
+	// load kcDst
 	kcDst, err = keepclient.MakeKeepClient(&arvDst)
 	c.Assert(err, Equals, nil)
 	kcDst.Want_replicas = 1
@@ -105,7 +110,7 @@ func (s *ServerRequiredSuite) TestReadConfigFromFile(c *C) {
 // Do a Get in dst for the src hash, which should raise block not found error.
 // Do a Get in src for the dst hash, which should raise block not found error.
 func (s *ServerRequiredSuite) TestRsyncPutInOne_GetFromOtherShouldFail(c *C) {
-	setupRsync(c, false)
+	setupRsync(c, false, true)
 
 	// Put a block in src using kcSrc and Get it
 	srcData := []byte("test-data1")
@@ -137,11 +142,11 @@ func (s *ServerRequiredSuite) TestRsyncPutInOne_GetFromOtherShouldFail(c *C) {
 	all, err = ioutil.ReadAll(reader)
 	c.Check(all, DeepEquals, dstData)
 
-	// Get srcLocator using kcDst should fail with NotFound error
+	// Get srcLocator using kcDst should fail with Not Found error
 	_, _, _, err = kcDst.Get(locatorInSrc)
 	c.Assert(err.Error(), Equals, "Block not found")
 
-	// Get dstLocator using kcSrc should fail with NotFound error
+	// Get dstLocator using kcSrc should fail with Not Found error
 	_, _, _, err = kcSrc.Get(locatorInDst)
 	c.Assert(err.Error(), Equals, "Block not found")
 }
@@ -150,7 +155,7 @@ func (s *ServerRequiredSuite) TestRsyncPutInOne_GetFromOtherShouldFail(c *C) {
 func (s *ServerRequiredSuite) TestRsyncInitializeWithKeepServicesJSON(c *C) {
 	srcKeepServicesJSON = "{ \"kind\":\"arvados#keepServiceList\", \"etag\":\"\", \"self_link\":\"\", \"offset\":null, \"limit\":null, \"items\":[ { \"href\":\"/keep_services/zzzzz-bi6l4-123456789012340\", \"kind\":\"arvados#keepService\", \"etag\":\"641234567890enhj7hzx432e5\", \"uuid\":\"zzzzz-bi6l4-123456789012340\", \"owner_uuid\":\"zzzzz-tpzed-123456789012345\", \"service_host\":\"keep0.zzzzz.arvadosapi.com\", \"service_port\":25107, \"service_ssl_flag\":false, \"service_type\":\"disk\", \"read_only\":false }, { \"href\":\"/keep_services/zzzzz-bi6l4-123456789012341\", \"kind\":\"arvados#keepService\", \"etag\":\"641234567890enhj7hzx432e5\", \"uuid\":\"zzzzz-bi6l4-123456789012341\", \"owner_uuid\":\"zzzzz-tpzed-123456789012345\", \"service_host\":\"keep0.zzzzz.arvadosapi.com\", \"service_port\":25108, \"service_ssl_flag\":false, \"service_type\":\"disk\", \"read_only\":false } ], \"items_available\":2 }"
 
-	setupRsync(c, false)
+	setupRsync(c, false, true)
 
 	localRoots := kcSrc.LocalRoots()
 	c.Check(localRoots != nil, Equals, true)
@@ -172,13 +177,13 @@ func (s *ServerRequiredSuite) TestRsyncInitializeWithKeepServicesJSON(c *C) {
 	c.Check(foundIt, Equals, true)
 }
 
-// Test keep-rsync initialization, with src and dst keep servers with blobSingingKey.
+// Test keep-rsync initialization, with src and dst keep servers with blobSigningKey.
 // Do a Put and Get in src, both of which should succeed.
 // Do a Put and Get in dst, both of which should succeed.
 // Do a Get in dst for the src hash, which should raise block not found error.
 // Do a Get in src for the dst hash, which should raise block not found error.
 func (s *ServerRequiredSuite) TestRsyncWithBlobSigning_PutInOne_GetFromOtherShouldFail(c *C) {
-	setupRsync(c, true)
+	setupRsync(c, true, true)
 
 	// Put a block in src using kcSrc and Get it
 	srcData := []byte("test-data1")
@@ -215,12 +220,12 @@ func (s *ServerRequiredSuite) TestRsyncWithBlobSigning_PutInOne_GetFromOtherShou
 	all, err = ioutil.ReadAll(reader)
 	c.Check(all, DeepEquals, dstData)
 
-	// Get srcLocator using kcDst should fail with NotFound error
+	// Get srcLocator using kcDst should fail with Not Found error
 	signedLocator = keepclient.SignLocator(locatorInSrc, arvDst.ApiToken, tomorrow, []byte(blobSigningKey))
 	_, _, _, err = kcDst.Get(locatorInSrc)
 	c.Assert(err.Error(), Equals, "Block not found")
 
-	// Get dstLocator using kcSrc should fail with NotFound error
+	// Get dstLocator using kcSrc should fail with Not Found error
 	signedLocator = keepclient.SignLocator(locatorInDst, arvSrc.ApiToken, tomorrow, []byte(blobSigningKey))
 	_, _, _, err = kcSrc.Get(locatorInDst)
 	c.Assert(err.Error(), Equals, "Block not found")
@@ -228,7 +233,7 @@ func (s *ServerRequiredSuite) TestRsyncWithBlobSigning_PutInOne_GetFromOtherShou
 
 // Test keep-rsync initialization with default replications count
 func (s *ServerRequiredSuite) TestInitializeRsyncDefaultReplicationsCount(c *C) {
-	setupRsync(c, false)
+	setupRsync(c, false, false)
 
 	// Must have got default replications value as 2 from dst discovery document
 	c.Assert(replications, Equals, 2)
@@ -236,10 +241,10 @@ func (s *ServerRequiredSuite) TestInitializeRsyncDefaultReplicationsCount(c *C)
 
 // Test keep-rsync initialization with replications count argument
 func (s *ServerRequiredSuite) TestInitializeRsyncReplicationsCount(c *C) {
-	// set replications to 3 to mimic passing input argument
+	// First set replications to 3 to mimic passing input argument
 	replications = 3
 
-	setupRsync(c, false)
+	setupRsync(c, false, false)
 
 	// Since replications value is provided, default is not used
 	c.Assert(replications, Equals, 3)

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list