wt.replication.sender
Class StandardSenderService

java.lang.Object
  extended bywt.services.StandardManager
      extended bywt.replication.sender.StandardSenderService
All Implemented Interfaces:
Manager, NetFactor, SenderService, SenderServiceSrv, Serializable

public class StandardSenderService
extends StandardManager
implements SenderService, SenderServiceSrv, Serializable

Use the newStandardSenderService static factory method(s), not the StandardSenderService constructor, to construct instances of this class. Instances must be constructed using the static factory(s), in order to ensure proper initialization of the instance.



Supported API: false

Extendable: false

See Also:
Serialized Form

Nested Class Summary
(package private)  class StandardSenderService.WTUnitSenderEventListener
          Deprecated.  
 
Field Summary
private static String CLASSNAME
          Deprecated.  
private static String EMB_PATH
          Deprecated.  
private static boolean EXECUTE_QUEUES
          Deprecated.  
private static String LINK_LIFECYCLE_TEMPLATE
          Deprecated.  
private static boolean PERFORMANCE
          Deprecated.  
private static String PREFERRED_HTTP_PIPE
          Deprecated.  
private static long REFRESH_RMT_TEAMTEMPLATE_PERIOD
          Deprecated.  
private static String RESOURCE
          Deprecated.  
private static boolean SCHEDULE_ITEM_ENABLED
          Deprecated.  
private static String SENDER_START_TIME
          Deprecated. the time for the sender's start time for replication.
(set in wt.properties - wt.replication.sender.senderstarttime)
If malformed entry or not set, it assumes current time.
Note: time in "24hh:mm:ss" format, not 7:30pm, but instead:
wt.replication.sender.senderstarttime=19:30:00
private static boolean SHOW_LOCAL_SITE
          Deprecated.  
private static String TEAMTEMPLATE_CACHE_QUEUE_NAME
          Deprecated.  
private static String TEAMTEMPLATE_SCHEDULE_ITEM_NAME
          Deprecated.  
private static boolean VERBOSE
          Deprecated.  
private static boolean waitingDone
          Deprecated.  
 
Fields inherited from class wt.services.StandardManager
 
Fields inherited from interface wt.services.Manager
MANAGER_SERVICE, STARTUP_AUTOMATIC, STARTUP_MANUAL, STATUS_EMERGENCY_SHUTDOWN, STATUS_EMERGENCY_SHUTTING_DOWN, STATUS_SHUTDOWN, STATUS_SHUTDOWN_ERRORS, STATUS_SHUTDOWN_FAILURE, STATUS_SHUTTING_DOWN, STATUS_STARTED, STATUS_STARTED_ERRORS, STATUS_STARTING_UP, STATUS_STARTUP_FAILURE
 
Constructor Summary
StandardSenderService()
          Deprecated.  
 
Method Summary
 WTUnit addContentToUnit(ObjectReference unitRef, String fullPath, ContentRoleType roleType)
          Deprecated.  
 WTUnit addContentToUnit(String unitNum, String fullPath, ContentRoleType roleType)
          Deprecated.  
 WTUnit addContentToUnit(String unitNum, String version, String iteration, String fullPath, ContentRoleType roleType)
          Deprecated.  
private static void addLifeCycleUnitSendRecord(UnitSendRecord link, String linkLcTemplate, WTUnit unit)
          Deprecated.  
private  void addThisScheduledItem(Site toSite, boolean scheduleUnique)
          Deprecated.  
private static void deleteRmtTeamTemplates(Site rmtSite)
          Deprecated.  
private  void deleteScheduleQueueEntries()
          Deprecated.  
protected  void dispatchVetoableEvent(String eventType, UnitSendRecord rec)
          Deprecated.  
static void doScheduledSend(UnitSendRecord sendRec, String fullTeamTemplateName, String transType, String embFolder, Boolean onSchedule, Timestamp timeStamp, Locale locale)
          Deprecated. Routine that can be called from the scheduler to send a unit.
private  void embUploadUnitInitialize(WTUnit wtUnit, ObjectReference manifestRef, Site rmtSite, String fullTeamTemplateName, String diskFolder)
          Deprecated.  
private  void embWriteHeader(EMBSenderLog embLog, WTUnit wtUnit, Site rmtSite, String fullTeamTemplateName)
          Deprecated.  
static String enableScheduleItem(UnitSendRecord rec)
          Deprecated. This method is called by the workflow processes to allow the currently active send operation for the replication unit to proceed.
