Class Message
A message is a task, a notification, or any meaningful data that gets posted
to the queue. A message exists until it is deleted by a recipient or
automatically by the system based on a TTL (time-to-live) value.
-
OpenCloud\Common\Base
-
OpenCloud\Common\PersistentObject
-
OpenCloud\Queues\Resource\Message
Methods summary
public
OpenCloud\Queues\Resource\Message
|
#
setHref( string $href )
Set href (and ID).
Parameters
Returns
|
public
|
#
createJson( )
Returns an object for the Create() method JSON Must be overridden in a child
class.
Returns an object for the Create() method JSON Must be overridden in a child
class.
Throws
CreateError if not overridden
Overrides
|
public
HttpResponse
|
#
create( array $params = array() )
Creates a new object
Parameters
- $params
array $params array of values to set when creating the object
Returns
HttpResponse
Throws
VolumeCreateError if HTTP status is not Success
Overrides
|
public
HttpResponse
|
#
update( array $params = array() )
Updates an existing object
Updates an existing object
Parameters
- $params
array $params array of values to set when updating the object
Returns
HttpResponse
Throws
VolumeCreateError if HTTP status is not Success
Api
Overrides
|
public
boolean
|
#
delete( string $claimId = null )
This operation immediately deletes the specified message.
This operation immediately deletes the specified message.
Parameters
- $claimId
string $claimId Specifies that the message should be deleted only if it has the
specified claim ID, and that claim has not expired. This is useful for ensuring
only one agent processes any given message. Whenever a worker client's claim
expires before it has a chance to delete a message it has processed, the worker
must roll back any actions it took based on that message because another worker
will now be able to claim and process the same message. If you do not
specify $claimId, but the message is claimed, the operation fails. You can only
delete claimed messages by providing an appropriate $claimId.
Returns
boolean
Throws
Overrides
|
Methods inherited from OpenCloud\Common\PersistentObject
__construct(),
action(),
checkExtension(),
createUrl(),
findLink(),
getClient(),
getMetadata(),
getParent(),
getService(),
getUrl(),
id(),
jsonCollectionElement(),
jsonCollectionName(),
jsonName(),
name(),
noCreate(),
noDelete(),
noUpdate(),
parseResponse(),
primaryKeyField(),
refresh(),
refreshFromLocationUrl(),
region(),
resourceName(),
setMetadata(),
setParent(),
setService(),
status(),
updateJson(),
url(),
waitFor()
|
Methods inherited from OpenCloud\Common\Base
__call(),
checkJsonError(),
generateUuid(),
getLogger(),
getProperty(),
makeResourceIteratorOptions(),
populate(),
propertyExists(),
setLogger(),
setProperty(),
stripNamespace(),
toCamel(),
toUnderscores()
|