[
https://issues.apache.org/jira/browse/IGNITE-11662?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Amelchev Nikita updated IGNITE-11662:
-------------------------------------
Ignite Flags: Release Notes Required
> Wrong classloader is used to unmarshal joining node data
> --------------------------------------------------------
>
> Key: IGNITE-11662
> URL: https://issues.apache.org/jira/browse/IGNITE-11662
> Project: Ignite
> Issue Type: Bug
> Affects Versions: 2.7
> Environment: Ignite 2.7
> Karaf 4.2.0
> Reporter: Oleksii Mohylin
> Assignee: Oleksii Mohylin
> Priority: Major
> Fix For: 2.13
>
> Time Spent: 40m
> Remaining Estimate: 0h
>
> When a cluster coordinator node is running in Karaf container it cannot
> accept joining requests from other nodes. Problem lies in unability to
> unmarshal joining node data in
> org.apache.ignite.internal.processors.cluster.GridClusterStateProcessor.validateNode()
> This line
> {code:java}
> joiningNodeState = marsh.unmarshal((byte[]) discoData.joiningNodeData(),
> Thread.currentThread().getContextClassLoader());{code}
> fails with
> {noformat}
> Error on unmarshalling discovery data from node
> 10.0.2.15,127.0.0.1,172.17.0.1:47501: Failed to find class with given class
> loader for unmarshalling (make sure same versions of all classes are
> available on all nodes or enable peer-class-loading)
> [clsLdr=jdk.internal.loader.ClassLoaders$AppClassLoader@5c0369c4,
> cls=org.apache.ignite.internal.processors.cluster.DiscoveryDataClusterState];
> node is not allowed to join{noformat}
> Apparently problem is wrong classloader returned by
> {code:java}
> Thread.currentThread().getContextClassLoader()){code}
> which is not the one created in IgniteAbstractOsgiContextActivator.start().
> *Proposed fix:*
> use proper way of obtaining classloader:
> {code:java}
> U.resolveClassLoader(ctx.config()){code}
> Like in other places. i.e. in GridClusterStateProcessor.collectGridNodeData().
>
>
--
This message was sent by Atlassian Jira
(v8.20.1#820001)