static void findRemoteTeamTemplates(Site site)
          Deprecated.  
 QueryResult getAllSendRecordsForSite(WTUnit unit, String site)
          Deprecated.  
 Enumeration getAllSendRecordsForUnit(WTUnit unit)
          Deprecated.  
 String getConceptualClassname()
          Deprecated.  
private  Timestamp getPropertiesInitialTime(ScheduleItem item)
          Deprecated. Safely gets initial time according to user specification in wt.properties
That is, initial time for start replication sending services.
If incorrect settings, returns current time.
 Enumeration getRemoteTeamTemplates(Site rmtSite)
          Deprecated.  
 QueryResult getSendRecordsByScheduleStatus(WTUnit unit, String site, String status)
          Deprecated.  
 QueryResult getSendRecordsBySenderStatus(WTUnit unit, String site, UnitReplicationStatus status)
          Deprecated.  
private static UnitSendRecord getUniqueSendRecordByScheduleStatus(WTUnit wtUnit, Site site, String status)
          Deprecated.  
private static UnitSendRecord getUniqueSendRecordBySenderStatus(WTUnit wtUnit, Site site, UnitReplicationStatus status)
          Deprecated.  
 boolean isSendOperationActive(WTUnit unit, String site)
          Deprecated.  
private  boolean lookForExistingScheduleItem()
          Deprecated. Looks for existing schedule items in the system associated with this replication service.
Reschedule item start time according to user preference (specified in wt.replication.sender.senderstarttime).
static StandardSenderService newStandardSenderService()
          Deprecated.  
protected  void performStartupProcess()
          Deprecated.  
private  void refreshRmtTeamTemplateOnSiteChange(Site rmtSite, KeyedEvent keyedEvent)
          Deprecated.  
private static void refreshTeamTemplateUponFolderProblem(Site rmtSite, Throwable e)
          Deprecated.  
private  void removeAllScheduledItems()
          Deprecated.  
private  void removeThisScheduledItem(Site rmtSite)
          Deprecated.  
static void saveRemoteTeamTemplates(String rmtUrl, Vector teamTemplateList, Throwable e)
          Deprecated.  
private static void saveRmtTeamTemplates(Site rmtSite, Vector teamTemplateList)
          Deprecated.  
private  void scheduleRemoteTeamTemplateFinding()
          Deprecated.  
 void scheduleSendOperation(WTUnit unit, String fullTeamTemplateName, Site site, boolean bEMBPipe, String embFolder, Timestamp startTime, boolean scheduled, String description, String toUser, String toTeamTemplate, Locale locale)
          Deprecated.  
 void testManifest(WTUnit unit, ApplicationData appData, String fullPath)
          Deprecated.  
private  void updateUnitSentToSiteLinkStatus(ActionShippingItem asi)
          Deprecated.  
private static void updateUnitStatus(WTUnit wtUnit, UnitReplicationStatus statusE, UnitReplicationStatus statusR, UnitReplicationStatus statusI)
          Deprecated.  
static void uploadUnitComplete(ObjectReference sendRecRef, String receiverUrl, Throwable e)
          Deprecated.  
 WTUnit uploadUnitInitialize(UnitSendRecord sendRec, String fullTeamTemplateName, String transType, String embFolder, boolean onSchedule, Timestamp timeStamp)
          Deprecated.  
 
Methods inherited from class wt.services.StandardManager
emergencyShutdown, emergencyShutdownComplete, emergencyShuttingDown, getClassInfo, getManagerService, getManagerStatus, getName, getStartupType, init, initialize, initialize, isStarted, newStandardManager, newStandardManager, performEmergencyShutdownProcess, performShutdownProcess, registerEvents, setManagerService, shutdown, shutdownFailure, shutdownSuccess, shuttingDown, started, startedErrors, startingUp, startup, startupFailure, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
Deprecated. 
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME
Deprecated. 

VERBOSE

private static boolean VERBOSE
Deprecated. 

SENDER_START_TIME

private static String SENDER_START_TIME
Deprecated. 
the time for the sender's start time for replication.
(set in wt.properties - wt.replication.sender.senderstarttime)
If malformed entry or not set, it assumes current time.
Note: time in "24hh:mm:ss" format, not 7:30pm, but instead:
wt.replication.sender.senderstarttime=19:30:00


REFRESH_RMT_TEAMTEMPLATE_PERIOD

