public void Execute(JobExecutionContext context) { var jsonRepository = Repsitory as JsonRepository; if (jsonRepository == null) { throw new Exception("Backup currently supports only JsonRepository"); } Cloud.ArchiveFolder(jsonRepository.DataPath); }