Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion dependencyManagement/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ val DEPENDENCY_BOMS = listOf(

val autoServiceVersion = "1.1.1"
val autoValueVersion = "1.11.0"
val errorProneVersion = "2.38.0"
val errorProneVersion = "2.39.0"
val byteBuddyVersion = "1.17.6"
val asmVersion = "9.8"
val jmhVersion = "1.37"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,33 +99,39 @@ String getQueueArn(String queueUrl) {
}

void setTopicPublishingPolicy(String topicArn) {
String snsPolicy =
"{"
+ " \"Statement\": ["
+ " {"
+ " \"Effect\": \"Allow\","
+ " \"Principal\": \"*\","
+ " \"Action\": \"sns:Publish\","
+ " \"Resource\": \"%s\""
+ " }]"
+ "}";
snsClient.setTopicAttributes(
new SetTopicAttributesRequest(topicArn, "Policy", String.format(snsPolicy, topicArn)));
new SetTopicAttributesRequest(
topicArn,
"Policy",
String.format(
"{"
+ " \"Statement\": ["
+ " {"
+ " \"Effect\": \"Allow\","
+ " \"Principal\": \"*\","
+ " \"Action\": \"sns:Publish\","
+ " \"Resource\": \"%s\""
+ " }]"
+ "}",
topicArn)));
}

void setQueuePublishingPolicy(String queueUrl, String queueArn) {
String sqsPolicy =
"{"
+ " \"Statement\": ["
+ " {"
+ " \"Effect\": \"Allow\","
+ " \"Principal\": \"*\","
+ " \"Action\": \"sqs:SendMessage\","
+ " \"Resource\": \"%s\""
+ " }]"
+ "}";
sqsClient.setQueueAttributes(
queueUrl, Collections.singletonMap("Policy", String.format(sqsPolicy, queueArn)));
queueUrl,
Collections.singletonMap(
"Policy",
String.format(
"{"
+ " \"Statement\": ["
+ " {"
+ " \"Effect\": \"Allow\","
+ " \"Principal\": \"*\","
+ " \"Action\": \"sqs:SendMessage\","
+ " \"Resource\": \"%s\""
+ " }]"
+ "}",
queueArn)));
}

void createBucket(String bucketName) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public void beforeRequest(Request<?> request) {
Context context = InstrumenterUtil.suppressSpan(instrumenter, parentContext, request);
context = context.with(REQUEST_TIMER_KEY, Timer.start());
context = context.with(PARENT_CONTEXT_KEY, parentContext);
context = context.with(REQUEST_SPAN_SUPPRESSED_KEY, Boolean.TRUE);
context = context.with(REQUEST_SPAN_SUPPRESSED_KEY, true);
request.addHandlerContext(CONTEXT, context);
return;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ static void setUp(@TempDir File esWorkingDir) {
new ClusterUpdateSettingsRequest()
.transientSettings(
Collections.singletonMap(
"cluster.routing.allocation.disk.threshold_enabled", Boolean.FALSE)));
"cluster.routing.allocation.disk.threshold_enabled", false)));
});
testing.waitForTraces(1);
testing.clearData();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ static void setUp(@TempDir File esWorkingDir) {
new ClusterUpdateSettingsRequest()
.transientSettings(
Collections.singletonMap(
"cluster.routing.allocation.disk.threshold_enabled", Boolean.FALSE)));
"cluster.routing.allocation.disk.threshold_enabled", false)));
});
testing.waitForTraces(1);
testing.clearData();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Node elasticSearchNode() throws Exception {
new ClusterUpdateSettingsRequest()
.transientSettings(
Collections.singletonMap(
"cluster.routing.allocation.disk.threshold_enabled", Boolean.FALSE)));
"cluster.routing.allocation.disk.threshold_enabled", false)));