private static long REFRESH_RMT_TEAMTEMPLATE_PERIOD
Deprecated. 

SCHEDULE_ITEM_ENABLED

private static boolean SCHEDULE_ITEM_ENABLED
Deprecated. 

waitingDone

private static boolean waitingDone
Deprecated. 

EMB_PATH

private static String EMB_PATH
Deprecated. 

SHOW_LOCAL_SITE

private static boolean SHOW_LOCAL_SITE
Deprecated. 

PREFERRED_HTTP_PIPE

private static String PREFERRED_HTTP_PIPE
Deprecated. 

PERFORMANCE

private static boolean PERFORMANCE
Deprecated. 

TEAMTEMPLATE_CACHE_QUEUE_NAME

private static final String TEAMTEMPLATE_CACHE_QUEUE_NAME
Deprecated. 
See Also:
Constant Field Values

TEAMTEMPLATE_SCHEDULE_ITEM_NAME

private static final String TEAMTEMPLATE_SCHEDULE_ITEM_NAME
Deprecated. 
See Also:
Constant Field Values

EXECUTE_QUEUES

private static boolean EXECUTE_QUEUES
Deprecated. 

LINK_LIFECYCLE_TEMPLATE

private static String LINK_LIFECYCLE_TEMPLATE
Deprecated. 
Constructor Detail

StandardSenderService

public StandardSenderService()
Deprecated. 
Method Detail

getConceptualClassname

public String getConceptualClassname()
Deprecated.  

Returns the conceptual (modeled) name for the class.

Supported API: false

Specified by:
getConceptualClassname in interface NetFactor
Overrides:
getConceptualClassname in class StandardManager
Returns:
String

newStandardSenderService

public static StandardSenderService newStandardSenderService()
                                                      throws WTException
Deprecated.  



Supported API: false

Returns:
StandardSenderService
Throws:
WTException

performStartupProcess

protected void performStartupProcess()
                              throws ManagerException
Deprecated.  

Initialization tasks performed by the engine service. Includes queue activation and event subscription.

Supported API: false

Overrides:
performStartupProcess in class StandardManager
Throws:
ManagerException

dispatchVetoableEvent

protected void dispatchVetoableEvent(String eventType,
                                     UnitSendRecord rec)
                              throws WTException
Deprecated.  



Supported API: false

Parameters:
eventType -
rec -
Throws:
WTException

findRemoteTeamTemplates

public static void findRemoteTeamTemplates(Site site)
                                    throws WTException
Deprecated.  

Cache the team templates at remote site, with the restrictions: 1) match the WTPrincipal which is set at remote site to this site; 2) must associated with ActorRole.CREATOR

Supported API: false

Parameters:
site -
Throws:
WTException

saveRemoteTeamTemplates

public static void saveRemoteTeamTemplates(String rmtUrl,
                                           Vector teamTemplateList,
                                           Throwable e)
                                    throws WTException
Deprecated.  

Save team templates associated with the rmtSite. The team templates match the WTPrincipal set at remote site and are associated with ActorRole.CREATOR role.

Supported API: false

Parameters:
rmtUrl -
teamTemplateList -
e -
Throws:
WTException

addContentToUnit

public WTUnit addContentToUnit(String unitNum,
                               String fullPath,
                               ContentRoleType roleType)
                        throws WTException
Deprecated.  

fullPath is the full path of the file in disk If there are multiple WTUnit object with the same unitNum exist, then the first object is assumed.

Supported API: false

Specified by:
addContentToUnit in interface SenderService
Parameters:
unitNum -
fullPath -
roleType -
Returns:
WTUnit
Throws:
WTException

uploadUnitInitialize

public WTUnit uploadUnitInitialize(UnitSendRecord sendRec,
                                   String fullTeamTemplateName,
                                   String transType,
                                   String embFolder,
                                   boolean onSchedule,
                                   Timestamp timeStamp)
                            throws WTReplicationException,
                                   WTException
Deprecated.  



Supported API: false

Specified by:
uploadUnitInitialize in interface SenderService
Parameters:
sendRec -
fullTeamTemplateName -
transType -
embFolder -
onSchedule -
timeStamp -
Returns:
WTUnit
Throws:
WTReplicationException
WTException

addContentToUnit

public WTUnit addContentToUnit(String unitNum,
                               String version,
                               String iteration,
                               String fullPath,
                               ContentRoleType roleType)
                        throws WTException
Deprecated.  

