[JBoss JIRA] (DROOLS-1197) concurrency issue when having multiple kie containers
by Mario Fusco (JIRA)
[ https://issues.jboss.org/browse/DROOLS-1197?page=com.atlassian.jira.plugi... ]
Mario Fusco resolved DROOLS-1197.
---------------------------------
Resolution: Rejected
The problem is caused by the fact that you're (implicitly) using 2 KieContainers with the same ReleaseId, while that one is supposed to be unique. This is a fixed version of your test case.
{code}
import org.junit.Test;
import org.kie.api.KieServices;
import org.kie.api.builder.KieBuilder;
import org.kie.api.builder.KieFileSystem;
import org.kie.api.builder.Message;
import org.kie.api.builder.ReleaseId;
import org.kie.api.io.KieResources;
import org.kie.api.io.Resource;
import org.kie.api.runtime.KieContainer;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.concurrent.CompletableFuture;
import static org.junit.Assert.assertEquals;
public class ConcurrencyTest {
KieContainer createContainer(String rule, int id) {
KieServices kieServices = KieServices.Factory.get();
KieResources kieResources = kieServices.getResources();
KieFileSystem kieFileSystem = kieServices.newKieFileSystem();
ReleaseId releaseId = kieServices.newReleaseId("org", "test", id + ".0");
Resource resource = kieResources.newByteArrayResource(rule.getBytes());
kieFileSystem.write("src/main/resources/rule.drl", resource);
kieFileSystem.writePomXML(getPom(releaseId));
KieBuilder kb = kieServices.newKieBuilder(kieFileSystem).buildAll();
if (kb.getResults().hasMessages(Message.Level.ERROR)) {
throw new RuntimeException("Build Errors:\n" + releaseId);
}
return kieServices.newKieContainer(releaseId);
}
String returns1 = "import java.util.List;\n" +
"\n" +
"rule \"rule1\"\n" +
"\tdialect \"mvel\"\n" +
"\twhen\n" +
"\t\tres : List( )\n" +
"\tthen\n" +
" res.add(\"1\");\n" +
"end";
String returns2 = "import java.util.List;\n" +
"\n" +
"rule \"rule1\"\n" +
"\tdialect \"mvel\"\n" +
"\twhen\n" +
"\t\tres : List( )\n" +
"\tthen\n" +
" res.add(\"1\");\n" +
" res.add(\"2\");\n" +
"end";
@Test
public void test() throws Exception {
CompletableFuture<?> f1 = CompletableFuture.runAsync(() -> {
for (int i = 0; i < 100; i++) {
List<String> res1 = new ArrayList<>();
createContainer(returns1, 1).newStatelessKieSession().execute(Arrays.asList(res1));
assertEquals(1, res1.size());
}
});
CompletableFuture<?> f2 = CompletableFuture.runAsync(() -> {
for (int i = 0; i < 100; i++) {
List<String> res2 = new ArrayList<>();
createContainer(returns2, 2).newStatelessKieSession().execute(Arrays.asList(res2));
assertEquals(2, res2.size());
}
});
f1.get();
f2.get();
}
private String getPom( ReleaseId releaseId ) {
return
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
"<project xmlns=\"http://maven.apache.org/POM/4.0.0\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n" +
" xsi:schemaLocation=\"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd\">\n" +
" <modelVersion>4.0.0</modelVersion>\n" +
"\n" +
" <groupId>" + releaseId.getGroupId() + "</groupId>\n" +
" <artifactId>" + releaseId.getArtifactId() + "</artifactId>\n" +
" <version>" + releaseId.getVersion() + "</version>\n" +
"</project>\n";
}
}
{code}
> concurrency issue when having multiple kie containers
> -----------------------------------------------------
>
> Key: DROOLS-1197
> URL: https://issues.jboss.org/browse/DROOLS-1197
> Project: Drools
> Issue Type: Bug
> Components: core engine
> Affects Versions: 6.4.0.Final
> Reporter: Viacheslav Krot
> Assignee: Mario Fusco
>
> It seems there is some bug related to concurrency when creating multiple kie containers in different threads.
> Here is a test, that runs two threads, each has a loop creating a new kie container and running rule with stateless session. I expect this usecase to work, but it fails eventually - at some point in time kie container has loaded rules other than expected.
> Is the test wrong or is there is a bug?
> {{noformat}}
> import static org.hamcrest.Matchers.hasSize;
> import static org.junit.Assert.assertThat;
> import java.util.ArrayList;
> import java.util.Arrays;
> import java.util.List;
> import java.util.concurrent.CompletableFuture;
> import org.junit.Test;
> import org.kie.api.KieServices;
> import org.kie.api.builder.KieBuilder;
> import org.kie.api.builder.KieFileSystem;
> import org.kie.api.builder.Message;
> import org.kie.api.io.KieResources;
> import org.kie.api.io.Resource;
> import org.kie.api.runtime.KieContainer;
> public class ConcurrencyTest {
> KieContainer createContainer(String rule) {
> KieServices kieServices = KieServices.Factory.get();
> KieResources kieResources = kieServices.getResources();
> KieFileSystem kieFileSystem = kieServices.newKieFileSystem();
> Resource resource = kieResources.newByteArrayResource(rule.getBytes());
> kieFileSystem.write("src/main/resources/rule.drl", resource);
> KieBuilder kb = kieServices.newKieBuilder(kieFileSystem).buildAll();
> if (kb.getResults().hasMessages(Message.Level.ERROR)) {
> throw new RuntimeException("Build Errors:\n" + kb.getResults().toString());
> }
> return kieServices.newKieContainer(kb.getKieModule().getReleaseId());
> }
> String returns1 = "import java.util.List;\n" +
> "\n" +
> "rule \"rule1\"\n" +
> "\tdialect \"mvel\"\n" +
> "\twhen\n" +
> "\t\tres : List( )\n" +
> "\tthen\n" +
> " res.add(\"1\");\n" +
> "end";
> String returns2 = "import java.util.List;\n" +
> "\n" +
> "rule \"rule1\"\n" +
> "\tdialect \"mvel\"\n" +
> "\twhen\n" +
> "\t\tres : List( )\n" +
> "\tthen\n" +
> " res.add(\"1\");\n" +
> " res.add(\"2\");\n" +
> "end";
> @Test
> public void test() throws Exception {
> CompletableFuture<?> f1 = CompletableFuture.runAsync(() -> {
> for (int i = 0; i < 100; i++) {
> List<String> res1 = new ArrayList<>();
> createContainer(returns1).newStatelessKieSession().execute(Arrays.asList(res1));
> assertThat(res1, hasSize(1));
> }
> });
> CompletableFuture<?> f2 = CompletableFuture.runAsync(() -> {
> for (int i = 0; i < 100; i++) {
> List<String> res2 = new ArrayList<>();
> createContainer(returns2).newStatelessKieSession().execute(Arrays.asList(res2));
> assertThat(res2, hasSize(2));
> }
> });
> f1.get();
> f2.get();
> }
> }
> {{noformat}}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 11 months
[JBoss JIRA] (WFLY-6670) Upgrade Infinispan to 8.2.3.Final
by Radoslav Husar (JIRA)
[ https://issues.jboss.org/browse/WFLY-6670?page=com.atlassian.jira.plugin.... ]
Radoslav Husar commented on WFLY-6670:
--------------------------------------
[~matlach] in the meantime you can surely cherry-pick that fix into Infinispan, built it and upgrade the Jar in your WildFly installation.
> Upgrade Infinispan to 8.2.3.Final
> ---------------------------------
>
> Key: WFLY-6670
> URL: https://issues.jboss.org/browse/WFLY-6670
> Project: WildFly
> Issue Type: Component Upgrade
> Components: Clustering
> Affects Versions: 10.0.0.Final
> Reporter: Mathieu Lachance
> Assignee: Paul Ferraro
>
> We are currently suffering from ISPN-4390.
> Once Infinispan 8.2.3 will be released, it should be incorporated as soon as possible to get rid of the issue.
> Thanks!
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 11 months
[JBoss JIRA] (WFLY-6670) Upgrade Infinispan to 8.2.3.Final
by Mathieu Lachance (JIRA)
Mathieu Lachance created WFLY-6670:
--------------------------------------
Summary: Upgrade Infinispan to 8.2.3.Final
Key: WFLY-6670
URL: https://issues.jboss.org/browse/WFLY-6670
Project: WildFly
Issue Type: Component Upgrade
Components: Clustering
Affects Versions: 10.0.0.Final
Reporter: Mathieu Lachance
Assignee: Paul Ferraro
We are currently suffering from ISPN-4390.
Once Infinispan 8.2.3 will be released, it should be incorporated as soon as possible to get rid of the issue.
Thanks!
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 11 months
[JBoss JIRA] (WFCORE-1575) Source files without license headers
by gil cattaneo (JIRA)
gil cattaneo created WFCORE-1575:
------------------------------------
Summary: Source files without license headers
Key: WFCORE-1575
URL: https://issues.jboss.org/browse/WFCORE-1575
Project: WildFly Core
Issue Type: Feature Request
Reporter: gil cattaneo
Hi
The following source files are without license headers:
./controller/src/main/java/org/jboss/as/controller/PersistentResourceDefinition.java
./controller/src/main/java/org/jboss/as/controller/PersistentResourceXMLDescription.java
./controller/src/main/java/org/jboss/as/controller/access/AuthorizerConfiguration.java
./controller/src/main/java/org/jboss/as/controller/operations/common/OrderedChildTypesAttachment.java
./controller/src/test/java/org/jboss/as/controller/CompositeOperationHandlerUnitTestCase.java
./controller/src/test/java/org/jboss/as/controller/ListAttributeDefinitionTestCase.java
./controller/src/test/java/org/jboss/as/controller/transform/ModelDescriptionTestCase.java
./controller/src/test/java/org/jboss/as/controller/transform/RootSubsystemResource.java
./controller/src/test/java/org/jboss/as/controller/transform/SessionDefinition.java
./core-model-test/tests/src/test/java/org/jboss/as/core/model/test/host/HostModelTestCase.java
./deployment-scanner/src/test/java/org/jboss/as/server/deployment/scanner/DeploymentScannerParsingTestCase.java
./domain-http/interface/src/main/java/org/jboss/as/domain/http/server/OperationParameter.java
./domain-http/interface/src/main/java/org/jboss/as/domain/http/server/ResourceHandlerDefinition.java
./domain-management/src/main/java/org/jboss/as/domain/management/security/password/RestrictionLevel.java
./domain-management/src/test/java/org/jboss/as/domain/management/security/adduser/PropertyPatternTestCase.java
./host-controller/src/main/java/org/jboss/as/domain/controller/operations/SyncServerStateOperationHandler.java
./host-controller/src/main/java/org/jboss/as/domain/controller/operations/deployment/SyncModelParameters.java
./host-controller/src/main/java/org/jboss/as/host/controller/operations/NativeManagementServices.java
./host-controller/src/test/java/org/jboss/as/domain/controller/operations/SyncModelServerStateTestCase.java
./io/subsystem/src/main/java/org/wildfly/extension/io/OptionList.java
./logging/src/main/java/org/jboss/as/logging/KnownModelVersion.java
./logging/src/main/java/org/jboss/as/logging/TransformerResourceDefinition.java
./logging/src/main/java/org/jboss/as/logging/logmanager/PropertySorter.java
./logging/src/main/java/org/jboss/as/logging/validators/RegexValidator.java
./model-test/src/test/java/org/jboss/as/model/test/MavenUtilTestCase.java
./patching/src/main/java/org/jboss/as/patching/cli/CandidatesProviders.java
./patching/src/main/java/org/jboss/as/patching/installation/Identity.java
./patching/src/main/java/org/jboss/as/patching/installation/InstallationManager.java
./patching/src/main/java/org/jboss/as/patching/installation/InstallationManagerImpl.java
./patching/src/main/java/org/jboss/as/patching/installation/InstallationManagerService.java
./patching/src/main/java/org/jboss/as/patching/installation/InstallationModificationImpl.java
./patching/src/main/java/org/jboss/as/patching/installation/LayersConfig.java
./patching/src/main/java/org/jboss/as/patching/installation/MutableTargetImpl.java
./patching/src/main/java/org/jboss/as/patching/runner/IdentityApplyCallback.java
./patching/src/main/java/org/jboss/as/patching/runner/IdentityPatchContext.java
./patching/src/main/java/org/jboss/as/patching/runner/IdentityPatchRunner.java
./patching/src/main/java/org/jboss/as/patching/runner/IdentityRollbackCallback.java
./patching/src/main/java/org/jboss/as/patching/runner/PatchContentProvider.java
./patching/src/main/java/org/jboss/as/patching/runner/PatchingTaskContext.java
./patching/src/main/java/org/jboss/as/patching/runner/PatchReenableJarTool.java
./platform-mbean/src/main/java/org/jboss/as/platform/mbean/ClassLoadingResourceDefinition.java
./platform-mbean/src/main/java/org/jboss/as/platform/mbean/CompilationResourceDefinition.java
./platform-mbean/src/main/java/org/jboss/as/platform/mbean/GarbageCollectorRootResourceDefinition.java
./platform-mbean/src/main/java/org/jboss/as/platform/mbean/PlatformMBeanResourceDefinition.java
./process-controller/src/main/java/org/jboss/as/process/ProcessUtils.java
./remoting/subsystem/src/main/java/org/jboss/as/remoting/HttpListenerRegistryService.java
./remoting/subsystem/src/main/java/org/jboss/as/remoting/Protocol.java
./remoting/subsystem/src/main/java/org/jboss/as/remoting/RemotingSubsystem10Parser.java
./server/src/main/java/org/jboss/as/server/GracefulShutdownService.java
./server/src/main/java/org/jboss/as/server/deployment/MountedDeploymentOverlay.java
./server/src/main/java/org/jboss/as/server/deployment/service/SecuredServiceRegistry.java
./server/src/main/java/org/jboss/as/server/moduleservice/ModuleDefinition.java
./server/src/main/java/org/jboss/as/server/moduleservice/ModuleResolvePhaseService.java
./server/src/main/java/org/jboss/as/server/operations/NativeManagementServices.java
./server/src/main/java/org/jboss/as/server/suspend/OperationListener.java
./server/src/main/java/org/jboss/as/server/suspend/ServerActivity.java
./server/src/main/java/org/jboss/as/server/suspend/ServerActivityCallback.java
./server/src/main/java/org/jboss/as/server/suspend/SuspendController.java
./subsystem-test/framework/src/main/java/org/jboss/as/subsystem/test/AbstractKernelServicesImpl.java
./subsystem-test/framework/src/main/java/org/jboss/as/subsystem/test/AbstractSubsystemTest.java
./subsystem-test/framework/src/main/java/org/jboss/as/subsystem/test/AdditionalInitialization.java
./subsystem-test/framework/src/main/java/org/jboss/as/subsystem/test/AdditionalParsers.java
./subsystem-test/framework/src/main/java/org/jboss/as/subsystem/test/KernelServices.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/extrasubsystem/subsystem/dependency/DependencySubsystemAdd.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/extrasubsystem/subsystem/dependency/DependencySubsystemExtension.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/extrasubsystem/subsystem/main/MainSubsystemAdd.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/extrasubsystem/subsystem/main/MainSubsystemExtension.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/otherservices/subsystem/OtherServicesSubsystemExtension.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/otherservices/subsystem/SubsystemAddBlank.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/otherservices/subsystem/SubsystemAddWithOtherService.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/otherservices/subsystem/SubsystemAddWithPathUserService.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/otherservices/subsystem/SubsystemAddWithSocketBindingUserService.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/simple/subsystem/SimpleSubsystemAdd.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/simple/subsystem/SimpleSubsystemDeploymentProcessor.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/simple/subsystem/SimpleSubsystemExtension.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/simple/subsystem/SimpleSubsystemRemove.java
./subsystem-test/tests/src/test/java/org/jboss/as/subsystem/test/validation/subsystem/ValidateSubsystemExtension.java
./testsuite/domain/src/test/java/org/jboss/as/test/integration/respawn/TestControllerClient.java
./testsuite/domain/src/test/java/org/jboss/as/test/integration/respawn/TestControllerUtils.java
./testsuite/manualmode/src/test/java/org/jboss/as/test/manualmode/auditlog/JmxAuditLogFieldsOfLogTestCase.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/AbstractPatchingTestCase.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/CumulativePatchingScenariosTestCase.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/MergedPatchesTestCase.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/PatchBundleTestCase.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/PatchRemoteHostUnitTestCase.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/ProductInfo.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/ResourceItem.java
./testsuite/patching/src/test/java/org/jboss/as/test/patching/util/module/Module.java
./testsuite/shared/src/main/java/org/jboss/as/test/http/Authentication.java
./testsuite/shared/src/main/java/org/jboss/as/test/integration/management/ManagementOperations.java
./testsuite/shared/src/main/java/org/jboss/as/test/integration/management/rbac/PermissionsCoverageTestUtil.java
./testsuite/shared/src/main/java/org/jboss/as/test/integration/management/util/MgmtOperationException.java
./testsuite/shared/src/main/java/org/jboss/as/test/shared/FileUtils.java
./testsuite/shared/src/main/java/org/jboss/as/test/shared/TestSuiteEnvironment.java
./testsuite/shared/src/main/java/org/wildfly/test/suspendresumeendpoint/TestSuspendServiceActivator.java
./testsuite/shared/src/main/java/org/wildfly/test/suspendresumeendpoint/TestUndertowService.java
./testsuite/src/test/xslt/changeIPAddresses.xsl
./testsuite/src/test/xslt/enableRbac.xsl
./testsuite/src/test/xslt/enableTrace.xsl
./testsuite/test-runner/src/main/java/org/wildfly/core/testrunner/Server.java
./testsuite/test-runner/src/main/java/org/wildfly/core/testrunner/ServerControl.java
./testsuite/test-runner/src/main/java/org/wildfly/core/testrunner/ServerController.java
./testsuite/test-runner/src/main/java/org/wildfly/core/testrunner/UnsuccessfulOperationException.java
./testsuite/test-runner/src/main/java/org/wildfly/core/testrunner/WildflyTestRunner.java
Please, confirm the licensing of code and/or content/s, and add license headers
https://fedoraproject.org/wiki/Packaging:LicensingGuidelines?rd=Packaging...
Thanks in advance
Regards
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 11 months
[JBoss JIRA] (WFLY-6665) clustering-web-infinispan: missing error handling when unmarshalling session
by Kamil Podlešák (JIRA)
[ https://issues.jboss.org/browse/WFLY-6665?page=com.atlassian.jira.plugin.... ]
Kamil Podlešák commented on WFLY-6665:
--------------------------------------
Thank for the reply. I fully expected WFLY-6666 to be closed without fix, I just thought it should be recorded and it will he handy as a reference (it's quite a big incentive to upgrade to 10.0.0 soon, if nothing else).
You are right, this scenario is basically "application bug" and AS is not required to handle it. Problem is that there is apparently no way to handle it at all (or at lest I don't know about any) and the "poisoned" session just remain broken.
Maybe some additional context would be helpful:
I am trying to implement automatized "seamless deployment" (also known as "zero downtime") of applications running on WildFly AS. This should be, in theory, very simple with web session clustering. In practice, however, I've run into this problem. Small incompatible change in application can cause thousands of users to be denied service. Combined with 6 hours session timeout, this effectively means "six hour downtime" = completely unacceptable. Training customers to "clear cookies or close browser" is not real solution.
Maybe I could implement some external watchdog that observes log and handles these errors by jboss-cli... but I've already tried very simple workaround by patching jboss-marshalling-river and it works like charm:
https://github.com/podlesh/jboss-marshalling/commit/ecb0d9332a3e08f662ad8...
> clustering-web-infinispan: missing error handling when unmarshalling session
> ----------------------------------------------------------------------------
>
> Key: WFLY-6665
> URL: https://issues.jboss.org/browse/WFLY-6665
> Project: WildFly
> Issue Type: Bug
> Components: Clustering
> Affects Versions: 10.0.0.Final
> Reporter: Kamil Podlešák
> Assignee: Paul Ferraro
>
> When unmarshalling of session throws _unexpected_ exception, it is not handled correctly and is propagated to undertow worker, thus causing generic http 500 error to be shown to user. Problem is that each request tries to unmarshall session again and fails... making this session completely broken (for with no recovery until session cookie expires or is removed (ie browser closed).
> Some exceptions are _expected_ and handled correctly by removing session and continuing (usually, new session is created). They are catched in MarshalledValueMarshaller.read, wrapped by InvalidSerializedFormException and then handled in CoarseSessionAttributesFactory.findValue. Expected exceptions are these:
> * java.lang.ClassNotFoundException
> * java.io.InvalidClassException
> * java.io.InvalidObjectException
> This list is sufficient in *most* of the time, but sometimes even jboss-marshalling-river throws some RuntimeException (not to mention IOException).
> Sample stacktrace (there are several possible variants):
> {noformat}
> 14:26:14,366 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (default task-1) ISPN000136: Error executing command GetKeyValueCommand, writing keys []: org.infinispan.commons.CacheListenerException: ISPN000280: Caught exception [java.lang.IllegalArgumentException] while invoking method [public void org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.activated(org.infinispan.notifications.cachelistener.event.CacheEntryActivatedEvent)] on listener instance: org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager@25e2eac0
> at org.infinispan.notifications.impl.AbstractListenerImpl$ListenerInvocationImpl$1.run(AbstractListenerImpl.java:291)
> at org.infinispan.util.concurrent.WithinThreadExecutor.execute(WithinThreadExecutor.java:21)
> at org.infinispan.notifications.impl.AbstractListenerImpl$ListenerInvocationImpl.invoke(AbstractListenerImpl.java:309)
> at org.infinispan.notifications.cachelistener.CacheNotifierImpl$BaseCacheEntryListenerInvocation.doRealInvocation(CacheNotifierImpl.java:1234)
> at org.infinispan.notifications.cachelistener.CacheNotifierImpl$BaseCacheEntryListenerInvocation.invokeNoChecks(CacheNotifierImpl.java:1229)
> at org.infinispan.notifications.cachelistener.CacheNotifierImpl$BaseCacheEntryListenerInvocation.invoke(CacheNotifierImpl.java:1206)
> at org.infinispan.notifications.cachelistener.CacheNotifierImpl.notifyCacheEntryActivated(CacheNotifierImpl.java:522)
> at org.infinispan.interceptors.ActivationInterceptor.sendNotification(ActivationInterceptor.java:33)
> at org.infinispan.interceptors.CacheLoaderInterceptor.loadInContext(CacheLoaderInterceptor.java:392)
> at org.infinispan.interceptors.CacheLoaderInterceptor.loadIfNeeded(CacheLoaderInterceptor.java:362)
> at org.infinispan.interceptors.CacheLoaderInterceptor.visitDataCommand(CacheLoaderInterceptor.java:183)
> at org.infinispan.interceptors.CacheLoaderInterceptor.visitGetKeyValueCommand(CacheLoaderInterceptor.java:137)
> at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> at org.infinispan.interceptors.EntryWrappingInterceptor.visitDataReadCommand(EntryWrappingInterceptor.java:133)
> at org.infinispan.interceptors.EntryWrappingInterceptor.visitGetKeyValueCommand(EntryWrappingInterceptor.java:123)
> at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:113)
> at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> at org.infinispan.interceptors.locking.PessimisticLockingInterceptor.visitDataReadCommand(PessimisticLockingInterceptor.java:71)
> at org.infinispan.interceptors.locking.AbstractLockingInterceptor.visitGetKeyValueCommand(AbstractLockingInterceptor.java:77)
> at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> at org.infinispan.interceptors.TxInterceptor.enlistReadAndInvokeNext(TxInterceptor.java:345)
> at org.infinispan.interceptors.TxInterceptor.visitGetKeyValueCommand(TxInterceptor.java:330)
> at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> at org.infinispan.interceptors.InvocationContextInterceptor.handleAll(InvocationContextInterceptor.java:107)
> at org.infinispan.interceptors.InvocationContextInterceptor.handleDefault(InvocationContextInterceptor.java:76)
> at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:336)
> at org.infinispan.cache.impl.CacheImpl.get(CacheImpl.java:411)
> at org.infinispan.cache.impl.CacheImpl.get(CacheImpl.java:403)
> at org.infinispan.cache.impl.AbstractDelegatingCache.get(AbstractDelegatingCache.java:286)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionMetaDataFactory.getValue(InfinispanSessionMetaDataFactory.java:92)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionMetaDataFactory.findValue(InfinispanSessionMetaDataFactory.java:69)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionMetaDataFactory.findValue(InfinispanSessionMetaDataFactory.java:39)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionFactory.findValue(InfinispanSessionFactory.java:61)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionFactory.findValue(InfinispanSessionFactory.java:40)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.findSession(InfinispanSessionManager.java:234)
> at org.wildfly.clustering.web.undertow.session.DistributableSessionManager.getSession(DistributableSessionManager.java:140)
> at io.undertow.servlet.spec.ServletContextImpl.getSession(ServletContextImpl.java:726)
> at io.undertow.servlet.spec.ServletContextImpl.getSession(ServletContextImpl.java:756)
> at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:69)
> at io.undertow.security.handlers.NotificationReceiverHandler.handleRequest(NotificationReceiverHandler.java:50)
> at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)
> at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
> at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:284)
> at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:263)
> at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:81)
> at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:174)
> at io.undertow.server.Connectors.executeRootHandler(Connectors.java:202)
> at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:793)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:745)
> Caused by: java.lang.IllegalArgumentException: always failing!
> at eu.lmc.experiment.FailingDeserialization2.readObject(FailingDeserialization2.java:36)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:497)
> at org.jboss.marshalling.reflect.SerializableClass.callReadObject(SerializableClass.java:307)
> at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1637)
> at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1285)
> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
> at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:149)
> at org.jboss.marshalling.river.BlockUnmarshaller.readObject(BlockUnmarshaller.java:135)
> at org.jboss.marshalling.MarshallerObjectInputStream.readObjectOverride(MarshallerObjectInputStream.java:53)
> at org.jboss.marshalling.river.RiverObjectInputStream.readObjectOverride(RiverObjectInputStream.java:307)
> at java.io.ObjectInputStream.readObject(ObjectInputStream.java:365)
> at java.util.HashMap.readObject(HashMap.java:1396)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:497)
> at org.jboss.marshalling.reflect.SerializableClass.callReadObject(SerializableClass.java:307)
> at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1637)
> at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1285)
> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:276)
> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209)
> at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:41)
> at org.wildfly.clustering.marshalling.jboss.SimpleMarshalledValue.get(SimpleMarshalledValue.java:101)
> at org.wildfly.clustering.marshalling.jboss.SimpleMarshalledValue.get(SimpleMarshalledValue.java:44)
> at org.wildfly.clustering.marshalling.jboss.MarshalledValueMarshaller.read(MarshalledValueMarshaller.java:45)
> at org.wildfly.clustering.marshalling.jboss.MarshalledValueMarshaller.read(MarshalledValueMarshaller.java:32)
> at org.wildfly.clustering.web.infinispan.session.coarse.CoarseSessionAttributesFactory.findValue(CoarseSessionAttributesFactory.java:84)
> at org.wildfly.clustering.web.infinispan.session.coarse.CoarseSessionAttributesFactory.findValue(CoarseSessionAttributesFactory.java:48)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionFactory.findValue(InfinispanSessionFactory.java:63)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionFactory.findValue(InfinispanSessionFactory.java:40)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.lambda$activated$24(InfinispanSessionManager.java:300)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager$$Lambda$129/153353148.run(Unknown Source)
> at org.wildfly.clustering.service.concurrent.StampedLockServiceExecutor.execute(StampedLockServiceExecutor.java:42)
> at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.activated(InfinispanSessionManager.java:297)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:497)
> at org.infinispan.notifications.impl.AbstractListenerImpl$ListenerInvocationImpl$1.run(AbstractListenerImpl.java:286)
> ... 62 more
> Caused by: an exception which occurred:
> in object of type eu.lmc.experiment.FailingDeserialization2
> in object of type java.util.HashMap
> {noformat}
> Note 1: application must be marked as "distributable" in web.xml or equivalent.
> Note 2: in 9.0.2, this bug is way more serious because handling of "expected" exceptions is completely broken and ends up in infinite recursion. So in addition to completely broken session, server logs is spammed by 40 megabytes of stacktraces per each request.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 11 months