public class

AutoExportImpl

extends Object
implements AutoExport
java.lang.Object
   ↳ com.atlassian.jira.bean.export.AutoExportImpl

Class Overview

Determines the best possible location (if any) and export all JIRA data to the chosen location using any provided filename generation strategy.

Summary

[Expand]
Inherited Constants
From interface com.atlassian.jira.bean.export.AutoExport
Public Constructors
AutoExportImpl(String defaultDir)
Creates an AutoExport that uses the given defaultDir and a datestamp filename generator.
Public Methods
String exportData()
Attempts to choose the best location for export and exports the existing data This method tries to export to backup path, then to index path and the to the value of the "javax.servlet.context.tempdir" property of the passed in ServletContext
String getExportFilePath()
Tries the JIRA backup path, the configured JIRA index path and the servlet temp directory as candidate export file paths before failing.
Protected Methods
ExportService getExportService()
JiraAuthenticationContext getJiraAuthContext()
boolean isValidDirectory(String filename)
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.jira.bean.export.AutoExport

Public Constructors

public AutoExportImpl (String defaultDir)

Creates an AutoExport that uses the given defaultDir and a datestamp filename generator.

Public Methods

public String exportData ()

Attempts to choose the best location for export and exports the existing data This method tries to export to backup path, then to index path and the to the value of the "javax.servlet.context.tempdir" property of the passed in ServletContext

Returns
  • the list of errors that occured duing the export

public String getExportFilePath ()

Tries the JIRA backup path, the configured JIRA index path and the servlet temp directory as candidate export file paths before failing.

Returns
  • the ultimate filepath decided.
Throws
FileNotFoundException if configuration of each option is a missing dir.
FileExistsException if there is a file in the way of the generated path.
IOException if there is a filesystem problem in determining the best path.

Protected Methods

protected ExportService getExportService ()

protected JiraAuthenticationContext getJiraAuthContext ()

protected boolean isValidDirectory (String filename)