fullPath is the full path of the file in disk version: value of VersionIdentifier; iteration: value of IterationIdentifier.

Supported API: false

Specified by:
addContentToUnit in interface SenderService
Parameters:
unitNum -
version -
iteration -
fullPath -
roleType -
Returns:
WTUnit
Throws:
WTException

testManifest

public void testManifest(WTUnit unit,
                         ApplicationData appData,
                         String fullPath)
                  throws WTException
Deprecated.  

This method test the unit manifest file creation.

Supported API: false

Specified by:
testManifest in interface SenderService
Parameters:
unit -
appData -
fullPath -
Throws:
WTException

addContentToUnit

public WTUnit addContentToUnit(ObjectReference unitRef,
                               String fullPath,
                               ContentRoleType roleType)
                        throws WTException
Deprecated.  

fullPath is the full path of the file in disk

Supported API: false

Specified by:
addContentToUnit in interface SenderService
Parameters:
unitRef -
fullPath -
roleType -
Returns:
WTUnit
Throws:
WTException

getRemoteTeamTemplates

public Enumeration getRemoteTeamTemplates(Site rmtSite)
                                   throws WTException
Deprecated.  

Returns Enumeration of team templates associated with the rmtSite. The team templates match the WTPrincipal set at remote site and are associated with ActorRole.CREATOR role.

Supported API: false

Specified by:
getRemoteTeamTemplates in interface SenderService
Parameters:
rmtSite -
Returns:
Enumeration
Throws:
WTException

scheduleSendOperation

public void scheduleSendOperation(WTUnit unit,
                                  String fullTeamTemplateName,
                                  Site site,
                                  boolean bEMBPipe,
                                  String embFolder,
                                  Timestamp startTime,
                                  boolean scheduled,
                                  String description,
                                  String toUser,
                                  String toTeamTemplate,
                                  Locale locale)
                           throws WTException,
                                  WTPropertyVetoException
Deprecated.  



Supported API: false

Specified by:
scheduleSendOperation in interface SenderService
Parameters:
unit -
fullTeamTemplateName -
site -
bEMBPipe -
embFolder -
startTime -
scheduled -
description -
toUser -
toTeamTemplate -
locale -
Throws:
WTException
WTPropertyVetoException

getAllSendRecordsForUnit

public Enumeration getAllSendRecordsForUnit(WTUnit unit)
                                     throws WTException
Deprecated.  



Supported API: false

Specified by:
getAllSendRecordsForUnit in interface SenderService
Parameters:
unit -
Returns:
Enumeration
Throws:
WTException

getSendRecordsByScheduleStatus

public QueryResult getSendRecordsByScheduleStatus(WTUnit unit,
                                                  String site,
                                                  String status)
                                           throws WTException
Deprecated.  



Supported API: false

Specified by:
getSendRecordsByScheduleStatus in interface SenderService
Parameters:
unit -
site -
status -
Returns:
QueryResult
Throws:
WTException

getSendRecordsBySenderStatus

public QueryResult getSendRecordsBySenderStatus(WTUnit unit,
                                                String site,
                                                UnitReplicationStatus status)
                                         throws WTException
Deprecated.  



Supported API: false

Specified by:
getSendRecordsBySenderStatus in interface SenderService
Parameters:
unit -
site -
status -
Returns:
QueryResult
Throws:
WTException

getAllSendRecordsForSite

public QueryResult getAllSendRecordsForSite(WTUnit unit,
                                            String site)
                                     throws WTException
Deprecated.  



Supported API: false

Specified by:
getAllSendRecordsForSite in interface SenderService
Parameters:
unit -
site -
Returns:
QueryResult
Throws:
WTException

isSendOperationActive

public boolean isSendOperationActive(WTUnit unit,
                                     String site)
                              throws WTException
Deprecated.  



Supported API: false

Specified by:
isSendOperationActive in interface SenderService
Parameters:
unit -
site -
Returns:
boolean
Throws:
WTException

uploadUnitComplete

public static void uploadUnitComplete(ObjectReference sendRecRef,
                                      String receiverUrl,
                                      Throwable e)
                               throws WTReplicationException,
                                      WTException
Deprecated. 
Throws:
WTReplicationException
WTException

updateUnitStatus

private static void updateUnitStatus(WTUnit wtUnit,
                                     UnitReplicationStatus statusE,
                                     UnitReplicationStatus statusR,
                                     UnitReplicationStatus statusI)
                              throws WTException
Deprecated. 
Throws:
WTException

