Closed TheCelavi closed 9 years ago
Like! Even better!
Sent from my iPad
On Sep 8, 2015, at 5:20 PM, Kevin Bond notifications@github.com wrote:
I do like the system but I think we should leave the existing Destination interface as-is and add another interface called RotatingDestination which extends Destination:
It doesn't make sense to have the S3CmdDestination rotatable. I think we should have a StreamDestination and a RotatingStreamDestination. It is my opinion that most use cases will not require rotation. — Reply to this email directly or view it on GitHub.
The more I think about it, I don't even see a reason for a RotatingDestination
interface.
I'm thinking all you need is:
RotatingDestination
(abstract, implements Destination
)
RotatingStreamDestination
(extends RotatingDestination
)
Ok, all done.
If everything is fine - I have to leave you with implementation of S3CmdDestination - I do not have account to test that... sorry :(
Now, do review, and notify me when I can start to mess around with factories and integration of rotators into service container.
Thanks for your time.
Looks good except for a few CS issues, duplicated code and cleanup. I try not using the else
statement and nested for
loops if I can avoid it.
Hi guys,
Am I right that this PR will eventually enable rotations of backups? My ultimate goal is to have hourly backups over the last day, daily backups over the last week and weekly backups for anything that's older. This means that the backup command will have to clean-up some archives that exist at the destination (or each destination, if there are more than one).
Is this what's going to be possible? How soon are you planning to roll out the change?
I'm currently choosing between kbond/ZenstruckBackupBundle and dizda/CloudBackupBundle, your answer will help a lot with the decision.
@kachkaev I believe this PR will enable what you desire. @TheCelavi would be able to better answer though.
@TheCelavi I am in the process of moving the backup specific stuff to it's own repo (https://github.com/kbond/php-backup). When I have some time, I can try my hand at migrating what you have done here over.
Hi, I am sorry, I have some much stuff on my plate right now so I am not in the position to dedicate the time to this topic right now, sorry. :(
You have the code, so if you want you can adjust it to your needs, I am going to close the PR since I do not have time right now to handle it.
I do like the system but I think we should leave the existing
Destination
interface as-is and add another interface calledRotatingDestination
which extendsDestination
:S3CmdDestination
rotatable.StreamDestination
and aRotatingStreamDestination
. It is my opinion that most use cases will not require rotation.