Hi Chris, 

    I am new to web application. i have created a one small application to 
store data's in a h2 database. it is working fine in STS tool. After 
deploying a war file into tomcat server. it is not working. i am not able 
to see h2 console on tomcat. Can we use embedded database with spring boot 
war. Please help me on this. 


On Sunday, March 30, 2008 at 5:23:31 AM UTC+5:30, Chris W. wrote:
>
> I was able to get my JRuby on Rails application working with H2 using 
> a JNDI database pool.  The primary reason I had to do this was because 
> tomcat on windows was giving me errors saying multiple processes were 
> trying to access the database.  On UNIX (Linux and Solaris), this 
> didn't happen.  The following is what I added to the conf/context.xml 
> in my tomcat install. 
>
> <Resource 
>       name="h2/maadn_production" 
>       type="javax.sql.DataSource" 
>       url="jdbc:h2:/home/Chris/projects/h2_databases/maadn_production" 
>       driverClassName="org.h2.Driver" 
>       username="" 
>       password="" 
>       maxActive="100" 
>       maxIdle="20"/> 
>
> I also had to add the h2 jar to the common/lib. 
>
> Thanks for the great product! 
> Chris 
> On Mar 29, 7:21 pm, "Chris W." <[email protected]> wrote: 
> > I would like to use a server but the IT guys are only allowing me to 
> > deploy with Tomcat and no other additional software running.  My goal 
> > is to just deploy my Rails app with a war with an embedded database. 
> > I was going to use Derby until I saw the performance comparison.  I 
> > see another post that had an example for a datbase pool so I am going 
> > to experiment with it.  I will follow-up if I make any progress. 
> > 
> > Thanks 
> > Chris 
> > 
> > On Mar 28, 1:26 pm, "Thomas Mueller" <[email protected]> 
> > wrote: 
> > 
> > > Hi, 
> > 
> > > >  I am trying to use H2 as my database engine for a Ruby on Rails 
> > > >  application using JRuby. 
> > 
> > > Cool! Unfortunately I didn't have time yet to try out JRuby. 
> > 
> > > >  I am using H2 in an embedded mode. 
> > > > org.h2.jdbc.JdbcSQLException: Database may be already in use: Locked 
> > > > by another process. Possible solutions: close all other 
> connection(s); 
> > > > use the server mode [90020-63]): 
> > 
> > > Well, probably you should use the server mode. I think this is easier 
> > > than using JNDI. To use the server mode, you need to start a server 
> > > (or start the H2 Console application), and then use a JDBC URL of this 
> > > form: jdbc:h2:tcp://localhost/~/test 
> > 
> > > See also:http://www.h2database.com/html/tutorial.html#using_server 
> > 
> > > Please tell me if this worked for you! 
> > 
> > > Regards, 
> > > Thomas

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.

Reply via email to