I've just checked that test unit running on Linux Mint 5 with the same build
of JDK, and it works like a charm. No problems there.
Anyway, it's the first time I use SSL, and there is something disappointing
me. I have a Callable class on the server-side, that has a stack of messages
it should send to client, specified by clientSelectionKey. If I write
something like
@Override
public Object call()
{
try
{
for(Message message : _messages)
{
if (clientSelectionKey.isValid())
{
SSLOutputWriter.flushChannel(clientSelectionKey.channel(),
message.getByteBuffer());
}
...
I get
Sep 30, 2008 12:10:10 AM com.sun.grizzly.Controller returnContext
FINE: returnContext() Context : com.sun.grizzly.Context_at_b82368
java.lang.NullPointerException
at com.sun.grizzly.util.SSLUtils.wrap(SSLUtils.java:290)
at
com.sun.grizzly.util.SSLOutputWriter.flushChannel(SSLOutputWriter.java:87)
at
com.sun.grizzly.util.SSLOutputWriter.flushChannel(SSLOutputWriter.java:69)
at TestSSLPrj.Client.call(Client.java:137)
at
com.sun.grizzly.util.WorkerThreadImpl.processTask(WorkerThreadImpl.java:309)
at
com.sun.grizzly.util.WorkerThreadImpl.run(WorkerThreadImpl.java:168)
The ByteBuffer of "message" is not null, the SelectionKey is valid, so I
wonder, why I can't send data to client. Have I missed something, or is
there a better practice to send data from server to client with SSL?
Thanks in advance,
-- Quende
--
View this message in context: http://www.nabble.com/Problem-with-SSL-tp19709902p19731104.html
Sent from the Grizzly - Users mailing list archive at Nabble.com.