Esempio n. 1
0
 public static DefaultExecutedScriptInfoSource getDefaultExecutedScriptInfoSource(
     Database database, boolean autoCreateExecutedScriptsTable, ScriptIndexes baselineRevision) {
   ScriptFactory scriptFactory =
       new ScriptFactory(
           "^([0-9]+)_",
           "(?:\\\\G|_)@([a-zA-Z0-9]+)_",
           "(?:\\\\G|_)#([a-zA-Z0-9]+)_",
           Collections.<Qualifier>emptySet(),
           asSet(new Qualifier("patch")),
           "postprocessing",
           baselineRevision);
   return new DefaultExecutedScriptInfoSource(
       autoCreateExecutedScriptsTable,
       "dbmaintain_scripts",
       "file_name",
       150,
       "file_last_modified_at",
       "checksum",
       50,
       "executed_at",
       50,
       "succeeded",
       new SimpleDateFormat("dd/MM/yyyy"),
       database,
       new DefaultSQLHandler(),
       scriptFactory);
 }
Esempio n. 2
0
 public static FileSystemScriptLocation createFileSystemLocation(File scriptRootLocation) {
   return new FileSystemScriptLocation(
       scriptRootLocation,
       "ISO-8859-1",
       "postprocessing",
       Collections.<Qualifier>emptySet(),
       asSet(new Qualifier("patch")),
       "^([0-9]+)_",
       "(?:\\\\G|_)@([a-zA-Z0-9]+)_",
       "(?:\\\\G|_)#([a-zA-Z0-9]+)_",
       asSet("sql"),
       null,
       false);
 }