QueryDynamic

The QueryDynamic activity is used to retrieve entries with parameters. The parameters can be outputs of a process.

General

In the General tab, you can specify the activity name and a metaspace connection.

The following table describes the fields in the General tab of the QueryDynamic activity:

Field Module Property? Description
Name No Specifies the name to be displayed as the label for the activity in the process.
Metaspace Yes Specifies the metaspace connection you use to connect to the metaspace.
Note: If no matching metaspace is found, click Create Shared Resource to create one.

See Creating a Metaspace Connection for details.

Timeout(milliseconds) Yes Specifies the amount of time in milliseconds that you have to wait before the QueryDynamic activity returns results.
Note: The default value is 60000 milliseconds. If the value is -1 or smaller than -1, it indicates waiting indefinitely.

If the field is blank, the value of the field is -1. If the value is 0, an error message is displayed.

Description

In the Description tab, you can enter a short description for the QueryDynamic activity.

Advanced

In the Advanced tab, you can specify the advanced configurations.

The following table describes the fields in the Advanced tab of the QueryDynamic activity:

Field Module Property? Description
DistributionScope Yes Select a distribution scope to narrow down the set of entries to be browsed:
  • ALL: retrieves all the entries in the space. By default, this option is selected.
  • SEEDED: retrieves only the entries actually distributed to the member when this activity is invoked.
DistributionRole Yes Select a distribution role, which defines the way an application or agent joins the space:
  • SEEDER: a member that joins a space and lends resources, such as memory and processing power, to the scalability of the space. By default, this option is selected.
  • LEECH: a member that joins a space but does not lend any resources, such as memory or processing power, to the space.
BrowserType Yes Select a browser type from the following options:
  • GET: retrieves the matched entries. By default, this option is selected.
  • TAKE: retrieves the matched entries and removes them.
  • LOCK: retrieves the matched entries and locks them.
Note: Only the GET option is available when you select CURRENT from the TimeScope list.
Prefetch Yes Specifies the number of records that are prefetched for each seeder in parallel with the processing of the result tuples.
Note: The default value is 1000. The special value of -1 indicates that the entire result set is pushed to the client at once.
TimeScope Yes Select a time scope to narrow down the period of time of interest:
  • SNAPSHOT: the browser starts with all the tuples in the space when the browser is created, instead of being updated with new tuples that are put into the space.
  • CURRENT: the client applications create queries that return large result sets using less resources. By default, this option is selected.
QueryLimit Yes Specifies the number of tuples returned from a dynamic query operation.

The value of -2 indicates that the value specified in the Query Limit field in the Advanced tab of the Space shared resource is used.

The value of -1 indicates that all the matched tuples are retrieved.

This field is displayed only when you select SNAPSHOT from the TimeScope list in the Advanced tab.

Input

In the Input tab, you can specify the filter and the number of tuples returned from a dynamic query operation in the following items:

Input Item Data Type Description
Space String Specifies the space name.
Filter String Specifies a filter string.
DistributionScope String Specifies the distribution scope to narrow down the set of entries to be browsed.
DistributionRole String Specifies a distribution role, which defines how an application or agent joins the space.
BrowserType String Specifies a browser type.
TimeScope String Specifies the time scope to narrow down the period of time of interest.
Prefetch Integer Specifies the number of records that are prefetched for each seeder in parallel with the processing of the result tuples.
QueryLimit Integer Specifies the number of tuples returned from a dynamic query operation.

Output

In the Output tab, you can find the operation results.

The following table describes the fields in the Output tab of the QueryDynamic activity:

Output Item Data Type Description
Tuple String Indicates the matched tuple in the associated space.
TotalCount Long Indicates the number of returned tuples.
IsPartialResult String Indicates whether the returned tuples are partial.
  • The value of true indicates that the returned tuples are partial.
  • The value of false indicates that the returned tuples are not partial.
Note: If you select CURRENT from the TimeScope list, IsPartialResult is displayed as a dash (--).

Fault

In the Fault tab, you can find the error code and error message of the QueryDynamic activity. See Error Codes for more detailed explanation of the errors.

The following table describes the errors in the Fault tab of the QueryDynamic activity:

Error Schema Element Data Type Description
msg String The TIBCO ActiveMatrix BusinessWorks Plug-in for ActiveSpaces error message.
msgCode String The TIBCO ActiveMatrix BusinessWorks Plug-in for ActiveSpaces error code.
ASStatus String The status code returned by TIBCO ActiveSpaces functions.

See TIBCO ActiveSpaces Java API Reference for more information.