Thank you Noel,
that's great... this way I should obtain exactly what I need.

*What kind of problems do you think I may experience disabling transaction 
log?* Provided that:
* db access is single threaded
* partial writes don't bother me: at first exception my job terminates (but 
I should guarantee a fresh usable db on the next run)

i.e. before I introduced H2, that legacy code used ehcache to store the 
same data, without transactions support. Should I enable the transaction 
log, H2 would become too slow if compared with ehcache.
Let me explain: I know H2 is plenty of other valuable features (it's a db, 
I've used it in several other projects, and I don't want to compare a db 
with a cache) but in these scenario I prefer fast data access to 
transactions' reliability. That's why I introduced H2 in this scenario.

On Tuesday, July 2, 2013 4:11:30 PM UTC+2, Noel Grandin wrote:
>
>  On 2013-07-02 15:00, Davide Cavestro wrote:
>
>
>  I'd like to know if there's* a way to check for db corruption at startup 
> (without waiting 5 or 10 minutes): if the database is corrupted I'd like to 
> drop it entirely and create a new one*. It would be very useful having a
>  
>  
> You could try opening it in read-only mode. 
> A corrupt DB will cause an exception, and then you can delete it and 
> re-create it.
> If the read-only open succeeds, close it, and open it again in read-write 
> mode.
>
> Also note that LOG=0 is extremely dangerous for production use - you use 
> it at your own risk.
>
>  

-- 
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 http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to