...
This web service acquires a lock for a specified entity, and it can also steal the lock of a specified entity that is already locked at the time this service is run.
Request Format
...
Panel | ||
---|---|---|
|
...
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/">
<soapenv:Header/>
<soapenv:Body>
<pws:PwsAcquireProjectorLocks>
<pws:serviceRequest>
<req:RequestId>1</req:RequestId>
<req:SessionTicket>AYlq2lioh82F1PapkJ+Npg==</req:SessionTicket>
| ||||||
| ||||||
|
Request Elements
Element | Data Type | Required? | Default | Description | Sample Data |
---|---|---|---|---|---|
RequestId | Int32 | No |
| Click here for more information | 1 |
SessionTicket | String (50) | Yes |
| Click here for more information | AYlq2lioh82F1PapkJ+Npg== |
LockDurationSeconds | Int32 | Yes |
| The number of seconds the lock will be held must be between 1 second and 1 day (86400) | 120 |
Locks | Yes |
| The detailed information of the lock that is to be acquired | ||
LocksToSteal | No |
| The detailed information of the lock that is to be stolen | ||
ProjectorLockSetId | Int32 | No |
| A unique identifier of a lock on an entity |
Request Usage Example(s)
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/"> <soapenv:Header/> <soapenv:Body> <pws:PwsAcquireProjectorLocks> <req:LockDurationSeconds>120</req:LockDurationSeconds> <pws:serviceRequest> <req:Locks> <req:RequestId>1</req:RequestId> <com:PwsProjectorLockRequest><req:SessionTicket>AYlq2lioh82F1PapkJ+Npg==</req:SessionTicket> <req:LockDurationSeconds>120</req:LockDurationSeconds> <com:EntityIdentity> <req:Locks> <com:EntityCode>P001468-001</com:EntityCode> PwsProjectorLockRequest> <com:EntityUid>1152921504607429941</com:EntityUid>EntityIdentity> <com:LockType>P<EntityCode>P001468-001</com:LockType>EntityCode> <com:EntityUid>1152921504607429941</com:EntityUid> <com:LockType>P</com:LockType> </com:EntityIdentity> </com:PwsProjectorLockRequest> </req:Locks> </pws:serviceRequest> </pws:PwsAcquireProjectorLocks> </soapenv:Body> </soapenv:Envelope> |
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:pws="http://projectorpsa.com/PwsProjectorServices/" xmlns:req="http://projectorpsa.com/DataContracts/Requests/" xmlns:com="http://projectorpsa.com/DataContracts/Shared/Common/">
<soapenv:Header/>
<soapenv:Body>
<pws:PwsAcquireProjectorLocks>
<pws:serviceRequest>
<req:RequestId>1</req:RequestId>
<req:SessionTicket>AYlq2lioh82F1PapkJ+Npg==</req:SessionTicket>
<req:LockDurationSeconds>120</req:LockDurationSeconds>
<req:Locks>
<com:PwsProjectorLockRequest>
<com:EntityIdentity>
<com:EntityCode>P001468-001</com:EntityCode>
<com:EntityUid>1152921504607429941</com:EntityUid>
<com:LockType>P</com:LockType>
</com:EntityIdentity>
</com:PwsProjectorLockRequest>
</req:Locks>
<req:LocksToSteal>
<com:PwsEntityLockSummary>
<com:EntityIdentity>
<com:EntityCode>P001468-001</com:EntityCode>
<com:EntityUid>1152921504607429941</com:EntityUid>
<com:LockType>P</com:LockType>
</com:EntityIdentity>
<com:EntityLockSummary>
<com:PwsEntityLockSummaryItem>
<com:LockCount>1</com:LockCount>
<com:LockHolderUserIdentity>
<com:UserDisplayName>IT Manager</com:UserDisplayName>
<com:UserReferenceSystemId>IT Manager</com:UserReferenceSystemId>
</com:LockHolderUserIdentity>
<com:MostRecentLockAcquisitionTimestamp>2018-10-16T13:59:12.903Z</com:MostRecentLockAcquisitionTimestamp>
</com:PwsEntityLockSummaryItem>
</com:EntityLockSummary>
</com:PwsEntityLockSummary>
</req:LocksToSteal>
</pws:serviceRequest>
</pws:PwsAcquireProjectorLocks>
</soapenv:Body>
</soapenv:Envelope> |
Response Format
Response Elements
...
</soapenv:Body>
</soapenv:Envelope> |
Response Format
Panel | ||
---|---|---|
| ||
|
Response Elements
Element | Data Type | Description | Sample Data |
---|---|---|---|
Messages | The web service response status and message. Click here for more information | ||
ResponseId | Int32 | Click here for more information | 1 |
Status | RequestStatus | Click here for more information | Ok |
ServerTimestampUtc | DateTime | Click here for more information | 2018-10-16T17:28:12.1700152Z |
Locks | The complete set of information about the lock | ||
ProjectorLockSetId | Int32 | A unique identifier of a lock on an entity | 2602 |
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"> <s:Body> <PwsAcquireProjectorLocksResponse xmlns="http://projectorpsa.com/PwsProjectorServices/"> <PwsAcquireProjectorLocksResult xmlns:a="http://projectorpsa.com/DataContracts/Responses/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"> <Messages xmlns="http://projectorpsa.com/CommonServices/" xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"/> <ResponseId xmlns="http://projectorpsa.com/CommonServices/">1</ResponseId> <Status xmlns="http://projectorpsa.com/CommonServices/">Ok</Status> <ServerTimestampUtc xmlns="http://projectorpsa.com/CommonServices/">2018-10-16T17:28:12.1700152Z</ServerTimestampUtc> <a:Locks xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/"> <b:PwsProjectorLock> <b:EntityIdentity> <b:EntityCode>P001468-001</b:EntityCode> <b:EntityId i:nil="true"/> <b:EntityUid>1152921504607429941</b:EntityUid> <b:LockType>P</b:LockType> </b:EntityIdentity> <b:EntityTimestamp>AAAAABCnqW4=</b:EntityTimestamp> <b:LockStolenFlag>false</b:LockStolenFlag> <b:StolenLocks/> </b:PwsProjectorLock> </a:Locks> <a:ProjectorLockSetId>2602</a:ProjectorLockSetId> </PwsAcquireProjectorLocksResult> </PwsAcquireProjectorLocksResponse> </s:Body> </s:Envelope> |
Response Usage Example(s)
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"> <s:Body> <s:Fault> <faultcode>s:Client</faultcode> <faultstring xml:lang="en-US">The creator of this fault did not specify a Reason.</faultstring> <detail> <PwsFault xmlns="http://projectorpsa.com/DataContracts/Shared/Common/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"> <Messages> <PwsMessage> <AdditionalErrorText>Error 50469: EntityAlreadyLocked</AdditionalErrorText> <ErrorCode>EntityAlreadyLocked</ErrorCode> <ErrorNumber>50469</ErrorNumber> <ErrorText>One or more existing locks prevent acquisition of requested lock.</ErrorText> <Type>Error</Type> <ReferenceId1 i:nil="true"/> <ReferenceId2 i:nil="true"/> </PwsMessage> </Messages> <ResponseId>1</ResponseId> <ServiceName>PwsAcquireProjectorLocksRs</ServiceName> <LockHolderUserIdentity> <UserDisplayName>IT Manager</UserDisplayName> <UserId i:nil="true"/> <UserReferenceSystemId>IT Manager</UserReferenceSystemId> <UserUid>1152921504607134339</UserUid> </LockHolderUserIdentity> <LockHolders> <PwsEntityLockSummary> <EntityIdentity> <EntityCode>P001468-001</EntityCode> <EntityId i:nil="true"/> <EntityUid>1152921504607429941</EntityUid> <LockType>P</LockType> </EntityIdentity> <EntityLockSummary> <PwsEntityLockSummaryItem> <LockCount>1</LockCount> <LockHolderUserIdentity> <UserDisplayName>IT Manager</UserDisplayName> <UserId i:nil="true"/> <UserReferenceSystemId>IT Manager</UserReferenceSystemId> <UserUid>1152921504607134339</UserUid> </LockHolderUserIdentity> <MostRecentLockAcquisitionTimestamp>2018-10-16T17:34:43.037Z</MostRecentLockAcquisitionTimestamp> </PwsEntityLockSummaryItem> </EntityLockSummary> </PwsEntityLockSummary> </LockHolders> <LockTaker i:nil="true"/> </PwsFault> </detail> </s:Fault> </s:Body> </s:Envelope> |
...