WeakBuffer, Buffer, and BasicBuffer; WeakBuffer to avoid copies in some cases
use weakbuffer, and remove MetadataManager::Ref (referencing in .::set)