摘要:
Techniques for fast and scalable generation and aggregation of XML data are described. In an example embodiment, an XML query that requests data from XML documents is received. The XML query is evaluated to determine one or more XML results. For each particular XML result, evaluating the XML query comprises: instantiating a particular data structure that represents the particular XML result, where the particular data structure is encoded in accordance with tags specified in the XML query but does not store the tags; and storing, in the particular data structure, one or more locators that respectively point to one or more fragments in the XML documents, where the particular data structure stores the one or more locators but does not store the one or more fragments. On demand, in response to a request indicating the particular XML result, a serialized representation of the particular XML result is generated based at least on the particular data structure.
摘要:
Techniques for fast and scalable generation and aggregation of XML data are described. In an example embodiment, an XML query that requests data from XML documents is received. The XML query is evaluated to determine one or more XML results. For each particular XML result, evaluating the XML query comprises: instantiating a particular data structure that represents the particular XML result, where the particular data structure is encoded in accordance with tags specified in the XML query but does not store the tags; and storing, in the particular data structure, one or more locators that respectively point to one or more fragments in the XML documents, where the particular data structure stores the one or more locators but does not store the one or more fragments. On demand, in response to a request indicating the particular XML result, a serialized representation of the particular XML result is generated based at least on the particular data structure.
摘要:
Techniques are provided to achieve performance improvements for path-based access to hierarchical data and for utilizing an extensible indexing framework. Extensible operators may be optimized by evaluating the operators using functions native to the database system instead of using functions defined through an extensible indexing mechanism. Furthermore, the database system may resolve a resource path of a query when the query is compiled, and may store the mapping of the resource path to one or more resources in a cursor for the query execution plan to avoid resolving the resource path each time the cursor is used to run the query. The cursor may be made dependent on the one or more resources to which the resource path refers at compile time. This takes advantage of the observation that the mapping of the resource path to particular resources rarely changes between evaluations of a particular query.
摘要:
Techniques are provided to achieve performance improvements for path-based access to hierarchical data and for utilizing an extensible indexing framework. Extensible operators may be optimized by evaluating the operators using functions native to the database system instead of using functions defined through an extensible indexing mechanism. Furthermore, the database system may resolve a resource path of a query when the query is compiled, and may store the mapping of the resource path to one or more resources in a cursor for the query execution plan to avoid resolving the resource path each time the cursor is used to run the query. The cursor may be made dependent on the one or more resources to which the resource path refers at compile time. This takes advantage of the observation that the mapping of the resource path to particular resources rarely changes between evaluations of a particular query.
摘要:
A two-level cache to facilitate resolving resource path expressions for a hierarchy of resources is described, which includes a system-wide shared cache and a session-level cache. The shared cache is organized as a hierarchy of hash tables that mirrors the structure of a repository hierarchy. A particular hash table in a shared cache includes information for the child resources of a particular resource. A database management system that manages a shared cache may control the amount of memory used by the cache by implementing a replacement policy for the cache based on one or more characteristics of the resources in the repository. The session-level cache is a single level cache in which information for target resources of resolved path expressions may be tracked. In the session-level cache, the resource information is associated with the entire path expression of the associated resource.
摘要:
Techniques are provided for efficiently collecting statistics for hierarchically-organized collections of data. A database system leverages container-level modification time stamps and stored subtree-level change information to gather statistical information from only those resources in a hierarchical collection for which the statistics have changed since the last time that statistics were gathered for the collection. A lockless data structure is also described for storing the subtree-level change information in which an identifier corresponding to each subtree in a collection containing a changed resource may be stored. This data structure may be a table that is distinct from one or more tables representing the collection. In one embodiment of the invention, the immediate parent resource of a particular modified resource may be omitted from the subtree table by leveraging modification time stamps while gathering statistics based on tracked subtree-level information.
摘要:
Techniques are provided to achieve performance improvements for path-based access to hierarchical data and for utilizing an extensible indexing framework. Extensible operators may be optimized by evaluating the operators using functions native to the database system instead of using functions defined through an extensible indexing mechanism. Furthermore, the database system may resolve a resource path of a query when the query is compiled, and may store the mapping of the resource path to one or more resources in a cursor for the query execution plan to avoid resolving the resource path each time the cursor is used to run the query. The cursor may be made dependent on the one or more resources to which the resource path refers at compile time. This takes advantage of the observation that the mapping of the resource path to particular resources rarely changes between evaluations of a particular query.
摘要:
One embodiment of the present invention provides a system for efficiently evaluating a security policy. During operation, the system retrieves one or more roles associated with the user. Next, the system checks if a session-level cache exists for a set of Access Control Entries (ACEs) which is associated with the one or more roles. If this session-level cache exists, the system returns the set of ACEs from the session-level cache. Otherwise, the system generates the set of ACEs associated with the one or more roles from an Access Control List (ACL). During operation, the system can also update the one or more roles associated with the user and update the set of ACEs based on the updated one or more roles and the ACL. The system subsequently updates the session level cache with the updated set of ACEs and updated one or more roles.
摘要:
One embodiment of the present invention provides a system for efficiently evaluating a security policy. During operation, the system retrieves one or more roles associated with the user. Next, the system checks if a session-level cache exists for a set of Access Control Entries (ACEs) which is associated with the one or more roles. If this session-level cache exists, the system returns the set of ACEs from the session-level cache. Otherwise, the system generates the set of ACEs associated with the one or more roles from an Access Control List (ACL). During operation, the system can also update the one or more roles associated with the user and update the set of ACEs based on the updated one or more roles and the ACL. The system subsequently updates the session level cache with the updated set of ACEs and updated one or more roles.
摘要:
Techniques are provided to achieve performance improvements for path-based access to hierarchical data and for utilizing an extensible indexing framework. Extensible operators may be optimized by evaluating the operators using functions native to the database system instead of using functions defined through an extensible indexing mechanism. Furthermore, the database system may resolve a resource path of a query when the query is compiled, and may store the mapping of the resource path to one or more resources in a cursor for the query execution plan to avoid resolving the resource path each time the cursor is used to run the query. The cursor may be made dependent on the one or more resources to which the resource path refers at compile time. This takes advantage of the observation that the mapping of the resource path to particular resources rarely changes between evaluations of a particular query.