Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recompute unsafe ArrayIndexShift vallue in shaded jctools #41251

Merged
merged 1 commit into from
Jun 17, 2024

Conversation

zakkak
Copy link
Contributor

@zakkak zakkak commented Jun 17, 2024

Removes warning:

Warning: RecomputeFieldValue.ArrayIndexScale automatic substitution
failed. The automatic substitution registration was attempted because a
call to jdk.internal.misc.Unsafe.arrayIndexScale(Class) was detected in
the static initializer of
io.netty.util.internal.shaded.org.jctools.util.UnsafeLongArrayAccess. Detailed
failure reason(s): Could not determine the field where the value
produced by the call to jdk.internal.misc.Unsafe.arrayIndexScale(Class)
for the array index scale computation is stored. The call is not
directly followed by a field store or by a sign extend node followed
directly by a field store.

See https://github.com/quarkusio/quarkus/actions/runs/9544560942/job/26304099563#step:16:465

Closes Karm/mandrel-integration-tests#260

Removes warning:

```
Warning: RecomputeFieldValue.ArrayIndexScale automatic substitution
failed. The automatic substitution registration was attempted because a
call to jdk.internal.misc.Unsafe.arrayIndexScale(Class) was detected in
the static initializer of
io.netty.util.internal.shaded.org.jctools.util.UnsafeLongArrayAccess. Detailed
failure reason(s): Could not determine the field where the value
produced by the call to jdk.internal.misc.Unsafe.arrayIndexScale(Class)
for the array index scale computation is stored. The call is not
directly followed by a field store or by a sign extend node followed
directly by a field store.
```
@gsmet
Copy link
Member

gsmet commented Jun 17, 2024

@zakkak I understand this needs a backport?

@zakkak
Copy link
Contributor Author

zakkak commented Jun 17, 2024

@zakkak I understand this needs a backport?

@gsmet, I think not. The warning first appeared with #41155, so I assume before that the class was not reachable.

@jerboaa
Copy link
Contributor

jerboaa commented Jun 17, 2024

@zakkak I understand this needs a backport?

@gsmet, I think not. The warning first appeared with #41155, so I assume before that the class was not reachable.

Wasn't there a conversation about shading JCtools in netty? Is that new in the netty update?

Copy link

quarkus-bot bot commented Jun 17, 2024

Status for workflow Quarkus CI

This is the status report for running Quarkus CI on commit 91ddb6d.

✅ The latest workflow run for the pull request has completed successfully.

It should be safe to merge provided you have a look at the other checks in the summary.

You can consult the Develocity build scans.


Flaky tests - Develocity

⚙️ JVM Tests - JDK 17

📦 extensions/smallrye-reactive-messaging-kafka/deployment

io.quarkus.smallrye.reactivemessaging.kafka.deployment.dev.KafkaDevServicesDevModeTestCase.sseStream - History

  • Assertion condition defined as a Lambda expression in io.quarkus.smallrye.reactivemessaging.kafka.deployment.dev.KafkaDevServicesDevModeTestCase Expecting size of: [] to be greater than or equal to 2 but was 0 within 10 seconds. - org.awaitility.core.ConditionTimeoutException
org.awaitility.core.ConditionTimeoutException: 
Assertion condition defined as a Lambda expression in io.quarkus.smallrye.reactivemessaging.kafka.deployment.dev.KafkaDevServicesDevModeTestCase 
Expecting size of:
  []
to be greater than or equal to 2 but was 0 within 10 seconds.
	at org.awaitility.core.ConditionAwaiter.await(ConditionAwaiter.java:167)
	at org.awaitility.core.AssertionCondition.await(AssertionCondition.java:119)
	at org.awaitility.core.AssertionCondition.await(AssertionCondition.java:31)

⚙️ JVM Tests - JDK 21

📦 extensions/smallrye-reactive-messaging-kafka/deployment

io.quarkus.smallrye.reactivemessaging.kafka.deployment.dev.KafkaDevServicesDevModeTestCase.sseStream - History

  • Assertion condition defined as a Lambda expression in io.quarkus.smallrye.reactivemessaging.kafka.deployment.dev.KafkaDevServicesDevModeTestCase Expecting size of: [] to be greater than or equal to 2 but was 0 within 10 seconds. - org.awaitility.core.ConditionTimeoutException
org.awaitility.core.ConditionTimeoutException: 
Assertion condition defined as a Lambda expression in io.quarkus.smallrye.reactivemessaging.kafka.deployment.dev.KafkaDevServicesDevModeTestCase 
Expecting size of:
  []
to be greater than or equal to 2 but was 0 within 10 seconds.
	at org.awaitility.core.ConditionAwaiter.await(ConditionAwaiter.java:167)
	at org.awaitility.core.AssertionCondition.await(AssertionCondition.java:119)
	at org.awaitility.core.AssertionCondition.await(AssertionCondition.java:31)

⚙️ Native Tests - Security2

📦 integration-tests/oidc-client-wiremock

io.quarkus.it.keycloak.OidcClientInGraalITCase.testEchoAndRefreshTokensWithConcurrency - History

  • Assertion condition defined as a Lambda expression in io.quarkus.it.keycloak.OidcClientTest 1 expectation failed. Response body doesn't match expectation. Expected: "access_token_2" Actual: access_token_1 within 2 seconds. - org.awaitility.core.ConditionTimeoutException
org.awaitility.core.ConditionTimeoutException: 
Assertion condition defined as a Lambda expression in io.quarkus.it.keycloak.OidcClientTest 1 expectation failed.
Response body doesn't match expectation.
Expected: "access_token_2"
  Actual: access_token_1
 within 2 seconds.
	at org.awaitility.core.ConditionAwaiter.await(ConditionAwaiter.java:167)
	at org.awaitility.core.AssertionCondition.await(AssertionCondition.java:119)

@zakkak
Copy link
Contributor Author

zakkak commented Jun 17, 2024

@zakkak I understand this needs a backport?

@gsmet, I think not. The warning first appeared with #41155, so I assume before that the class was not reachable.

Wasn't there a conversation about shading JCtools in netty? Is that new in the netty update?

Hmmm, I don't recall what the discussion was about but jctools seems to be shaded for quite long (since 4.1.2 back in 2016) in netty netty/netty@c3abb91

@zakkak zakkak merged commit 4b7e8c2 into quarkusio:main Jun 17, 2024
52 checks passed
@zakkak zakkak deleted the 2024-06-17-netty-jctools-warning-fix branch June 17, 2024 17:46
@quarkus-bot quarkus-bot bot added this to the 3.13 - main milestone Jun 17, 2024
@jerboaa
Copy link
Contributor

jerboaa commented Jun 18, 2024

Hmmm, I don't recall what the discussion was about but jctools seems to be shaded for quite long (since 4.1.2 back in 2016) in netty netty/netty@c3abb91

Sorry, sounds like I confused some discussions. Ignore me, please.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Warning about netty's shaded jctools' usage of Unsafe
4 participants