@Service @Named @RunLevel(value=5, mode=0) public class RuntimeAccessDeploymentReceiverService extends AbstractServerService implements weblogic.deploy.service.DeploymentReceiverV2
Modifier and Type | Class and Description |
---|---|
private class |
RuntimeAccessDeploymentReceiverService.RuntimeAccessDescriptorCreationListener |
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
callbackHandlerId
Handler id.
|
private ConfiguredDeploymentsAccess |
configuredDeployments |
private java.util.List |
currChangeDescriptors
Stores outstanding change descriptors
|
private long |
currRequestId
Stores outstanding request
|
private Descriptor |
currRequestTree
Stores current tree
|
private static int |
currTreeIdx
Prepare the deployment request.
|
private weblogic.deploy.internal.targetserver.datamanagement.Data |
dataObject |
private static weblogic.diagnostics.debug.DebugLogger |
debugLogger
Handle to debug output logger.
|
private ServerService |
dependencyOnDeploymentService
On non-admin servers the start method calls registerService which
calls DeploymentService.getDeploymentService() which is initialized
by the DeploymentService
|
private ServerService |
dependencyOnEarlySecurityInitializationService |
private ServerService |
dependencyOnPropertyService
The start method calls ManagementService.getPropertyService which is
initialized by PropertyService
|
private weblogic.deploy.service.internal.DeploymentService |
deploymentService
A reference to the deploymentService that is initialized when
we register ourselves.
|
private weblogic.management.workflow.DescriptorLock |
descriptorLock |
private weblogic.management.workflow.DescriptorLockHandle |
descriptorLockHandle |
private static int |
DOWNLOAD_ATTEMPTS |
private static int |
DOWNLOAD_SLEEP_SECONDS |
private static weblogic.security.acl.internal.AuthenticatedSubject |
kernelId |
private long |
lastRequestId
Stores last request
|
private static java.lang.String |
localServerName
The name of the local server.
|
private javax.inject.Provider<MSIService> |
msiService
The start method calls MSIService.getMSIService() which is
initialized by the MSIService
|
private boolean |
OLD_LIFECYCLE_MODEL |
private javax.inject.Provider<weblogic.descriptor.internal.PartitionResourceProcessor> |
partitionResourceProcessorProvider |
private javax.inject.Provider<PartitionRuntimeStateManager> |
partitionRuntimeStateManagerProvider |
private java.util.List |
pendingChangeDescriptors |
private long |
pendingCommitRequestId
Pending commit info
|
private Descriptor |
pendingCommitRequestTree |
private boolean |
prepareCalled
Stores whether prepare has been called.
|
private DescriptorDiff |
proposedConfigChanges
Changes for proposed config tree
|
private Descriptor |
proposedConfigTree
Stores proposed config tree
|
private java.util.HashMap |
proposedExternalTrees
Stores proposed external trees
|
private java.util.ArrayList |
restartRequestList
List of requests that are pending restart of the server
|
private javax.inject.Provider<RuntimeAccessImpl> |
runtimeAccessProvider |
private ServerRuntimeMBean |
serverBean |
private static RuntimeAccessDeploymentReceiverService |
singleton
Pointer to service
|
private javax.inject.Provider<TargetingAnalyzer> |
targetingAnalyzerProvider |
private java.util.WeakHashMap |
temporaryTrees
Stores temporary trees to validate they are gc'd.
|
APPLICATION, CONFIGURATION, TESTS
CONNECTOR, EJB, JMS
ACTIVATE_LATER, ADMIN, DISCOVERED, FAILED, FAILED_MIGRATABLE, FAILED_NOT_RESTARTABLE, FAILED_RESTARTING, FORCE_SHUTTING_DOWN, FORCE_SUSPENDING, RESTART_REQUIRED, RESUMING, RUNNING, SERVERSTATES, SHUTDOWN, SHUTDOWN_IN_PROCESS, SHUTDOWN_PENDING, SHUTTING_DOWN, SRVR_ACTIVATE_LATER, SRVR_ADMIN, SRVR_DISCOVERED, SRVR_FAILED, SRVR_FAILED_MIGRATABLE, SRVR_FAILED_NOT_RESTARTABLE, SRVR_FAILED_RESTARTING, SRVR_FORCE_SHUTTING_DOWN, SRVR_FORCE_SUSPENDING, SRVR_RESUMING, SRVR_RUNNING, SRVR_SHUTDOWN, SRVR_SHUTDOWN_IN_PROCESS, SRVR_SHUTDOWN_PENDING, SRVR_SHUTTING_DOWN, SRVR_STANDBY, SRVR_STARTING, SRVR_SUSPENDING, SRVR_UNKNOWN, STANDBY, STARTING, SUSPENDING, UNKNOWN
Constructor and Description |
---|
RuntimeAccessDeploymentReceiverService()
Construct the Service
|
Modifier and Type | Method and Description |
---|---|
private void |
activateUpdate(Descriptor originalDescriptor)
All activates should go through this method to ensure that the underlying original
descriptor is properly unlocked
|
private void |
activateUpdate(Descriptor originalDescriptor,
DescriptorPreNotifyProcessor preNotifyProcessor)
All activates with preprocessors should go through this method to ensure that the underlying original
descriptor is properly unlocked
|
private void |
addTemporaryTree(java.lang.Object beanTree,
java.lang.String name) |
private void |
bootHaltedPartitionsWithTargetedActiveAdminRGs(DomainMBean domain) |
void |
cancel(weblogic.deploy.service.DeploymentContext context)
Cancel the deployment request.
|
void |
commit(weblogic.deploy.service.DeploymentContext context)
Commit the deployment request.
|
void |
commitAnyPendingRequests() |
void |
commitCompleted(weblogic.deploy.service.DeploymentContext deploymentContext,
java.lang.String callbackIdentifier) |
private void |
commitCurrentTreeAndSaveRevertDiffs(Descriptor currTree,
weblogic.deploy.service.DeploymentContext context) |
void |
commitSkipped(weblogic.deploy.service.DeploymentContext deploymentContext) |
private boolean |
containsLocalServer(java.lang.String[] list) |
private void |
doCommit(weblogic.deploy.service.DeploymentContext context,
boolean notify) |
private void |
downloadFiles(long requestId,
weblogic.deploy.service.Deployment deployment) |
private java.util.List<DescriptorInfo> |
findDescriptorInfoForFileName(Descriptor currTree,
java.lang.String filePath) |
private ConfigurationDeployment |
getConfigDeployment(weblogic.deploy.service.DeploymentRequest request) |
java.lang.String |
getHandlerIdentity() |
private java.lang.String |
getLocalServerName() |
private java.lang.String |
getLockFileName() |
static java.lang.Object |
getLockObject() |
private static int |
getNextCurrTreeIdx() |
private PartitionRuntimeMBean |
getPartitionRuntimeBean(java.lang.String partitionName) |
private ServerRuntimeMBean |
getServerBean() |
private ServerMBean |
getServerMBean(java.lang.String serverName) |
static RuntimeAccessDeploymentReceiverService |
getService()
Deprecated.
December 18, 2015 Use LocatorUtilities.getService()
|
void |
halt()
Halt the service.
|
private void |
haltShutdownPartitionsWithNoTargetedActiveAdminRGs(DomainMBean domain) |
private Descriptor |
handleConfigTreeLoad(weblogic.deploy.service.DeploymentContext context,
weblogic.deploy.service.ChangeDescriptor change,
weblogic.deploy.service.Deployment deployment) |
private void |
handleExternalTreeCommit(java.lang.String filePath,
weblogic.deploy.service.DeploymentContext context) |
private void |
handleExternalTreeLoad(long requestId,
weblogic.deploy.service.ChangeDescriptor change) |
private void |
handleExternalTreePrepare(weblogic.deploy.service.DeploymentContext context,
weblogic.deploy.service.ChangeDescriptor change,
weblogic.deploy.service.Deployment deployment) |
private void |
handleRegistrationResponse(weblogic.deploy.service.DeploymentContext registrationResponse)
Utility method to notify deployment service of success
|
private boolean |
isConfigChange(weblogic.deploy.service.ChangeDescriptor change) |
private boolean |
isNonWLSChange(weblogic.deploy.service.ChangeDescriptor change) |
private boolean |
isPublishRequired(DescriptorDiff changes) |
private boolean |
isUpdateChange(weblogic.deploy.service.ChangeDescriptor change) |
private void |
notifyCommitFailure(weblogic.deploy.service.DeploymentRequest request,
java.lang.Exception e)
Utility method to notify deployment service of failure
|
private void |
notifyCommitSuccess(weblogic.deploy.service.DeploymentRequest request)
Utility method to notify deployment service of success
|
private void |
notifyPrepareFailure(weblogic.deploy.service.DeploymentRequest request,
java.lang.Exception e)
Utility method to notify deployment service of failure
|
private void |
notifyPrepareSuccess(weblogic.deploy.service.DeploymentRequest request,
boolean requiresRestart)
Utility method to notify deployment service of success
|
private void |
notifyUpdateFailure(weblogic.deploy.service.DeploymentRequest request,
java.lang.Exception e)
Utility method to notify deployment service of failure
|
private void |
notifyUpdateSuccess(weblogic.deploy.service.DeploymentRequest request)
Utility method to notify deployment service of success
|
private void |
postApplyChanges(TargetingAnalyzer analyzer,
DomainMBean proposed) |
private void |
preApplyChanges(TargetingAnalyzer analyzer,
DomainMBean current) |
void |
prepare(weblogic.deploy.service.DeploymentContext context) |
void |
prepareCompleted(weblogic.deploy.service.DeploymentContext deploymentContext,
java.lang.String callbackIdentifier) |
private void |
prepareUpdate(Descriptor originalDescriptor,
Descriptor proposedDescriptor,
boolean failOnNonDynamicChanges)
All prepares should go through this method to ensure that the underlying original
descriptor is properly locked
|
private DescriptorDiff |
prepareUpdateDiff(Descriptor originalDescriptor,
Descriptor proposedDescriptor,
boolean failOnNonDynamicChanges)
All prepare with diff should go through this method to ensure that the underlying original
descriptor is properly locked
|
private void |
processChanges(TargetingAnalyzer analyzer,
DomainMBean current,
DomainMBean proposed,
Descriptor currTree,
weblogic.deploy.service.DeploymentContext context) |
void |
registerHandler()
Register the deployment service handler.
|
private void |
registerHandlerWithRetries(java.lang.String serverName)
Register the deployment service handler; retry if failures
|
private void |
removeFromRestartList(weblogic.deploy.service.DeploymentRequest request) |
private boolean |
requiresRestart(weblogic.deploy.service.Deployment deployment) |
private void |
resetPendingCommitState() |
private void |
resetState()
Reset tree
|
private void |
revertCommittedConfigChanges(DescriptorDiff revertDiff,
weblogic.deploy.service.DeploymentContext context) |
private void |
rollbackUpdate(Descriptor originalDescriptor)
All rollbacks should go through this method to ensure that the underlying original
descriptor is properly unlocked
|
private void |
savePendingCommitState() |
private void |
setCurrentRequestId(long requestId) |
private void |
setPartitionAndSystemResourcesRestartList(ConfigurationDeployment deployment,
boolean toSetOrResetStatus) |
void |
start()
Start the service.
|
void |
stop()
Stop the service.
|
void |
updateDeploymentContext(weblogic.deploy.service.DeploymentContext context)
Perform work required for prepare.
|
private void |
updateFiles(long requestId,
weblogic.deploy.service.Deployment deployment) |
getName, getVersion, postConstruct, preDestroy, stop
@Inject @Named(value="EarlySecurityInitializationService") private ServerService dependencyOnEarlySecurityInitializationService
@Inject @Named(value="DeploymentService") private ServerService dependencyOnDeploymentService
@Inject private javax.inject.Provider<MSIService> msiService
@Inject @Named(value="PropertyService") private ServerService dependencyOnPropertyService
@Inject private javax.inject.Provider<PartitionRuntimeStateManager> partitionRuntimeStateManagerProvider
@Inject private javax.inject.Provider<TargetingAnalyzer> targetingAnalyzerProvider
@Inject private javax.inject.Provider<RuntimeAccessImpl> runtimeAccessProvider
@Inject private javax.inject.Provider<weblogic.descriptor.internal.PartitionResourceProcessor> partitionResourceProcessorProvider
@Inject private ConfiguredDeploymentsAccess configuredDeployments
@Inject private weblogic.management.workflow.DescriptorLock descriptorLock
private weblogic.management.workflow.DescriptorLockHandle descriptorLockHandle
private final boolean OLD_LIFECYCLE_MODEL
private static weblogic.diagnostics.debug.DebugLogger debugLogger
private static final int DOWNLOAD_ATTEMPTS
private static final int DOWNLOAD_SLEEP_SECONDS
private final weblogic.deploy.internal.targetserver.datamanagement.Data dataObject
private ServerRuntimeMBean serverBean
private long currRequestId
private long lastRequestId
private Descriptor currRequestTree
private Descriptor proposedConfigTree
private boolean prepareCalled
private java.util.HashMap proposedExternalTrees
private java.util.List currChangeDescriptors
private java.lang.String callbackHandlerId
private static RuntimeAccessDeploymentReceiverService singleton
private weblogic.deploy.service.internal.DeploymentService deploymentService
private static weblogic.security.acl.internal.AuthenticatedSubject kernelId
private static java.lang.String localServerName
private java.util.ArrayList restartRequestList
private java.util.WeakHashMap temporaryTrees
private long pendingCommitRequestId
private Descriptor pendingCommitRequestTree
private java.util.List pendingChangeDescriptors
private DescriptorDiff proposedConfigChanges
private static int currTreeIdx
public RuntimeAccessDeploymentReceiverService()
public void start() throws ServiceFailureException
start
in interface ServerService
start
in class AbstractServerService
ServiceFailureException
- service is unable to start due to an
internal error condition. The service is not available if this exception
is thrown. The service should cleanup its state before throwing this
exception. No further callbacks will be issued after this exception is
thrown.public void stop()
stop
in interface ServerService
stop
in class AbstractServerService
public void halt()
halt
in interface ServerService
halt
in class AbstractServerService
public java.lang.String getHandlerIdentity()
getHandlerIdentity
in interface weblogic.deploy.service.CallbackHandler
public void prepare(weblogic.deploy.service.DeploymentContext context)
prepare
in interface weblogic.deploy.service.DeploymentReceiver
private static int getNextCurrTreeIdx()
public void commit(weblogic.deploy.service.DeploymentContext context)
commit
in interface weblogic.deploy.service.DeploymentReceiver
private void doCommit(weblogic.deploy.service.DeploymentContext context, boolean notify)
private void processChanges(TargetingAnalyzer analyzer, DomainMBean current, DomainMBean proposed, Descriptor currTree, weblogic.deploy.service.DeploymentContext context) throws ManagementException, DescriptorUpdateFailedException, ServiceFailureException, PartitionLifeCycleException, ResourceGroupLifecycleException
private void preApplyChanges(TargetingAnalyzer analyzer, DomainMBean current) throws DescriptorUpdateFailedException, ServiceFailureException, DeploymentException
private void postApplyChanges(TargetingAnalyzer analyzer, DomainMBean proposed) throws ManagementException, DescriptorUpdateFailedException
private void haltShutdownPartitionsWithNoTargetedActiveAdminRGs(DomainMBean domain) throws ResourceGroupLifecycleException, PartitionLifeCycleException
private void bootHaltedPartitionsWithTargetedActiveAdminRGs(DomainMBean domain) throws ResourceGroupLifecycleException, PartitionLifeCycleException
private ServerRuntimeMBean getServerBean()
private final PartitionRuntimeMBean getPartitionRuntimeBean(java.lang.String partitionName)
private final java.lang.String getLocalServerName()
private boolean containsLocalServer(java.lang.String[] list)
private boolean requiresRestart(weblogic.deploy.service.Deployment deployment)
private boolean isConfigChange(weblogic.deploy.service.ChangeDescriptor change)
private boolean isUpdateChange(weblogic.deploy.service.ChangeDescriptor change)
private boolean isNonWLSChange(weblogic.deploy.service.ChangeDescriptor change)
public void cancel(weblogic.deploy.service.DeploymentContext context)
cancel
in interface weblogic.deploy.service.DeploymentReceiver
private void removeFromRestartList(weblogic.deploy.service.DeploymentRequest request)
public void prepareCompleted(weblogic.deploy.service.DeploymentContext deploymentContext, java.lang.String callbackIdentifier)
prepareCompleted
in interface weblogic.deploy.service.DeploymentReceiver
public void commitCompleted(weblogic.deploy.service.DeploymentContext deploymentContext, java.lang.String callbackIdentifier)
commitCompleted
in interface weblogic.deploy.service.DeploymentReceiver
public void commitSkipped(weblogic.deploy.service.DeploymentContext deploymentContext)
commitSkipped
in interface weblogic.deploy.service.DeploymentReceiverV2
public void updateDeploymentContext(weblogic.deploy.service.DeploymentContext context)
updateDeploymentContext
in interface weblogic.deploy.service.DeploymentReceiver
private void setPartitionAndSystemResourcesRestartList(ConfigurationDeployment deployment, boolean toSetOrResetStatus)
@Deprecated public static RuntimeAccessDeploymentReceiverService getService()
private void registerHandlerWithRetries(java.lang.String serverName) throws weblogic.deploy.service.RegistrationException, ServiceFailureException
weblogic.deploy.service.RegistrationException
ServiceFailureException
private ServerMBean getServerMBean(java.lang.String serverName)
public void registerHandler() throws weblogic.deploy.service.RegistrationException, ServiceFailureException
weblogic.deploy.service.RegistrationException
ServiceFailureException
private void handleRegistrationResponse(weblogic.deploy.service.DeploymentContext registrationResponse) throws ServiceFailureException
ServiceFailureException
private void notifyUpdateSuccess(weblogic.deploy.service.DeploymentRequest request)
private void notifyUpdateFailure(weblogic.deploy.service.DeploymentRequest request, java.lang.Exception e)
private void notifyPrepareSuccess(weblogic.deploy.service.DeploymentRequest request, boolean requiresRestart)
private void notifyPrepareFailure(weblogic.deploy.service.DeploymentRequest request, java.lang.Exception e)
private void notifyCommitSuccess(weblogic.deploy.service.DeploymentRequest request)
private void notifyCommitFailure(weblogic.deploy.service.DeploymentRequest request, java.lang.Exception e)
private void resetState()
private void setCurrentRequestId(long requestId)
private java.lang.String getLockFileName()
private void updateFiles(long requestId, weblogic.deploy.service.Deployment deployment) throws ManagementException
ManagementException
private void downloadFiles(long requestId, weblogic.deploy.service.Deployment deployment) throws ManagementException
ManagementException
private Descriptor handleConfigTreeLoad(weblogic.deploy.service.DeploymentContext context, weblogic.deploy.service.ChangeDescriptor change, weblogic.deploy.service.Deployment deployment) throws java.io.IOException, DescriptorUpdateRejectedException
java.io.IOException
DescriptorUpdateRejectedException
private void handleExternalTreeLoad(long requestId, weblogic.deploy.service.ChangeDescriptor change) throws java.io.IOException, DescriptorUpdateRejectedException
java.io.IOException
DescriptorUpdateRejectedException
private void handleExternalTreePrepare(weblogic.deploy.service.DeploymentContext context, weblogic.deploy.service.ChangeDescriptor change, weblogic.deploy.service.Deployment deployment) throws java.io.IOException, DescriptorUpdateRejectedException
java.io.IOException
DescriptorUpdateRejectedException
private void handleExternalTreeCommit(java.lang.String filePath, weblogic.deploy.service.DeploymentContext context)
private java.util.List<DescriptorInfo> findDescriptorInfoForFileName(Descriptor currTree, java.lang.String filePath)
private void addTemporaryTree(java.lang.Object beanTree, java.lang.String name)
private void savePendingCommitState()
private void resetPendingCommitState()
public void commitAnyPendingRequests()
private boolean isPublishRequired(DescriptorDiff changes)
private ConfigurationDeployment getConfigDeployment(weblogic.deploy.service.DeploymentRequest request)
private void commitCurrentTreeAndSaveRevertDiffs(Descriptor currTree, weblogic.deploy.service.DeploymentContext context) throws DescriptorUpdateFailedException
DescriptorUpdateFailedException
private void revertCommittedConfigChanges(DescriptorDiff revertDiff, weblogic.deploy.service.DeploymentContext context) throws java.lang.Exception
java.lang.Exception
private void prepareUpdate(Descriptor originalDescriptor, Descriptor proposedDescriptor, boolean failOnNonDynamicChanges) throws DescriptorUpdateRejectedException
private DescriptorDiff prepareUpdateDiff(Descriptor originalDescriptor, Descriptor proposedDescriptor, boolean failOnNonDynamicChanges) throws DescriptorUpdateRejectedException
private void activateUpdate(Descriptor originalDescriptor) throws DescriptorUpdateFailedException
DescriptorUpdateFailedException
private void activateUpdate(Descriptor originalDescriptor, DescriptorPreNotifyProcessor preNotifyProcessor) throws DescriptorUpdateFailedException
DescriptorUpdateFailedException
private void rollbackUpdate(Descriptor originalDescriptor)
public static java.lang.Object getLockObject()