Can I append or overwrite some bytes to an existing object in Openstack Swift?

ⅰ亾dé卋堺 提交于 2020-01-14 14:53:29

问题


I need to append some bytes to an existing object stored in Openstack Swift, say like a log file object and constantly append new logs to it. Is this possible?

Moreover, can I change (overwrite) some bytes (specify with offset and length) to an existing object?


回答1:


I believe ZeroVM (zerovm.org) would be perfect for doing this.

Disclaimer: I work for Rackspace, who owns ZeroVM. Opinions are mine and mine alone.




回答2:


tl;dr: There's no append support currently in Swift.

There's a blueprint for Swift append support: https://blueprints.launchpad.net/swift/+spec/object-append. It doesn't look very active.

user2195538 is correct. Using ZeroVM + Swift (using the ZeroCloud middleware for Swift) you could get a performance boost on large-ish objects by sending deltas to a ZeroVM app and process them in place. Of course you still have to read/update/write the file, but you can do it in place. You don't need to pipe the entire file over the network, which could/would be costly for large files.

Disclaimer: I also work for Rackspace, and I work on ZeroVM for my day job.



来源:https://stackoverflow.com/questions/22549648/can-i-append-or-overwrite-some-bytes-to-an-existing-object-in-openstack-swift

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!