New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rgw: switch to std::array in RGWBulkUploadOp due to C++11 and FreeBSD. #14314

Merged
merged 1 commit into from Apr 5, 2017

Conversation

Projects
None yet
3 participants
@rzarzynski
Contributor

rzarzynski commented Apr 4, 2017

Before this patch RGWBulkUploadOp::terminal_errors was declared as std::initializer_list<int>. Unfortunately, a constexpr constructor for it is available since C++14, not C++11. This was causing build failures on FreeBSD.

Tempest confirms the BulkUpload is operational:

$ ./run_tempest.sh -V tempest.api.object_storage.test_account_bulk.BulkTest
WARNING: This script is deprecated and will be removed in the near future. Please migrate to tempest run or another method of launching a test runner
running=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-500} \
OS_TEST_LOCK_PATH=${OS_TEST_LOCK_PATH:-${TMPDIR:-'/tmp'}} \
${PYTHON:-python} -m subunit.run discover -t ${OS_TOP_LEVEL:-./} ${OS_TEST_PATH:-./tempest/test_discover} --list 
running=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-500} \
OS_TEST_LOCK_PATH=${OS_TEST_LOCK_PATH:-${TMPDIR:-'/tmp'}} \
${PYTHON:-python} -m subunit.run discover -t ${OS_TOP_LEVEL:-./} ${OS_TEST_PATH:-./tempest/test_discover}  --load-list /tmp/tmp491EMe
{0} tempest.api.object_storage.test_account_bulk.BulkTest.test_bulk_delete [4.409547s] ... ok
{0} tempest.api.object_storage.test_account_bulk.BulkTest.test_bulk_delete_by_POST [0.158442s] ... ok
{0} tempest.api.object_storage.test_account_bulk.BulkTest.test_extract_archive [0.083129s] ... ok

======
Totals
======
Ran: 3 tests in 8.0000 sec.
 - Passed: 3
 - Skipped: 0
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 0
Sum of execute time for each test: 4.6511 sec.

==============
Worker Balance
==============
 - Worker 0 (3 tests) => 0:00:04.661215

@wjwithagen: could you please verify whether this patch helps FreeBSD? I'm marking it as DNM for now.

CC: @oritwas

@rzarzynski rzarzynski added the rgw label Apr 4, 2017

@rzarzynski rzarzynski changed the title from rgw: switch to std::array in RGWBulkUploadOp due to C++11 and FreeBSD. to [DNM] rgw: switch to std::array in RGWBulkUploadOp due to C++11 and FreeBSD. Apr 4, 2017

@oritwas

This comment has been minimized.

Contributor

oritwas commented Apr 4, 2017

lgtm, we just need to make sure it builds on BSD

@oritwas oritwas self-assigned this Apr 4, 2017

@wjwithagen wjwithagen self-requested a review Apr 4, 2017

@wjwithagen

This comment has been minimized.

Contributor

wjwithagen commented Apr 4, 2017

@rzarzynski
I have put your PR in a diff, and that gets applied to my Jenkins runs.
Should be able to see the result at:
http://cephdev.digiware.nl:8180/jenkins/job/ceph-master/504/console

@rzarzynski

This comment has been minimized.

Contributor

rzarzynski commented Apr 4, 2017

@wjwithagen: thanks a lot! Waiting for the build.

@rzarzynski

This comment has been minimized.

Contributor

rzarzynski commented Apr 4, 2017

/home/jenkins/workspace/ceph-master/build/lib/librgw.so: undefined reference to `RGWBulkUploadOp::terminal_errors'
cc: error: linker command failed with exit code 1 (use -v to see invocation)

Fixing right now.

rgw: switch to std::array in RGWBulkUploadOp due to C++11 and FreeBSD.
Before this patch RGWBulkUploadOp::terminal_errors was declared as
std::initializer_list<int>. Unfortunately, a constexpr constructor
for it is available since C++14, not C++11. This was causing build
failures on FreeBSD.

Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
@rzarzynski

This comment has been minimized.

Contributor

rzarzynski commented Apr 4, 2017

@wjwithagen: just posted the amended patch.

@wjwithagen

This comment has been minimized.

Contributor

wjwithagen commented Apr 4, 2017

@rzarzynski
Right obvious... I have the same errors times over....
Jenkins is running.
Can check at:
http://cephdev.digiware.nl:8180/jenkins/job/ceph-master/lastBuild/console

I'm off for my evening appointment.

@rzarzynski

This comment has been minimized.

Contributor

rzarzynski commented Apr 4, 2017

@wjwithagen

@rzarzynski
Jenkins build is back to normal : ceph-master #505

@rzarzynski

This comment has been minimized.

Contributor

rzarzynski commented Apr 4, 2017

Great! Also gitbuilders are OK with the change. I'm removing the DNM tag right now.

@rzarzynski rzarzynski changed the title from [DNM] rgw: switch to std::array in RGWBulkUploadOp due to C++11 and FreeBSD. to rgw: switch to std::array in RGWBulkUploadOp due to C++11 and FreeBSD. Apr 4, 2017

@oritwas oritwas merged commit 2e9609d into ceph:master Apr 5, 2017

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details
default Build finished.
Details
@rzarzynski

This comment has been minimized.

Contributor

rzarzynski commented Apr 5, 2017

It's merged. Big thanks @wjwithagen for bug your involvement! :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment