35.11. MoveAfterRead consumer 选项
除了删除AfterRead它外,还添加了另一个选项,请 moveAfterRead。启用此选项后,消耗的对象将移到目标目标Bucket 中,而不是只删除。这将需要指定 destinationBucket 选项。例如:
from("minio://mycamelbucket?minioClient=#minioClient&moveAfterRead=true&destinationBucketName=myothercamelbucket")
.to("mock:result");
from("minio://mycamelbucket?minioClient=#minioClient&moveAfterRead=true&destinationBucketName=myothercamelbucket")
.to("mock:result");
在这种情况下,所使用的对象将移到 myothercamelbucket 存储桶并从原始对象中删除(因为 deleteAfterRead 设为 true 为默认值)。