Skip to content

Instantly share code, notes, and snippets.

@scottmarlow
scottmarlow / gist:053c02cde97c3f86be72c8d58ab9bf19
Created September 4, 2025 13:29
surefirebooterthreaddump.txt main thread
"main" #1 prio=5 os_prio=0 cpu=6045.97ms elapsed=70749.70s tid=0x00007f1a30029ee0 nid=0x132f waiting on condition [0x00007f1a37ff9000]
java.lang.Thread.State: WAITING (parking)
at jdk.internal.misc.Unsafe.park(java.base@17.0.15/Native Method)
- parking to wait for <0x00000000c7d70560> (a java.util.concurrent.CompletableFuture$Signaller)
at java.util.concurrent.locks.LockSupport.park(java.base@17.0.15/LockSupport.java:211)
at java.util.concurrent.CompletableFuture$Signaller.block(java.base@17.0.15/CompletableFuture.java:1864)
at java.util.concurrent.ForkJoinPool.unmanagedBlock(java.base@17.0.15/ForkJoinPool.java:3465)
at java.util.concurrent.ForkJoinPool.managedBlock(java.base@17.0.15/ForkJoinPool.java:3436)
at java.util.concurrent.CompletableFuture.waitingGet(java.base@17.0.15/CompletableFuture.java:1898)
at java.util.concurrent.CompletableFuture.get(java.base@17.0.15/CompletableFuture.java:2072)
@scottmarlow
scottmarlow / gist:260727bf6141c182326ae725d2edd5da
Last active September 4, 2025 13:25
WildFly Preview server.log contents for jakartaee-tck-runners/jakarta-ee-tck-runners/rest-platform-tck seems stuck after running for 19+ hours
2025-09-03 13:40:19,143 INFO [org.jboss.resteasy.resteasy_jaxrs.i18n] (ServerService Thread Pool -- 31) RESTEASY002225: Deploying jakarta.ws.rs.core.Application: class com.sun.ts.tests.jaxrs.platform.container.asyncejb.TSAppConfig
2025-09-03 13:40:19,144 INFO [org.jboss.resteasy.resteasy_jaxrs.i18n] (ServerService Thread Pool -- 31) RESTEASY002205: Adding provider class com.sun.ts.tests.jaxrs.common.provider.PrintingErrorHandler from Application class com.sun.ts.tests.jaxrs.platform.container.asyncejb.TSAppConfig
2025-09-03 13:40:19,145 INFO [org.jboss.resteasy.resteasy_jaxrs.i18n] (ServerService Thread Pool -- 31) RESTEASY002200: Adding class resource com.sun.ts.tests.jaxrs.platform.container.asyncejb.Resource from Application class com.sun.ts.tests.jaxrs.platform.container.asyncejb.TSAppConfig
2025-09-03 13:40:19,171 INFO [org.wildfly.extension.undertow] (ServerService Thread Pool -- 31) WFLYUT0021: Registered web context: '/jaxrs_platform_container_asyncejb_web' for server 'default-server'
2025-09-03 1
[INFO] Running ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest
[ERROR] Tests run: 3, Failures: 0, Errors: 3, Skipped: 0, Time elapsed: 3.930 s <<< FAILURE! -- in ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest
[ERROR] ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest.injectUtilitiesUsingQualifier -- Time elapsed: 0.019 s <<< ERROR!
java.lang.RuntimeException: java.lang.ClassNotFoundException: Provider for jakarta.ws.rs.client.ClientBuilder cannot be found
at jakarta.ws.rs.client.ClientBuilder.newBuilder(ClientBuilder.java:75)
at ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest.injectUtilitiesUsingQualifier(ServletEMLookupTest.java:124)
at java.base/java.lang.reflect.Method.invoke(Method.java:569)
at org.jboss.arquillian.junit5.ArquillianExtension$1.invoke(ArquillianExtension.java:284)
at org.jboss.arquillian.container.test.impl.execution.LocalTestExecuter.execute(LocalTestExecuter.java:57)
at java.base/java.lang.reflect.Method.invoke(Method.
@scottmarlow
scottmarlow / gist:192cf33e09cbe312559421a0f9aacf3b
Created July 28, 2025 18:07
WELD-001475: The following beans match by type, but none have matching qualifiers: - Configurator Bean [interface jakarta.persistence.EntityManagerFactory, types: Object, EntityManagerFactory, AutoCloseable, qualifiers: @Any @CtsEmQualifier] "}}}}
[INFO] Running ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.338 s <<< FAILURE! -- in ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest
[ERROR] ee.jakarta.tck.persistence.ee.cdi.ServletEMLookupTest -- Time elapsed: 0.338 s <<< ERROR!
org.jboss.arquillian.container.spi.client.container.DeploymentException:
Cannot deploy 219590b4-f818-4e57-bed5-5d9fe19bb2be.war: {"WFLYCTL0062: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-1" => {"WFLYCTL0080: Failed services" => {"jboss.deployment.unit.\"219590b4-f818-4e57-bed5-5d9fe19bb2be.war\".WeldStartService" => "Failed to start service
Caused by: org.jboss.weld.exceptions.DeploymentException: WELD-001408: Unsatisfied dependencies for type EntityManagerFactory with qualifiers @CtsEm2Qualifier
at injection point [BackedAnnotatedField] @Inject @CtsEm2Qualifier private ee.jakarta.tck.persistence.ee.cdi.TestBeanEM.entityManagerFactory2
at ee.
2025-07-23 10:04:36,165 INFO [org.jboss.modules] (main) JBoss Modules version 2.1.6.Final
2025-07-23 10:04:36,374 INFO [org.jboss.msc] (main) JBoss MSC version 1.5.6.Final
2025-07-23 10:04:36,378 INFO [org.jboss.threads] (main) JBoss Threads version 3.9.1
2025-07-23 10:04:36,429 INFO [org.jboss.as] (MSC service thread 1-3) WFLYSRV0049: WildFly 37.0.0.Final-SNAPSHOT (WildFly Core 29.0.0.Beta6) starting
2025-07-23 10:04:36,430 DEBUG [org.jboss.as.config] (MSC service thread 1-3) Configured system properties:
[Standalone] =
file.encoding = UTF-8
file.separator = /
java.awt.headless = true
java.class.path = /home/smarlow/work/wildfly/dist/target/wildfly-37.0.0.Final-SNAPSHOT/jboss-modules.jar
@scottmarlow
scottmarlow / gist:eba75649528d4c1262eabb6a71c80fc7
Created July 18, 2025 19:59
https://github.com/scottmarlow/wildfly/tree/WFLY-19554_cdijpa32_six test fails with org.jboss.weld.contexts.ContextNotActiveException: WELD-001303: No active contexts for scope type jakarta.transaction.TransactionScoped
[INFO] Running org.jboss.as.test.integration.jpa.cdi.CDIPersistenceTestCase
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 5.455 s <<< FAILURE! -- in org.jboss.as.test.integration.jpa.cdi.CDIPersistenceTestCase
[ERROR] org.jboss.as.test.integration.jpa.cdi.CDIPersistenceTestCase.doCMTTest -- Time elapsed: 0.247 s <<< ERROR!
jakarta.ejb.EJBException: org.jboss.weld.contexts.ContextNotActiveException: WELD-001303: No active contexts for scope type jakarta.transaction.TransactionScoped
at org.jboss.as.ejb3@37.0.0.Final-SNAPSHOT//org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInNoTx(CMTTxInterceptor.java:222)
at org.jboss.as.ejb3@37.0.0.Final-SNAPSHOT//org.jboss.as.ejb3.tx.CMTTxInterceptor.never(CMTTxInterceptor.java:338)
at org.jboss.as.ejb3@37.0.0.Final-SNAPSHOT//org.jboss.as.ejb3.tx.CMTTxInterceptor.processInvocation(CMTTxInterceptor.java:130)
at org.jboss.invocation@2.0.1.Final//org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:422)
Application improvements using transactions that are marked STATUS_MARKED_ROLLBACK in that the application was actually using a transaction but application was treated as if didn't have an active transaction:
1. TransactionScopedEntityManager.isInTx() (org.jboss.as.jpa.container) calls to TransactionUtil.isInTx(TransactionManager) (org.jboss.as.jpa.transaction)
AbstractEntityManager.detachQueryNonTxInvocation(EntityManager, Query) (org.jboss.as.jpa.container)
!this.isInTx() check so we changed from if ! (tx.getStatus() == Status.STATUS_ACTIVE) to if ! (tx.getStatus() == Status.STATUS_ACTIVE || tx.getStatus() == Status.STATUS_MARKED_ROLLBACK)
I think that this change is more correct for the STATUS_MARKED_ROLLBACK case.
// used by TransactionScopedEntityManager to detach entities loaded by a query in a non-Jakarta Transactions invocation.
Previously if transaction is STATUS_MARKED_ROLLBACK we would of treated that as non-active transaction and we would of cleared persistence context after query.getResu
@scottmarlow
scottmarlow / gist:13ce48bfda9a0556bb43653aa8acfc97
Created June 16, 2025 20:56
hackretryloadingdefiningloop.java
diff --git a/hibernate-core/src/main/java/org/hibernate/bytecode/internal/bytebuddy/ByteBuddyState.java b/hibernate-core/src/main/java/org/hibernate/bytecode/internal/bytebuddy/ByteBuddyState.java
index 2bdfb646bf..613604561c 100644
--- a/hibernate-core/src/main/java/org/hibernate/bytecode/internal/bytebuddy/ByteBuddyState.java
+++ b/hibernate-core/src/main/java/org/hibernate/bytecode/internal/bytebuddy/ByteBuddyState.java
@@ -237,22 +237,25 @@ public final class ByteBuddyState {
catch (ClassNotFoundException e) {
// Ignore
}
- try {
- return make( makeClassFunction.apply( byteBuddy, new FixedNamingStrategy( className ) ) )
load:217, ByteBuddyState (org.hibernate.bytecode.internal.bytebuddy)
loadProxy:133, ByteBuddyState (org.hibernate.bytecode.internal.bytebuddy)
buildProxy:57, ByteBuddyProxyHelper (org.hibernate.proxy.pojo.bytebuddy)
postInstantiate:56, ByteBuddyProxyFactory (org.hibernate.proxy.pojo.bytebuddy)
createProxyFactory:280, EntityRepresentationStrategyPojoStandard (org.hibernate.metamodel.internal)
resolveProxyFactory:169, EntityRepresentationStrategyPojoStandard (org.hibernate.metamodel.internal)
<init>:135, EntityRepresentationStrategyPojoStandard (org.hibernate.metamodel.internal)
resolveStrategy:48, ManagedTypeRepresentationResolverStandard (org.hibernate.metamodel.internal)
<init>:517, AbstractEntityPersister (org.hibernate.persister.entity)
<init>:116, SingleTableEntityPersister (org.hibernate.persister.entity)
public Class<?> load(Class<?> referenceClass, String className, BiFunction<ByteBuddy, NamingStrategy, DynamicType.Builder<?>> makeClassFunction) {
if (result.getClassLoader() == referenceClass.getClassLoader()) {
try {
return referenceClass.getClassLoader().loadClass(className);
}
catch (ClassNotFoundException e) {
// Ignore
}