You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The export service works asynchronously: first you request the export with the desired options, then you monitor the state of the export, and finally you request the output file. You must be authenticated as the system admin (superuser) for the export services.
`everything `- export everything except audit data: all repository resources, permissions, report jobs, users, and roles. This option is equivalent to:--uris --repository-permissions --report-jobs --users --roles
1801
+
(default value is false).
1802
+
1803
+
`repository-permissions `- when this option is present, repository permissions are exported along with each exported folder and resource. This option should only be used in conjunction with uris (default value is false).
1804
+
1805
+
`role-users `- when this option is present, each role export triggers the export of all users belonging to the role. This option should only be used in conjunction with --roles (default value is false).
1806
+
1807
+
`include-access-events `- access events (date, time, and user name of last modification) are exported (default value is false).
1808
+
1809
+
`include-audit-events `- include audit data for all resources and users in the export (default value is false).
1810
+
1811
+
`include-monitoring-events `- include monitoring events (default value is false).
1812
+
1813
+
`include-attributes `- include attributes in export (default value is false).
1814
+
1815
+
`skip-attribute-values `- skip attributes values to be exported (default value is false).
1816
+
1817
+
`include-server-settings` - include server settings in export(default value is false).
1818
+
1819
+
`skip-suborganizations `-if the parameter is set to true, the system will omit all the items(e.g. resources, user, roles, organizations) which belong to "sub organizations" even they are directly specified using corresponding options (default value is false).
1820
+
1821
+
`skip-dependent-resources `- skip dependent resources (domain, datasource etc.) to be exported (default value is false).
1822
+
//TODO task
1823
+
Also you can specify:
1824
+
`uris` - list of folder or resource URIs in the repository to export.
1825
+
`scheduledJobs` - list of repository report unit and folder URIsfor which report unit jobs should be exported. For a folder URI, this option exports the scheduled jobs of all reports in the folder and all subfolders.
1826
+
`roles` - list of roles to export.
1827
+
`users` - list of users to export.
1828
+
`resourceTypes` - list of resource types, that will be included in export. If the parameter is null or empty then will include all resource types.
1829
+
`organization` - identifier of organization to export together with its sub organizations. If it is specified it also will be the root organization, starting from it system will export all resources, users, roles e.t.c.
Use the following service to upload a catalog as a zip file and import it with the given options. Specify options as arguments from `com.jaspersoft.jasperserver.jaxrs.client.apiadapters.importexport.importservice.ImportParameter`. Arguments that are omitted are assumed to be false. You must be authenticated as the system admin (superuser) for the import service. Jaspersoft does not recommend uploading files greater than 2 gigabytes.
`includeAccessEvents` - access events (date, time, and user name of last modification) are exported (default value is false).
1884
+
`includeAuditEvents` - include audit data for all resources and users in the export (default value is false).
1885
+
`update` - resources in the catalog replace those in the repository if their URIs and typesmatch (default value is false).
1886
+
`skipUserUpdate` - when used with --update, users in the catalog are not imported or updated. Use this option to import catalogs without overwriting currently defined user (default value is false).
1887
+
`includeMonitoringEvents` - include monitoring events (default value is false).
1888
+
`includeServerSettings` - include server settings (default value is false).
1889
+
`mergeOrganization` - allows merging of exported organization/resource into organization with different identifier. In the case if it is false, then system will throw an exception, if exportedOrganizationId != organizationId_we_import_Into (default value is false).
1890
+
`brokenDependencies` - defines strategy with broken dependencies. Available values are - fail, skip, include (default value is fail).
1891
+
1892
+
Also you can set:
1893
+
`brokenDependencies` - defines strategy with broken dependencies. Available values are:
1894
+
1895
+
fail - server will give an error (errorCode=import.broken.dependencies) if import archive contain broken dependent resources.
1896
+
skip - import will skip from import broken resources.
1897
+
include - import will proceed with broken dependencies. In this case server will try to import broken dependent resources. a) In the case when in target environment there are already dependent resources import of target resource will be success, and resource will be skipped from import if there are no dependent resources to recover dependency chain.
1898
+
`parameters` - list of import parameters.
1899
+
`organization` - organization identifier we import into.
1900
+
```java
1901
+
1836
1902
```
1837
1903
####Checking the Import State
1838
1904
After receiving the import ID, you can check the state of the import operation.
1839
1905
```java
1840
-
OperationResult<StateDto> operationResult =
1906
+
OperationResult<State> operationResult =
1841
1907
client
1842
1908
.authenticate("jasperadmin", "jasperadmin")
1843
1909
.importService()
1844
-
.task(stateDto.getId())
1910
+
.task(state.getId())
1845
1911
.state();
1846
1912
1847
-
StateDto state = operationResult.getEntity();
1913
+
State state = operationResult.getEntity();
1914
+
```
1915
+
####Getting and restarting import task
1916
+
1917
+
To get import task metadata you can use next code example:
Copy file name to clipboardExpand all lines: src/main/java/com/jaspersoft/jasperserver/jaxrs/client/apiadapters/authority/organizations/BatchOrganizationsAdapter.java
Copy file name to clipboardExpand all lines: src/main/java/com/jaspersoft/jasperserver/jaxrs/client/apiadapters/authority/organizations/SingleOrganizationAdapter.java
0 commit comments