return testNode;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ static void setUp(@TempDir File esWorkingDir) {
new ClusterUpdateSettingsRequest()
.transientSettings(
Collections.singletonMap(
"cluster.routing.allocation.disk.threshold_enabled", Boolean.FALSE)));
"cluster.routing.allocation.disk.threshold_enabled", false)));
});
testing.waitForTraces(1);
testing.clearData();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ void setUp(@TempDir File esWorkingDir) {
new ClusterUpdateSettingsRequest()
.transientSettings(
Collections.singletonMap(
"cluster.routing.allocation.disk.threshold_enabled", Boolean.FALSE)));
"cluster.routing.allocation.disk.threshold_enabled", false)));
});
testing.waitForTraces(1);
testing.clearData();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ void setUp(@TempDir File esWorkingDir) {
new ClusterUpdateSettingsRequest()
.transientSettings(
Collections.singletonMap(
"cluster.routing.allocation.disk.threshold_enabled", Boolean.FALSE)));
"cluster.routing.allocation.disk.threshold_enabled", false)));
});
testing.waitForTraces(1);
testing.clearData();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public final class ExecutorAdviceHelper {
* to re-enable the propagation.
*/
public static void disablePropagation() {
propagationDisabled.set(Boolean.TRUE);
propagationDisabled.set(true);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public void transform(TypeTransformer transformer) {
public static class CallLogRawAdvice {
@Advice.OnMethodEnter(suppress = Throwable.class)
public static void methodEnter(
@Advice.This() Logger logger,
@Advice.This Logger logger,
@Advice.Argument(0) ExtLogRecord record,
@Advice.Local("otelCallDepth") CallDepth callDepth) {
// need to track call depth across all loggers in order to avoid double capture when one
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,8 @@ void testCaptureAttributeArray() {

assertThat(builder.build())
.containsOnly(
entry(AttributeKey.booleanArrayKey("booleanArray"), singletonList(Boolean.TRUE)),
entry(AttributeKey.booleanArrayKey("BooleanArray"), singletonList(Boolean.TRUE)),
entry(AttributeKey.booleanArrayKey("booleanArray"), singletonList(true)),
entry(AttributeKey.booleanArrayKey("BooleanArray"), singletonList(true)),
entry(AttributeKey.longArrayKey("byteArray"), singletonList(2L)),
entry(AttributeKey.longArrayKey("ByteArray"), singletonList(2L)),
entry(AttributeKey.longArrayKey("shortArray"), singletonList(2L)),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ private MessageListenerContext() {}

/** Call on entry to a method that will pass the received message to a message listener. */
public static void startProcessing() {
processing.set(Boolean.TRUE);
processing.set(true);
}

public static void endProcessing() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public void doFilter(
ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain)
throws IOException, ServletException {
if (servletRequest.getAttribute("firstFilterCalled") != null) {
servletRequest.setAttribute("testFilterCalled", Boolean.TRUE);
servletRequest.setAttribute("testFilterCalled", true);
filterChain.doFilter(servletRequest, servletResponse);
} else {
throw new IllegalStateException("First filter should have been called.");
Expand All @@ -75,7 +75,7 @@ public void init(FilterConfig filterConfig) {}
public void doFilter(
ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain)
throws IOException, ServletException {
servletRequest.setAttribute("firstFilterCalled", Boolean.TRUE);
servletRequest.setAttribute("firstFilterCalled", true);
filterChain.doFilter(servletRequest, servletResponse);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public void doFilter(
ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain)
throws IOException, ServletException {
if (servletRequest.getAttribute("firstFilterCalled") != null) {
servletRequest.setAttribute("testFilterCalled", Boolean.TRUE);
servletRequest.setAttribute("testFilterCalled", true);
filterChain.doFilter(servletRequest, servletResponse);
} else {
throw new IllegalStateException("First filter should have been called.");
Expand All @@ -75,7 +75,7 @@ public void init(FilterConfig filterConfig) {}
public void doFilter(
ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain)
throws IOException, ServletException {
servletRequest.setAttribute("firstFilterCalled", Boolean.TRUE);
servletRequest.setAttribute("firstFilterCalled", true);
filterChain.doFilter(servletRequest, servletResponse);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public final class TwilioAsyncMarker {
ContextKey.named("opentelemetry-instrumentation-twilio-async-marker");

public static Context markAsync(Context context) {
return context.with(MARKER_KEY, Boolean.TRUE);
return context.with(MARKER_KEY, true);
}

public static boolean isMarkedAsync(Context context) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public class VaadinSingletons {
// add context for tracking nested request handler calls
.addContextCustomizer(
(context, vaadinHandlerRequest, startAttributes) ->
context.with(REQUEST_HANDLER_CONTEXT_KEY, Boolean.TRUE))
context.with(REQUEST_HANDLER_CONTEXT_KEY, true))
.buildInstrumenter();

RPC_INSTRUMENTER =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -848,7 +848,7 @@ public AnnotationVisitor visitAnnotation(String descriptor, boolean visible) {
@Override
public void visit(String name, Object value) {
if ("inline".equals(name)) {
value = Boolean.FALSE;
value = false;
hasInline = true;
} else if ("skipOn".equals(name) && value != void.class) {
hasSkipOn = true;
Expand All @@ -859,7 +859,7 @@ public void visit(String name, Object value) {
@Override
public void visitEnd() {
if (!hasInline) {
visit("inline", Boolean.FALSE);
visit("inline", false);
}
if (context.canChangeReturnType() && hasSkipOn) {
visit("skipOnIndex", 0);
Expand Down Expand Up @@ -887,7 +887,7 @@ public AnnotationVisitor visitParameterAnnotation(
@Override
public void visit(String name, Object value) {
if ("readOnly".equals(name)) {
value = Boolean.TRUE;
value = true;
}
super.visit(name, value);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ protected TypePool.Resolution doResolve(String name) {
}

void enterLoadAnnotations() {
loadingAnnotations.set(Boolean.TRUE);
loadingAnnotations.set(true);
}

void exitLoadAnnotations() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public interface TestContainerManager {

int getTargetMappedPort(int originalPort);

@SuppressWarnings("TooManyParameters")
Consumer<OutputFrame> startTarget(
String targetImageName,
String agentPath,
Expand Down
Loading