Package org.nuxeo.ecm.quota
Interface QuotaStatsService
- All Known Implementing Classes:
QuotaStatsServiceImpl
public interface QuotaStatsService
Service used to compute quota and statistics on documents.
- Since:
- 5.5
- Author:
- Thomas Roger
-
Method Summary
Modifier and TypeMethodDescriptionvoid
activateQuotaOnUserWorkspaces
(long maxQuota, CoreSession session) Activates the quota on user personal workspacesboolean
canSetMaxQuota
(long maxQuota, DocumentModel doc, CoreSession session) Test to see if quota allowed.void
computeInitialStatistics
(String updaterName, CoreSession session, QuotaStatsInitialWork currentWorker, String path) Compute the initial statistics for the given @{code updaterName} fordocPath
.getProgressStatus
(String updaterName, String repositoryName) Returns the progress status ofupdaterName
.long
getQuotaFromParent
(DocumentModel doc, CoreSession session) Gets the quota from the first parent where quota has been set.long
getQuotaSetOnUserWorkspaces
(CoreSession session) void
launchInitialStatisticsComputation
(String updaterName, String repositoryName, String path) Launch an asynchronously initial computation for the givenupdaterName
onrepositoryName
fordocPath
.void
launchSetMaxQuotaOnUserWorkspaces
(long maxQuota, DocumentModel context, CoreSession session) Sets this maxQuota on all user workspacesvoid
updateStatistics
(DocumentEventContext docCtx, Event event) Update the statistics for the givendocCtx
andevent
.
-
Method Details
-
getQuotaStatsUpdaters
List<QuotaStatsUpdater> getQuotaStatsUpdaters() -
updateStatistics
-
computeInitialStatistics
void computeInitialStatistics(String updaterName, CoreSession session, QuotaStatsInitialWork currentWorker, String path) Compute the initial statistics for the given @{code updaterName} fordocPath
.- Since:
- 10.1
-
launchInitialStatisticsComputation
Launch an asynchronously initial computation for the givenupdaterName
onrepositoryName
fordocPath
.- Since:
- 10.1
-
getProgressStatus
Returns the progress status ofupdaterName
. -
getQuotaFromParent
Gets the quota from the first parent where quota has been set. Returns -1 if no quota has been set. For user workspaces, only the first parent is investigated- Since:
- 5.7
-
canSetMaxQuota
Test to see if quota allowed. Skip user worskpaces, where validation rules don't apply.- Since:
- 5.7
-
launchSetMaxQuotaOnUserWorkspaces
Sets this maxQuota on all user workspaces- Since:
- 5.7
-
activateQuotaOnUserWorkspaces
Activates the quota on user personal workspaces- Since:
- 5.7
-
getQuotaSetOnUserWorkspaces
- Since:
- 5.7
-