users@glassfish.java.net

Re: JavaMail sessions

From: Behrang Saeedzadeh <behrangsa_at_gmail.com>
Date: Sat, 11 Nov 2006 04:37:01 +0330

Hi again,

I have also tested this scenario with a JavaMail Session resource
named "mail/test" and it didn't work as well.

Regards,
Behi

On 11/11/06, Behrang Saeedzadeh <behrangsa_at_gmail.com> wrote:
> Hi,
>
> I have created a JavaMail Session named "test" via the Admin GUI. To
> test the availability of the resource, I have created a sample JSP
> file containing the following code snippet:
>
> <%
> Context ic = new InitialContext();
> Session ms = (Session) ic.lookup("java:comp/env/mail/test");
> %>
>
> When I visit the JSP page, I get the following exception:
>
> javax.servlet.ServletException: javax.naming.NameNotFoundException:
> No object bound to name java:comp/env/mail/test
>
> Any ideas what is possibly wrong with my setup?
>
> Thanks in advance,
> Behi
>
> --
> "Science is a differential equation. Religion is a boundary condition"
> - Alan Turing
>
> Behrang Saeedzadeh
> http://www.jroller.com/page/behrangsa
> http://my.opera.com/behrangsa
>


-- 
"Science is a differential equation. Religion is a boundary condition"
- Alan Turing
Behrang Saeedzadeh
http://www.jroller.com/page/behrangsa
http://my.opera.com/behrangsa