public abstract class MdsRepository extends SandboxedRepository
SandboxedRepository
implementation for an MDS store
configured in the application.Modifier and Type | Class and Description |
---|---|
static class |
MdsRepository.MdsConfiguration
Configuration of an MDS repository.
|
SandboxedRepository.MainlineCertifier
Modifier and Type | Field and Description |
---|---|
protected ADFLogger |
_logger |
protected MdsRepository.MdsConfiguration |
_mdsConfiguration |
static java.lang.String |
UNIFIED_SANDBOX_ID |
Modifier | Constructor and Description |
---|---|
protected |
MdsRepository(java.lang.String name,
MdsRepository.MdsConfiguration mdsConfig)
Constructs a
SandboxedRepository object for an MDS repository. |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
branch(Sandbox sandbox,
java.lang.String sourceBaseLine)
Branches the objects for a sandbox so that future modifications to the
sandbox will not affect the original repository.
|
static MetadataRevision |
certify(java.util.List<oracle.mds.naming.Namespace> namespaces,
java.lang.String shortComment)
Certifies MDS stores represented by their signature namespaces
and returns a new metadata revision.
|
void |
destroy(Sandbox sandbox)
Destroys a sandbox.
|
ChangeSet |
getChanges(Sandbox sandbox)
Gets the changes made in a sandbox.
|
static java.lang.String |
getCreationLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
java.util.Date |
getLastUpdateDate(Sandbox sandbox)
Returns the date of the last update to this repository in a sandbox.
|
java.lang.String |
getLastUpdatedBy(Sandbox sandbox)
Returns the user who performed last update to this repository in a sandbox.
|
SandboxedRepository.MainlineCertifier |
getMainlineCertifier()
Returns the proxy that creates and returns a new certified label that
represents the current state of the repository mainline.
|
static java.util.Map<java.lang.String,java.lang.String> |
getMdsRepositoryToNamespaceMap()
Returns the map from MdsRepository implementations in the system to their
store locator namespaces.
|
oracle.mds.naming.Namespace |
getMdsStoreLocator()
Returns the namespace used to locate the MDS store used by this repository.
|
SandboxTransaction |
getPendingTransaction(Sandbox sandbox,
java.lang.String transactionId)
Gets the pending transaction of a sandbox operation.
|
static java.lang.String |
getPostMergeLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
static java.lang.String |
getPostMergeUndoLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
static java.lang.String |
getPreCertifiedLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
static java.lang.String |
getPreMergeLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
static java.lang.String |
getPreMergeUndoLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
static java.lang.String |
getRefreshLabelForSandbox(java.lang.String sandboxName)
Deprecated.
|
static java.lang.String |
getTimeSuffix() |
void |
mergeConflicts(Sandbox sandbox)
Deprecated.
|
void |
prepareForRefresh(Sandbox sandbox,
java.lang.String targetBaseline)
Invoked prior to
refresh . |
java.lang.String |
prePublish(Sandbox sandbox)
Invoked prior to
publish(Sandbox) for the repository to
prepare for the upcoming publishing operation. |
UndoableChanges |
publish(Sandbox sandbox)
Merges changes in a sandbox into the repository mainline.
|
UndoableChanges |
publish(Sandbox sandbox,
SandboxArchive archive)
Merges the contents in a sandbox from an archive into the repository
mainline.
|
UndoableChanges |
refresh(Sandbox sandbox,
java.lang.String targetBaseline)
Merges changes from a repository baseline into the sandbox.
|
boolean |
usesCurrentThreadForRefresh()
For Internal Use Only.
|
static void |
validateMdsSandboxName(java.lang.String name)
Validates the name of an MDS sandbox to be created
|
branch, equals, getAvailableProviders, getAvailableProviders, getBranchId, getId, getInstance, getInstance, getName, getState, hasChanges, hashCode, isRefreshNeeded, newCertifiedLabel, publishCompleted, refreshCompleted, setProgress, test, test, toString, warn
public static final java.lang.String UNIFIED_SANDBOX_ID
protected final ADFLogger _logger
protected final MdsRepository.MdsConfiguration _mdsConfiguration
protected MdsRepository(java.lang.String name, MdsRepository.MdsConfiguration mdsConfig)
SandboxedRepository
object for an MDS repository.name
- the name of the repositorymdsConfig
- the MDS configurationjava.lang.IllegalArgumentException
- if the given MDS configuration is nullpublic java.lang.String branch(Sandbox sandbox, java.lang.String sourceBaseLine) throws SandboxException
SandboxedRepository
branch
in class SandboxedRepository
sandbox
- the sandboxsourceBaseLine
- the baseline which the sandbox is based on. The
baseline is usually the latest certified baselineSandboxException
- if an error occursSandboxedRepository.refresh(oracle.adf.share.sandbox.Sandbox, String)
public UndoableChanges refresh(Sandbox sandbox, java.lang.String targetBaseline) throws MergeConflictsException, SandboxException
SandboxedRepository
refresh
in class SandboxedRepository
sandbox
- the sandboxtargetBaseline
- the target baseline; null
if the target
baseline should be the tip of the mainlinenull
if there is no changeMergeConflictsException
- if any conflict occurs during the mergeSandboxException
- if an error occurspublic SandboxTransaction getPendingTransaction(Sandbox sandbox, java.lang.String transactionId)
SandboxedRepository
getPendingTransaction
in class SandboxedRepository
sandbox
- the sandbox that resulted in the pending transactiontransactionId
- the transaction IDnull
if such transaction
does not exist@Deprecated public void mergeConflicts(Sandbox sandbox) throws SandboxException
SandboxException
public java.util.Date getLastUpdateDate(Sandbox sandbox)
SandboxedRepository
getLastUpdateDate
in class SandboxedRepository
sandbox
- the sandbox that contains this repositorynull
if such information is unavailablepublic java.lang.String getLastUpdatedBy(Sandbox sandbox)
SandboxedRepository
getLastUpdatedBy
in class SandboxedRepository
sandbox
- the sandbox that contains this repositorynull
if such information is unavailablepublic void prepareForRefresh(Sandbox sandbox, java.lang.String targetBaseline) throws SandboxException
SandboxedRepository
refresh
.prepareForRefresh
in class SandboxedRepository
sandbox
- the sandbox to be refreshedtargetBaseline
- the target baseline; null
if the target
baseline whould be the tip of the mainlineSandboxException
- if an error occurspublic UndoableChanges publish(Sandbox sandbox) throws MergeConflictsException, SandboxException
SandboxedRepository
publish
in class SandboxedRepository
sandbox
- the sandboxnull
if there is no changeMergeConflictsException
- if any conflict occurs during the mergeSandboxException
- if an error occurspublic UndoableChanges publish(Sandbox sandbox, SandboxArchive archive) throws MergeConflictsException, SandboxException
SandboxedRepository
publish(Sandbox)
.publish
in class SandboxedRepository
sandbox
- the sandbox that contains the contents from the archivearchive
- the archive that provides the contents of the sandboxnull
if there is no
contentsMergeConflictsException
- if any conflict occurs during the mergeSandboxException
- if an error occurspublic ChangeSet getChanges(Sandbox sandbox)
SandboxedRepository
getChanges
in class SandboxedRepository
sandbox
- the sandboxnull
if no changes have been made or if
the sandbox has been publishedpublic void destroy(Sandbox sandbox)
SandboxedRepository
destroy
in class SandboxedRepository
sandbox
- the sandboxpublic java.lang.String prePublish(Sandbox sandbox)
SandboxedRepository
publish(Sandbox)
for the repository to
prepare for the upcoming publishing operation. A rollback label may be
returned if the runtime should read from this label instead of the latest
certified label during publishing.prePublish
in class SandboxedRepository
sandbox
- the sandbox to be publishednull
if the runtime should continue to read from the
latest certified label@Deprecated public static java.lang.String getCreationLabelForSandbox(java.lang.String sandboxName)
@Deprecated public static java.lang.String getRefreshLabelForSandbox(java.lang.String sandboxName)
@Deprecated public static java.lang.String getPreCertifiedLabelForSandbox(java.lang.String sandboxName)
@Deprecated public static java.lang.String getPreMergeLabelForSandbox(java.lang.String sandboxName)
@Deprecated public static java.lang.String getPostMergeLabelForSandbox(java.lang.String sandboxName)
@Deprecated public static java.lang.String getPreMergeUndoLabelForSandbox(java.lang.String sandboxName)
@Deprecated public static java.lang.String getPostMergeUndoLabelForSandbox(java.lang.String sandboxName)
public static java.lang.String getTimeSuffix()
public SandboxedRepository.MainlineCertifier getMainlineCertifier()
SandboxedRepository
getMainlineCertifier
in class SandboxedRepository
public final oracle.mds.naming.Namespace getMdsStoreLocator()
public boolean usesCurrentThreadForRefresh()
true
if the refresh operation must be run in the
current threadpublic static void validateMdsSandboxName(java.lang.String name)
name
- the name for the new sandboxIllegalCharSequenceException
- if the name contains invalid
character sequencespublic static MetadataRevision certify(java.util.List<oracle.mds.naming.Namespace> namespaces, java.lang.String shortComment)
MdsRepository
implementation is found for an MDS store,
the store is not certified.
Note that the certification process: label creation and revision creation
will be done without using any extensions outside ADF, such as the
SandboxSessionSupport
implementation from Oracle Applications.
The visibility of the repositories will depend on the caller's thread
context class loader.
namespaces
- the signature namespaces denoting the MDS stores to be
certifiedshortComment
- a short comment that must not exceed 100 bytes in
lengthpublic static java.util.Map<java.lang.String,java.lang.String> getMdsRepositoryToNamespaceMap()