Browse Source

Enable persistence of the task data

Enable h2 database
  Create initial evolution for tasks table
master
unknown 11 years ago
parent
commit
c836e27750
  1. 4
      conf/application.conf
  2. 14
      conf/evolutions/default/1.sql

4
conf/application.conf

@ -33,8 +33,8 @@ application.langs="en"
# You can declare as many datasources as you want. # You can declare as many datasources as you want.
# By convention, the default datasource is named `default` # By convention, the default datasource is named `default`
# #
# db.default.driver=org.h2.Driver
# db.default.url="jdbc:h2:mem:play"
db.default.driver=org.h2.Driver
db.default.url="jdbc:h2:mem:play"
# db.default.user=sa # db.default.user=sa
# db.default.password="" # db.default.password=""

14
conf/evolutions/default/1.sql

@ -0,0 +1,14 @@
# Tasks schema
# --- !Ups
CREATE SEQUENCE task_id_seq;
CREATE TABLE task (
id integer NOT NULL DEFAULT nextval('task_id_seq'),
label varchar(255)
);
# --- !Downs
DROP TABLE task;
DROP SEQUENCE task_id_seq;