dev@grizzly.java.net

Re: need some help

From: Oleksiy Stashok <Oleksiy.Stashok_at_Sun.COM>
Date: Mon, 01 Dec 2008 13:51:57 +0100

Hi,

can you pls. show the stacktrace?

Thanks.

WBR,
Alexey.

On Nov 30, 2008, at 22:34 , rama wrote:

> dear friends,
>
> i need some help with this piece of code.
>
> public class EulerResAdapter implements Adapter {
>
> public void service(Request req, final Response res) throws
> Exception {
> req.remoteAddr();
> }
>
> //blablabla (other method)
>
> }
>
>
> after adding this adapter
> st = new SelectorThread();
> st.setPort(port);
> st.setMaxThreads(maxThreads);
> st.setAdapter(new EulerResAdapter());
>
> req.remoteAddr throw a nullpointer :(
>
>
> btw, i use a method to serve file on this adapter, that work like a
> charm.
> the only problem is that i don't understand how to get the ip address
> of the remote addrs
>
>
> there is a way to get the remote ip address of a req?
>
> best regards
>