bitsondatadev commented on code in PR #9968:
URL: https://github.com/apache/iceberg/pull/9968#discussion_r1560201975


##########
docs/docs/branching.md:
##########
@@ -49,20 +49,21 @@ Tags can be used for retaining important historical 
snapshots for auditing purpo
 The above diagram demonstrates retaining important historical snapshot with 
the following retention policy, defined 
 via Spark SQL.
 
-1. Retain 1 snapshot per week for 1 month. This can be achieved by tagging the 
weekly snapshot and setting the tag retention to be a month.
-snapshots will be kept, and the branch reference itself will be retained for 1 
week. 
+Assume snapshots are compressed to a single day before this command executes.

Review Comment:
   ```suggestion
   Consider a table that runs a daily scheduled task to compress each snapshot 
to a single day at the end of each day.
   ```
   



##########
docs/docs/branching.md:
##########
@@ -49,20 +49,21 @@ Tags can be used for retaining important historical 
snapshots for auditing purpo
 The above diagram demonstrates retaining important historical snapshot with 
the following retention policy, defined 
 via Spark SQL.
 
-1. Retain 1 snapshot per week for 1 month. This can be achieved by tagging the 
weekly snapshot and setting the tag retention to be a month.
-snapshots will be kept, and the branch reference itself will be retained for 1 
week. 
+Assume snapshots are compressed to a single day before this command executes.
+
+1. Create a tag on the snapshot occurring at the end of the first week, that 
will expire a month after it is created. You do this by setting the tag 
retention to be 30 days, or an average month. Run this command for each weekend 
to keep a weekly Snapshot.

Review Comment:
   ```suggestion
   1. Create a tag on the snapshot occurring at the end of the first week, that 
expires an average month, or 30 days, after the tag generates. This command 
illustrates tagging the end of the initial week with the tag of 'EOW-1' after 
creating the seventh daily snapshot.
   ```
   



##########
docs/docs/branching.md:
##########
@@ -49,20 +49,21 @@ Tags can be used for retaining important historical 
snapshots for auditing purpo
 The above diagram demonstrates retaining important historical snapshot with 
the following retention policy, defined 
 via Spark SQL.
 
-1. Retain 1 snapshot per week for 1 month. This can be achieved by tagging the 
weekly snapshot and setting the tag retention to be a month.
-snapshots will be kept, and the branch reference itself will be retained for 1 
week. 
+Assume snapshots are compressed to a single day before this command executes.
+
+1. Create a tag on the snapshot occurring at the end of the first week, that 
will expire a month after it is created. You do this by setting the tag 
retention to be 30 days, or an average month. Run this command for each weekend 
to keep a weekly Snapshot.
 ```sql
--- Create a tag for the first end of week snapshot. Retain the snapshot for a 
week
-ALTER TABLE prod.db.table CREATE TAG `EOW-01` AS OF VERSION 7 RETAIN 7 DAYS;
+-- Create a tag for the first end of week snapshot. Retain the snapshot for a 
month
+ALTER TABLE prod.db.table CREATE TAG `EOW-01` AS OF VERSION 7 RETAIN 30 DAYS;
 ```
 
-2. Retain 1 snapshot per month for 6 months. This can be achieved by tagging 
the monthly snapshot and setting the tag retention to be 6 months.
+2. Create a tag on the snapshot occurring at the end of the first month, that 
will expire three months after it is created. You do this by setting the tag 
retention to be 180 days, or an average 3 months. Run this command for each 
month to keep a monthly Snapshot.

Review Comment:
   ```suggestion
   2. Create a tag on the snapshot occurring at the end of the first month, 
that expires three months after it is created. You do this by setting the tag 
retention to be 90 days, or an average 3 months. Run this command for each 
month to keep a monthly Snapshot.
   ```
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to