updateUnitSentToSiteLinkStatus

private void updateUnitSentToSiteLinkStatus(ActionShippingItem asi)
                                     throws WTException,
                                            WTPropertyVetoException
Deprecated. 
Throws:
WTException
WTPropertyVetoException

doScheduledSend

public static void doScheduledSend(UnitSendRecord sendRec,
                                   String fullTeamTemplateName,
                                   String transType,
                                   String embFolder,
                                   Boolean onSchedule,
                                   Timestamp timeStamp,
                                   Locale locale)
                            throws WTException
Deprecated. 
Routine that can be called from the scheduler to send a unit.

Throws:
WTException

addLifeCycleUnitSendRecord

private static void addLifeCycleUnitSendRecord(UnitSendRecord link,
                                               String linkLcTemplate,
                                               WTUnit unit)
Deprecated. 

getUniqueSendRecordByScheduleStatus

private static UnitSendRecord getUniqueSendRecordByScheduleStatus(WTUnit wtUnit,
                                                                  Site site,
                                                                  String status)
                                                           throws WTException,
                                                                  WTReplicationException
Deprecated. 
Throws:
WTException
WTReplicationException

getUniqueSendRecordBySenderStatus

private static UnitSendRecord getUniqueSendRecordBySenderStatus(WTUnit wtUnit,
                                                                Site site,
                                                                UnitReplicationStatus status)
                                                         throws WTException,
                                                                WTReplicationException
Deprecated. 
Throws:
WTException
WTReplicationException

enableScheduleItem

public static String enableScheduleItem(UnitSendRecord rec)
Deprecated. 
This method is called by the workflow processes to allow the currently active send operation for the replication unit to proceed. The arguments and return type for this method should not be changed because that will break existing workflow templates.

Supported API: true

Parameters:
rec - The UnitSendRecord whose send operation is to be enabled.
Returns:
A string indicating "success" or "failure"

embUploadUnitInitialize

private void embUploadUnitInitialize(WTUnit wtUnit,
                                     ObjectReference manifestRef,
                                     Site rmtSite,
                                     String fullTeamTemplateName,
                                     String diskFolder)
                              throws WTReplicationException
Deprecated. 
Throws:
WTReplicationException

embWriteHeader

private void embWriteHeader(EMBSenderLog embLog,
                            WTUnit wtUnit,
                            Site rmtSite,
                            String fullTeamTemplateName)
Deprecated. 

scheduleRemoteTeamTemplateFinding

private void scheduleRemoteTeamTemplateFinding()
Deprecated. 

removeAllScheduledItems

private void removeAllScheduledItems()
Deprecated. 

deleteScheduleQueueEntries

private void deleteScheduleQueueEntries()
Deprecated. 

deleteRmtTeamTemplates

private static void deleteRmtTeamTemplates(Site rmtSite)
                                    throws WTException
Deprecated. 
Throws:
WTException

saveRmtTeamTemplates

private static void saveRmtTeamTemplates(Site rmtSite,
                                         Vector teamTemplateList)
                                  throws WTException
Deprecated. 
Throws:
WTException

refreshTeamTemplateUponFolderProblem

private static void refreshTeamTemplateUponFolderProblem(Site rmtSite,
                                                         Throwable e)
Deprecated. 

refreshRmtTeamTemplateOnSiteChange

private void refreshRmtTeamTemplateOnSiteChange(Site rmtSite,
                                                KeyedEvent keyedEvent)
                                         throws WTException
Deprecated. 
Throws:
WTException

removeThisScheduledItem

private void removeThisScheduledItem(Site rmtSite)
Deprecated. 

addThisScheduledItem

private void addThisScheduledItem(Site toSite,
                                  boolean scheduleUnique)
Deprecated. 

lookForExistingScheduleItem

private boolean lookForExistingScheduleItem()
Deprecated. 
Looks for existing schedule items in the system associated with this replication service.
Reschedule item start time according to user preference (specified in wt.replication.sender.senderstarttime).

Returns:
true if found
false otherwise
Since:
Windchill R6 - build 30

getPropertiesInitialTime

private Timestamp getPropertiesInitialTime(ScheduleItem item)
Deprecated. 
Safely gets initial time according to user specification in wt.properties
That is, initial time for start replication sending services.
If incorrect settings, returns current time.

Parameters:
item - schedule item whose initial time is being set
Returns:
desired Timestamp
Since:
Windchill R6 - build 29