You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@jclouds.apache.org by Ka-Hing Cheung <no...@github.com> on 2015/01/19 23:02:28 UTC
[jclouds] fix usermetadata check on OS X (#648)
Java on OS X does not support extended attributes, which the
filesystem blobstore uses to implement user metadata. This disable
the relevant test on OS X
You can view, comment on, or merge this pull request online at:
https://github.com/jclouds/jclouds/pull/648
-- Commit Summary --
* fix usermetadata check on OS X
-- File Changes --
M blobstore/src/test/java/org/jclouds/blobstore/integration/internal/BaseBlobIntegrationTest.java (12)
-- Patch Links --
https://github.com/jclouds/jclouds/pull/648.patch
https://github.com/jclouds/jclouds/pull/648.diff
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Ka-Hing Cheung <no...@github.com>.
@jdaggett I just did a `mvn clean install` with xattrs disabled and TestUtils.isMacOSX() return true, and everything passed.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70746966
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Andrew Gaul <no...@github.com>.
Closed #648.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#event-222046415
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Jeremy Daggett <no...@github.com>.
@kahing Well, that was strange... I had a git remote problem with your repo and now that it is sorted out, `master` is happy again on OS X! +1
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70752052
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Andrew Gaul <no...@github.com>.
> @@ -555,6 +555,14 @@ public void testPutMultipartInputStream() throws Exception {
> testPut(payload, new ByteSourcePayload(byteSource), length, new PutOptions().multipart(true));
> }
>
> + /* Java on OS X does not support extended attributes, which the filesystem backend
> + * uses to implement user metadata */
> + private void checkUserMetadata(Blob blob, Map<String, String> userMetadata1, Map<String, String> userMetadata2) {
> + if ("filesystem".equals(blob.getMetadata().getProviderId()) && !TestUtils.isMacOSX()) {
Can you make this method protected and override it in `FilesystemBlobIntegrationTest`? We follow this pattern for other attributes like system metadata.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648/files#r23253661
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Jeremy Daggett <no...@github.com>.
@kahing Thanks again! Can you please address the comment from @andrewgaul above? Once that looks good, we should get it merged.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70753228
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Jeremy Daggett <no...@github.com>.
@kahing I just run `mvn clean install` :smile:
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70743082
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Ka-Hing Cheung <no...@github.com>.
@jdaggett how did you run the test? I don't have OS X but locally I verified with disabling xattrs and faking TestUtils.isMacOSX() to always return true.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70741593
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Jeremy Daggett <no...@github.com>.
@kahing Hi! I cherry-picked this commit, built again, and have the following 2 test failures in the `BaseBlobIntegrationTest.testPut()` method:
```
Failed tests:
FilesystemBlobIntegrationTest>BaseBlobIntegrationTest.testPutByteSource:531->BaseBlobIntegrationTest.testPut:584
Expecting:
<{}>
to be equal to:
<{"key1"="value1", "key2"="value2"}>
but was not.
FilesystemBlobIntegrationTest>BaseBlobIntegrationTest.testPutInputStream:539->BaseBlobIntegrationTest.testPut:584
Expecting:
<{}>
to be equal to:
<{"key1"="value1", "key2"="value2"}>
but was not.
```
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70729396
Re: [jclouds] fix usermetadata check on OS X (#648)
Posted by Jeremy Daggett <no...@github.com>.
@kahing I will pull the changes over later this morning and let you know, thanks! :+1:
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/648#issuecomment-70680769