-
Bug
-
Resolution: Done
-
Major
-
None
-
None
While trying out tracing enable/disable functionality over Console (using latest server image with main tag and console main branch), I have faced the following 2 issue:
1) There is cache `people` with following configuration:
<distributed-cache name="people" statistics="true"> <transaction mode="NON_XA"/> <encoding media-type="application/x-protostream"/> </distributed-cache>
When trying to add tracing categories in "Manage tracing" page, I am getting error message in popup window (see screenshot) , even though there is no exception in the logs. After that it is not possible to access people cache over console (REST call returns 500 Internal error) and I am getting exception in the logs:
2024-09-26 08:59:15,447 ERROR [o.i.r.RestRequestHandler] ISPN012005: An error occurred while responding to the client java.lang.NullPointerException at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197) at java.base/java.util.Iterator.forEachRemaining(Iterator.java:133) at java.base/java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1939) at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509) at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499) at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921) at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:682) at org.infinispan.commons.configuration.attributes.AttributeSerializer.lambda$static$4(AttributeSerializer.java:32) at org.infinispan.commons.configuration.attributes.Attribute.write(Attribute.java:309) at org.infinispan.commons.configuration.attributes.AttributeSet.write(AttributeSet.java:310) at org.infinispan.commons.configuration.attributes.AttributeSet.write(AttributeSet.java:266) at org.infinispan.commons.configuration.attributes.AttributeSet.write(AttributeSet.java:277) at org.infinispan.configuration.serializing.CoreConfigurationSerializer.writeTracing(CoreConfigurationSerializer.java:765) at org.infinispan.configuration.serializing.CoreConfigurationSerializer.writeCommonCacheAttributesElements(CoreConfigurationSerializer.java:643) at org.infinispan.configuration.serializing.CoreConfigurationSerializer.writeDistributedCache(CoreConfigurationSerializer.java:454) at org.infinispan.configuration.serializing.CoreConfigurationSerializer.writeCache(CoreConfigurationSerializer.java:292) at org.infinispan.configuration.parsing.ParserRegistry.serialize(ParserRegistry.java:343) at org.infinispan.rest.resources.CacheResourceV2.getCacheConfig(CacheResourceV2.java:1009) at org.infinispan.security.Security.doAs(Security.java:114) at org.infinispan.rest.framework.impl.RestDispatcherImpl.dispatch(RestDispatcherImpl.java:83) at org.infinispan.rest.RestRequestHandler.handleRestRequest(RestRequestHandler.java:208) at org.infinispan.rest.RestRequestHandler.lambda$channelRead0$1(RestRequestHandler.java:187) at java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:863) at java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:841) at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:510) at java.base/java.util.concurrent.CompletableFuture.postFire(CompletableFuture.java:614) at java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:844) at java.base/java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:482) at io.netty.util.concurrent.AbstractEventExecutor.runTask(AbstractEventExecutor.java:173) at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:166) at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:470) at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:405) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at java.base/java.lang.Thread.run(Thread.java:1583)
2) When the cache is secured, e.g.
<?xml version="1.0"?> <distributed-cache name="a-rbac-test-cache" mode="SYNC" statistics="true"> <encoding media-type="application/x-protostream"/> <memory storage="HEAP" max-size="1.5GB"/> <persistence passivation="false"> <file-store> <data path="data"/> <index path="index"/> </file-store> </persistence> <indexing enabled="true" startup-mode="REINDEX"> <index-reader/> <indexed-entities> <indexed-entity>org.infinispan.Car</indexed-entity> </indexed-entities> </indexing> <security> <authorization enabled="true" roles="application admin deployer"/> </security> </distributed-cache>
and I am trying to add tracing categories, I am getting error popup: `Unauthorized action` (no exception in the logs).
Please find attached screenshots for both issues below.