[ 
https://issues.apache.org/jira/browse/DL-194?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15937606#comment-15937606
 ] 

Sijie Guo commented on DL-194:
------------------------------

[~xiaohaoliang] That's a good point. we should also support truncate by 
transaction id in AsyncLogWriter. 

Right now, in DistributedLogManager, 
https://github.com/apache/incubator-distributedlog/blob/master/distributedlog-core/src/main/java/org/apache/distributedlog/DistributedLogManager.java#L299
 . There indeed is a method that can do what you want. You can use it for now.

Let me know if you have any more questions.

> I want to truncate the log until "Transaction ID" (not DLSN).  How can I do ? 
> ------------------------------------------------------------------------------
>
>                 Key: DL-194
>                 URL: https://issues.apache.org/jira/browse/DL-194
>             Project: DistributedLog
>          Issue Type: Improvement
>            Reporter: xiaohao liang
>             Fix For: 0.5.0
>
>
> Now , I want to truncate the log until "Transaction ID" (not DLSN), 
> I find that :
> ```java
> DLSN truncateDLSN = ...;
> Future<DLSN> truncateFuture = writer.truncate(truncateDLSN);
> // wait for truncation result
> Await.result(truncateFuture);
> ```
> http://distributedlog.incubator.apache.org/docs/latest/user_guide/api/core.html#asynclogwriter
>  
> So,ow can I do ? 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to