91 self._need_sql_create = not exists(dbpath) |
91 self._need_sql_create = not exists(dbpath) |
92 self._need_full_import = self._need_sql_create |
92 self._need_full_import = self._need_sql_create |
93 AbstractSource.__init__(self, repo, appschema, source_config, |
93 AbstractSource.__init__(self, repo, appschema, source_config, |
94 *args, **kwargs) |
94 *args, **kwargs) |
95 |
95 |
96 def backup(self, backupfile): |
96 def backup(self, backupfile, confirm): |
97 """method called to create a backup of the source's data""" |
97 """method called to create a backup of the source's data""" |
98 self.close_pool_connections() |
98 self.close_pool_connections() |
99 try: |
99 try: |
100 self.sqladapter.backup_to_file(backupfile) |
100 self.sqladapter.backup_to_file(backupfile, confirm) |
101 finally: |
101 finally: |
102 self.open_pool_connections() |
102 self.open_pool_connections() |
103 |
103 |
104 def restore(self, backupfile, confirm, drop): |
104 def restore(self, backupfile, confirm, drop): |
105 """method called to restore a backup of source's data""" |
105 """method called to restore a backup of source's data""" |