Package org.craftercms.studio.api.v1.dal
Interface SiteFeedMapper
public interface SiteFeedMapper
-
Method Summary
Modifier and TypeMethodDescriptionvoid
clearPublishingLockForSite
(String siteId) Clear publishing lock for siteint
boolean
createSite
(SiteFeed siteFeed) boolean
deleteSite
(String siteId, String state) Delete sitevoid
duplicate
(String sourceSiteId, String siteId, String name, String description, String sandboxBranch, String siteUuid) Duplicate a site in the databasevoid
enablePublishing
(Map params) existsById
(String id) existsByName
(String name) getAllCreatedSites
(String state) getLastCommitId
(String siteId) Get last commit id for local studio nodegetLastSyncedGitlogCommitId
(String siteId) Get last verified git log commit id for local studio nodegetLastVerifiedGitlogCommitId
(String siteId) Get last verified git log commit id for local studio nodeint
getPublishedRepoCreated
(String siteId) getPublishingStatus
(String siteId, int ttl) Get publishing status for sitegetSites()
getSitesPerUserData
(Map params) getSitesPerUserQuery
(Map params) int
getSitesPerUserQueryTotal
(Map params) getSiteState
(String siteId) boolean
isNameUsed
(String siteId, String name) Checks if there is a site, different than the siteId, using the given namevoid
setPublishedRepoCreated
(String siteId) Set published repo created flagvoid
setSiteState
(String siteId, String state) void
updateLastCommitId
(Map params) void
updateLastSyncedGitlogCommitId
(Map params) void
updateLastVerifiedGitlogCommitId
(Map params) void
updatePublishingStatus
(String siteId, String status) Update publishing statusint
updateSite
(String siteId, String name, String description) Updates the name and description for the given site
-
Method Details
-
getSites
-
countSites
int countSites() -
getSite
-
createSite
-
deleteSite
Delete site- Parameters:
siteId
- site identifierstate
- deleted state value- Returns:
-
updateLastCommitId
-
exists
-
existsById
-
existsByName
-
isNameUsed
Checks if there is a site, different than the siteId, using the given name- Parameters:
siteId
- the id of the sitename
- the name of the site- Returns:
- true if the name is being used by another site
-
getSitesPerUserQueryTotal
-
getSitesPerUserQuery
-
getSitesPerUserData
-
enablePublishing
-
updatePublishingStatus
void updatePublishingStatus(@Param("siteId") String siteId, @Param("publishingStatus") String status) Update publishing status- Parameters:
siteId
- site identifierstatus
- publisher status
-
updateLastVerifiedGitlogCommitId
-
updateLastSyncedGitlogCommitId
-
getDeletedSites
-
setPublishedRepoCreated
Set published repo created flag- Parameters:
siteId
- site identifier
-
updateSite
int updateSite(@Param("siteId") String siteId, @Param("name") String name, @Param("description") String description) Updates the name and description for the given site- Parameters:
siteId
- the id of the sitename
- the name of the sitedescription
- the description of the site- Returns:
- the number of changed rows
-
getLastCommitId
Get last commit id for local studio node- Parameters:
siteId
- site identifier- Returns:
- commit id
-
getLastVerifiedGitlogCommitId
Get last verified git log commit id for local studio node- Parameters:
siteId
- site identifier- Returns:
- commit id
-
getLastSyncedGitlogCommitId
Get last verified git log commit id for local studio node- Parameters:
siteId
- site identifier- Returns:
- commit id
-
setSiteState
-
getAllCreatedSites
-
getSiteState
-
getPublishedRepoCreated
-
getPublishingStatus
Get publishing status for site- Parameters:
siteId
- site identifierttl
- amount of minutes to add to the- Returns:
- Publishing status
-
clearPublishingLockForSite
Clear publishing lock for site- Parameters:
siteId
- site identifier
-
duplicate
void duplicate(@Param("sourceSiteId") String sourceSiteId, @Param("siteId") String siteId, @Param("name") String name, @Param("description") String description, @Param("sandboxBranch") String sandboxBranch, @Param("uuid") String siteUuid) Duplicate a site in the database- Parameters:
sourceSiteId
- the id of the site to duplicatesiteId
- the id of the new sitename
- the name of the new sitedescription
- the description of the new sitesandboxBranch
- the sandbox branch of the new sitesiteUuid
- the uuid of the new site
-