ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djm132 <dobermann...@gmail.com>
Subject Re: DiscoverySpiNodeAuthenticator implementation
Date Mon, 23 May 2016 14:21:02 GMT
I've tried the code from
http://smartkey.co.uk/development/securing-an-apache-ignite-cluster/ too.
The second (blocked) node just throw exception as in my example with
DiscoverySpiNodeAuthenticator:

2016/05/23 17:28:08.062 [main] ERROR Failed to start manager:
GridManagerAdapter [enabled=true,
name=o.a.i.i.managers.discovery.GridDiscoveryManager]
org.apache.ignite.IgniteCheckedException: Failed to start SPI:
TcpDiscoverySpi [addrRslvr=null, sockTimeout=5000, ackTimeout=5000,
reconCnt=10, maxAckTimeout=600000, forceSrvMode=false,
clientReconnectDisabled=false]
	at
org.apache.ignite.internal.managers.GridManagerAdapter.startSpi(GridManagerAdapter.java:258)
	at
org.apache.ignite.internal.managers.discovery.GridDiscoveryManager.start(GridDiscoveryManager.java:677)
	at
org.apache.ignite.internal.IgniteKernal.startManager(IgniteKernal.java:1531)
	at org.apache.ignite.internal.IgniteKernal.start(IgniteKernal.java:897)
	at
org.apache.ignite.internal.IgnitionEx$IgniteNamedInstance.start0(IgnitionEx.java:1736)
	at
org.apache.ignite.internal.IgnitionEx$IgniteNamedInstance.start(IgnitionEx.java:1589)
	at org.apache.ignite.internal.IgnitionEx.start0(IgnitionEx.java:1042)
	at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.java:569)
	at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.java:516)
	at org.apache.ignite.Ignition.start(Ignition.java:322)
	at dmp.grid.engine.Engine.start(Engine.java:120)
	at dmp.grid.Node.run(Node.java:45)
	at dmp.grid.Node.main(Node.java:32)
	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:498)
	at org.codehaus.mojo.exec.ExecJavaMojo$1.run(ExecJavaMojo.java:293)
	at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.ignite.spi.IgniteSpiException: Access denied
	at
org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi.checkFailedError(TcpDiscoverySpi.java:1644)
	at
org.apache.ignite.spi.discovery.tcp.ServerImpl.joinTopology(ServerImpl.java:885)
	at
org.apache.ignite.spi.discovery.tcp.ServerImpl.spiStart(ServerImpl.java:334)
	at
org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi.spiStart(TcpDiscoverySpi.java:1832)
	at
org.apache.ignite.internal.managers.GridManagerAdapter.startSpi(GridManagerAdapter.java:255)
	... 18 common frames omitted

Expected behaviour is the continue to work in standalone mode in this case.
Here is the code with blocks any other nodes from connecting to current one
(

public class TokenSecurityProcessor implements
DiscoverySpiNodeAuthenticator, GridSecurityProcessor, IgnitePlugin {
    ...
    @Override
    public IgniteNodeValidationResult validateNode(ClusterNode node) {
        return new IgniteNodeValidationResult(node.id(), "Access denied",
"Access denied");
    }
}



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/DiscoverySpiNodeAuthenticator-implementation-tp5087p5121.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Mime
View raw message