Skip to content

Commit

Permalink
[branch-3.3] Bump pulsar 3.3.0.2 (#1261)
Browse files Browse the repository at this point in the history
  • Loading branch information
gaoran10 authored Jun 12, 2024
1 parent 0d6d81d commit 985d291
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public void addComplete(Position position, ByteBuf entryData, Object ctx) {
log.debug("[{}] Success to write entry with position {}.", topic.getName(), position);
}
topic.recordAddLatency(System.nanoTime() - context.startTimeNs, TimeUnit.MICROSECONDS);
topic.getTransactionBuffer().syncMaxReadPositionForNormalPublish((PositionImpl) position);
topic.getTransactionBuffer().syncMaxReadPositionForNormalPublish((PositionImpl) position, false);
context.positionFuture.complete(position);
context.recycle();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
import java.util.List;
import java.util.Map;
import java.util.Optional;
import java.util.concurrent.CompletableFuture;
import java.util.function.Supplier;
import lombok.Getter;
import lombok.extern.slf4j.Slf4j;
Expand Down Expand Up @@ -204,21 +205,21 @@ public void reallyShutdown() {
private final BookKeeperClientFactory mockBookKeeperClientFactory = new BookKeeperClientFactory() {

@Override
public BookKeeper create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties) {
public CompletableFuture<BookKeeper> create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties) {
// Always return the same instance (so that we don't loose the mock BK content on broker restart
return mockBookKeeper;
return CompletableFuture.completedFuture(mockBookKeeper);
}

@Override
public BookKeeper create(ServiceConfiguration conf, MetadataStoreExtended store,
public CompletableFuture<BookKeeper> create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties, StatsLogger statsLogger) {
// Always return the same instance (so that we don't loose the mock BK content on broker restart
return mockBookKeeper;
return CompletableFuture.completedFuture(mockBookKeeper);
}

@Override
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
<project.compiler.release>${maven.compiler.target}</project.compiler.release>

<!-- dependencies -->
<pulsar.version>3.3.0-SNAPSHOT</pulsar.version>
<pulsar.version>3.3.0.2</pulsar.version>
<qpid-protocol-plugin.version>8.0.0</qpid-protocol-plugin.version>
<rabbitmq.version>5.8.0</rabbitmq.version>

Expand Down Expand Up @@ -386,7 +386,7 @@
</repository>
<repository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/service/local/repositories/iostreamnative-3095/content</url>
<url>https://s01.oss.sonatype.org/service/local/repositories/iostreamnative-3155/content</url>
</repository>
</repositories>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
import java.util.List;
import java.util.Map;
import java.util.Optional;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ThreadLocalRandom;
import java.util.concurrent.TimeUnit;
import java.util.function.Predicate;
Expand Down Expand Up @@ -332,21 +333,21 @@ public void reallyShutdown() {
private final BookKeeperClientFactory mockBookKeeperClientFactory = new BookKeeperClientFactory() {

@Override
public BookKeeper create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties) {
public CompletableFuture<BookKeeper> create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties) {
// Always return the same instance (so that we don't loose the mock BK content on broker restart
return mockBookKeeper;
return CompletableFuture.completedFuture(mockBookKeeper);
}

@Override
public BookKeeper create(ServiceConfiguration conf, MetadataStoreExtended store,
public CompletableFuture<BookKeeper> create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties, StatsLogger statsLogger) {
// Always return the same instance (so that we don't loose the mock BK content on broker restart
return mockBookKeeper;
return CompletableFuture.completedFuture(mockBookKeeper);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import java.util.List;
import java.util.Map;
import java.util.Optional;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ThreadLocalRandom;
import java.util.concurrent.TimeUnit;
import java.util.function.Predicate;
Expand Down Expand Up @@ -359,21 +360,21 @@ public void reallyShutdown() {
private final BookKeeperClientFactory mockBookKeeperClientFactory = new BookKeeperClientFactory() {

@Override
public BookKeeper create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties) {
public CompletableFuture<BookKeeper> create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties) {
// Always return the same instance (so that we don't loose the mock BK content on broker restart
return mockBookKeeper;
return CompletableFuture.completedFuture(mockBookKeeper);
}

@Override
public BookKeeper create(ServiceConfiguration conf, MetadataStoreExtended store,
public CompletableFuture<BookKeeper> create(ServiceConfiguration conf, MetadataStoreExtended store,
EventLoopGroup eventLoopGroup,
Optional<Class<? extends EnsemblePlacementPolicy>> ensemblePlacementPolicyClass,
Map<String, Object> properties, StatsLogger statsLogger) {
// Always return the same instance (so that we don't loose the mock BK content on broker restart
return mockBookKeeper;
return CompletableFuture.completedFuture(mockBookKeeper);
}

@Override
Expand Down

0 comments on commit 985d291

Please sign in to comment.