Re: GWT + Postgres not working when deployed

2013-10-17 Thread Sean
Ok, 
http://tomcat.apache.org/tomcat-7.0-doc/jndi-datasource-examples-howto.html#PostgreSQL
 worked, 
but you have to add the Resource to the projects Web.xml and not TOMCAT's 
web.xml.

Man, that was a pain in the ass. Thanks for the suggestions guys!

On Thursday, October 17, 2013 12:16:11 PM UTC-4, Sean wrote:
>
> The .jar is on my build path. I've double checked that. 
>
> Currently I'm loading the driver like this:
> conn=DriverManager.getConnection(url,user, pw);
>
> where the url is 
> String url = "jdbc:postgresql://"+host+"/"+dbName;
>
> It works from dev mode, for some reason once deployed it doesn't. 
>
> I'm trying to configure Tomcat to know about the .jar in a different way 
> now:
>
>
> http://tomcat.apache.org/tomcat-7.0-doc/jndi-datasource-examples-howto.html#PostgreSQL
>
> So far, no luck. I'm going to keep working on it.
> On Thursday, October 17, 2013 11:48:15 AM UTC-4, GWTter wrote:
>>
>> Sounds like your postgresjdbc is not on the classpath when building the 
>> war. Have you made sure that it would be included in the classpath in the 
>> build.xml?
>>
>> On Thursday, October 17, 2013 5:20:01 PM UTC+2, Sean wrote:
>>>
>>> I have a project that talks to Postgres on the server side. I have the 
>>> JDBC jar in the WEB-INF/lib folder. When I run it on my machine it works 
>>> fine. But when I deploy it to a TOMCAT instance I get:
>>>
>>> java.sql.SQLException: No suitable driver found for 
>>> jdbc:postgresql://localhost/grp91-in-out
>>> at java.sql.DriverManager.getConnection(Unknown Source)
>>> at java.sql.DriverManager.getConnection(Unknown Source)
>>> at 
>>> com.ll.grp91.server.GroupInfoServiceImpl.getGroupMembers(GroupInfoServiceImpl.java:45)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> .
>>>
>>> I've also tried putting the .jar into the Tomcat/lib folder. Still no 
>>> good. I've also tried restarting the service.
>>>
>>> Any ideas?
>>>
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: GWT + Postgres not working when deployed

2013-10-17 Thread Sean
The .jar is on my build path. I've double checked that. 

Currently I'm loading the driver like this:
conn=DriverManager.getConnection(url,user, pw);

where the url is 
String url = "jdbc:postgresql://"+host+"/"+dbName;

It works from dev mode, for some reason once deployed it doesn't. 

I'm trying to configure Tomcat to know about the .jar in a different way 
now:

http://tomcat.apache.org/tomcat-7.0-doc/jndi-datasource-examples-howto.html#PostgreSQL

So far, no luck. I'm going to keep working on it.
On Thursday, October 17, 2013 11:48:15 AM UTC-4, GWTter wrote:
>
> Sounds like your postgresjdbc is not on the classpath when building the 
> war. Have you made sure that it would be included in the classpath in the 
> build.xml?
>
> On Thursday, October 17, 2013 5:20:01 PM UTC+2, Sean wrote:
>>
>> I have a project that talks to Postgres on the server side. I have the 
>> JDBC jar in the WEB-INF/lib folder. When I run it on my machine it works 
>> fine. But when I deploy it to a TOMCAT instance I get:
>>
>> java.sql.SQLException: No suitable driver found for 
>> jdbc:postgresql://localhost/grp91-in-out
>> at java.sql.DriverManager.getConnection(Unknown Source)
>> at java.sql.DriverManager.getConnection(Unknown Source)
>> at 
>> com.ll.grp91.server.GroupInfoServiceImpl.getGroupMembers(GroupInfoServiceImpl.java:45)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> .
>>
>> I've also tried putting the .jar into the Tomcat/lib folder. Still no 
>> good. I've also tried restarting the service.
>>
>> Any ideas?
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: GWT + Postgres not working when deployed

2013-10-17 Thread Natanael Maldonado
Could you show us how are you loading your driver in memory?
El 17/10/2013 10:20, "Sean"  escribió:

> I have a project that talks to Postgres on the server side. I have the
> JDBC jar in the WEB-INF/lib folder. When I run it on my machine it works
> fine. But when I deploy it to a TOMCAT instance I get:
>
> java.sql.SQLException: No suitable driver found for
> jdbc:postgresql://localhost/grp91-in-out
> at java.sql.DriverManager.getConnection(Unknown Source)
> at java.sql.DriverManager.getConnection(Unknown Source)
> at
> com.ll.grp91.server.GroupInfoServiceImpl.getGroupMembers(GroupInfoServiceImpl.java:45)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> .
>
> I've also tried putting the .jar into the Tomcat/lib folder. Still no
> good. I've also tried restarting the service.
>
> Any ideas?
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: GWT + Postgres not working when deployed

2013-10-17 Thread GWTter
Sounds like your postgresjdbc is not on the classpath when building the 
war. Have you made sure that it would be included in the classpath in the 
build.xml?

On Thursday, October 17, 2013 5:20:01 PM UTC+2, Sean wrote:
>
> I have a project that talks to Postgres on the server side. I have the 
> JDBC jar in the WEB-INF/lib folder. When I run it on my machine it works 
> fine. But when I deploy it to a TOMCAT instance I get:
>
> java.sql.SQLException: No suitable driver found for 
> jdbc:postgresql://localhost/grp91-in-out
> at java.sql.DriverManager.getConnection(Unknown Source)
> at java.sql.DriverManager.getConnection(Unknown Source)
> at 
> com.ll.grp91.server.GroupInfoServiceImpl.getGroupMembers(GroupInfoServiceImpl.java:45)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> .
>
> I've also tried putting the .jar into the Tomcat/lib folder. Still no 
> good. I've also tried restarting the service.
>
> Any ideas?
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.