Skip to content

Commit

Permalink
Update loglevel to verbose (#7960)
Browse files Browse the repository at this point in the history
  • Loading branch information
srnagar authored Feb 4, 2020
1 parent f519d2c commit bd08c09
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ private <T> Flux<T> listBlobs(String prefix, Function<BlobItem, Mono<T>> convert

private Mono<Checkpoint> convertToCheckpoint(BlobItem blobItem) {
String[] names = blobItem.getName().split(BLOB_PATH_SEPARATOR);
logger.info(Messages.FOUND_BLOB_FOR_PARTITION, blobItem.getName());
logger.verbose(Messages.FOUND_BLOB_FOR_PARTITION, blobItem.getName());
if (names.length == 5) {
// Blob names should be of the pattern
// fullyqualifiednamespace/eventhub/consumergroup/checkpoints/<partitionId>
Expand All @@ -110,7 +110,7 @@ private Mono<Checkpoint> convertToCheckpoint(BlobItem blobItem) {
}

Map<String, String> metadata = blobItem.getMetadata();
logger.info(Messages.CHECKPOINT_INFO, blobItem.getName(), metadata.get(SEQUENCE_NUMBER),
logger.verbose(Messages.CHECKPOINT_INFO, blobItem.getName(), metadata.get(SEQUENCE_NUMBER),
metadata.get(OFFSET));

Long sequenceNumber = null;
Expand Down Expand Up @@ -171,15 +171,15 @@ public Flux<PartitionOwnership> claimOwnership(List<PartitionOwnership> requeste
.uploadWithResponse(Flux.just(UPLOAD_DATA), 0, null, metadata, null, null,
blobRequestConditions)
.flatMapMany(response -> updateOwnershipETag(response, partitionOwnership), error -> {
logger.info(Messages.CLAIM_ERROR, partitionId, error.getMessage());
logger.verbose(Messages.CLAIM_ERROR, partitionId, error.getMessage());
return Mono.empty();
}, Mono::empty);
} else {
// update existing blob
blobRequestConditions.setIfMatch(partitionOwnership.getETag());
return blobAsyncClient.setMetadataWithResponse(metadata, blobRequestConditions)
.flatMapMany(response -> updateOwnershipETag(response, partitionOwnership), error -> {
logger.info(Messages.CLAIM_ERROR, partitionId, error);
logger.verbose(Messages.CLAIM_ERROR, partitionId, error);
return Mono.empty();
}, Mono::empty);
}
Expand Down Expand Up @@ -247,7 +247,7 @@ private String getBlobName(String fullyQualifiedNamespace, String eventHubName,
}

private Mono<PartitionOwnership> convertToPartitionOwnership(BlobItem blobItem) {
logger.info(Messages.FOUND_BLOB_FOR_PARTITION, blobItem.getName());
logger.verbose(Messages.FOUND_BLOB_FOR_PARTITION, blobItem.getName());
String[] names = blobItem.getName().split(BLOB_PATH_SEPARATOR);
if (names.length == 5) {
// Blob names should be of the pattern
Expand All @@ -258,7 +258,7 @@ private Mono<PartitionOwnership> convertToPartitionOwnership(BlobItem blobItem)
return Mono.empty();
}
logger
.info(Messages.BLOB_OWNER_INFO, blobItem.getName(),
.verbose(Messages.BLOB_OWNER_INFO, blobItem.getName(),
blobItem.getMetadata().getOrDefault(OWNER_ID, EMPTY_STRING));

BlobItemProperties blobProperties = blobItem.getProperties();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,6 @@ public class EventProcessorClient {
private final String eventHubName;
private final String consumerGroup;



/**
* Package-private constructor. Use {@link EventHubClientBuilder} to create an instance.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ void stopAllPartitionPumps() {
*/
void startPartitionPump(PartitionOwnership claimedOwnership, Checkpoint checkpoint) {
if (partitionPumps.containsKey(claimedOwnership.getPartitionId())) {
logger.info("Consumer is already running for this partition {}", claimedOwnership.getPartitionId());
logger.verbose("Consumer is already running for this partition {}", claimedOwnership.getPartitionId());
return;
}

Expand Down

0 comments on commit bd08c09

Please sign in to comment.