Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
see JCRVLT-188:
I would appreciate a high level API like boolean JcrPackageManager.exists(Archive) which works on those properties to determine whether an archive (local or remote) is uploaded already in the remote repository.
To achieve that it should work as follows:
- extract the PID and the created date from the given archive
- try to find a package in the package manager with the same pid
- if there is a package compare its created date with the created date from the archive and only return true if both are equal. This method should not consider at all if the package in the repository is installed or not (i.e. shouldn't care about JcrPackage.isInstalled(), because this is mainly used to determine whether the upload should be triggered.
maybe an utility class instead?
public final class PackageUtils { public boolean exists(JcrPackageManager, Archive) }
Attachments
Issue Links
- blocks
-
SLING-6989 Package Installer Factory: Prevent package upload in case of uninstallation/2nd installation
- Open
-
SLING-6999 Package Installer Factory: Prevent package upload/extraction in case the same package is already installed
- Open
- relates to
-
JCRVLT-188 Ensure that hollow packages still provide PackageProperties and JcrPackageDefinition.
- Closed