You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by ni...@apache.org on 2022/06/16 13:35:35 UTC

[pulsar] 01/01: [doc] Transactions: fix code samples indentantion

This is an automated email from the ASF dual-hosted git repository.

nicoloboschi pushed a commit to branch doc-trans-code-indent
in repository https://gitbox.apache.org/repos/asf/pulsar.git

commit a723d43f0fdf324c6d710b727e5e35f63a5732d9
Author: Nicolò Boschi <bo...@gmail.com>
AuthorDate: Thu Jun 16 15:35:26 2022 +0200

    [doc] Transactions: fix code samples indentantion
---
 site2/docs/txn-use.md | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/site2/docs/txn-use.md b/site2/docs/txn-use.md
index a8f21b766a5..772d6c7788b 100644
--- a/site2/docs/txn-use.md
+++ b/site2/docs/txn-use.md
@@ -69,12 +69,9 @@ This section provides an example of how to use the transaction API to send and r
    ```
    
    PulsarClient client = PulsarClient.builder()
-
-   .serviceUrl(“pulsar://localhost:6650”)
-
-   .enableTransaction(true)
-
-   .build();
+      .serviceUrl(“pulsar://localhost:6650”)
+      .enableTransaction(true)
+      .build();
    
    ```
 
@@ -100,8 +97,7 @@ Consumer<byte[]> sinkConsumer = pulsarClient
     .newConsumer()
     .topic(transferTopic)
     .subscriptionName("sink-topic")
-
-.subscriptionInitialPosition(SubscriptionInitialPosition.Earliest)
+    .subscriptionInitialPosition(SubscriptionInitialPosition.Earliest)
     .subscriptionType(SubscriptionType.Shared)
     .enableBatchIndexAcknowledgment(true) // enable batch index acknowledgement
     .subscribe();