History | View | Annotate | Download (15 kB)
Also consider filter fields for deciding if using live data
If the query fields don't require live data, we use the shortcutand don't request live data. However, we cannot take this shortcutif the fields the filter depends on requires live data.
Signed-off-by: Klaus Aehlig <aehlig@google.com>...
Implement fields query for instance
Support the query for the fields available for instances.
Signed-off-by: Klaus Aehlig <aehlig@google.com>Reviewed-by: Petr Pudlak <pudlak@google.com>
When interpreting [] as "all fields", sort nicely
When asked for all fields, we promise to return the list of fieldssorted according to niceSort. Keep this promise.
Use hypervisor / storage information only when requested
So far, the node queries ignored the list of fields andjust requested all available information from the backend.That means, for example if only hypervisor information isrequested, still the storage space calculation is...
Optimize instance query speed
The instance queries have a field called console which requires anextra RPC call. This commit allows extra parameters to be passed onto the query logic, which allows us to determine when to make theextra call.
Signed-off-by: Hrvoje Ribicic <riba@google.com>...
Add the first instance query live fields
This patch adds live fields which can be implemented with the existingRPC calls. Some fields require additional call types and will be addedlater. Most of them can be added at this point.The status field is especially interesting, as it depends not on the...
Add a new field type - FieldConfigRuntime
In the instance queries, some fields require both config and runtimeinformation. This patch adds a new field type for this purpose.
Signed-off-by: Hrvoje Ribicic <riba@google.com>Reviewed-by: Jose A. Lopes <jabolopes@google.com>
Unify all live calls which return no data
With the (current) instance query, there are three queries which do notrequire live data: instance, network, and group queries.The collectors and runtime types for these have been unified.
Initial changes for adding instance queries
Add basic instance querying capabilities to the Haskell codebase.Several fields are present, more to come.
Document the generic query function
The way the generic query works was not documented anywhere. Forgreater readability, add a short explanation to the genericQueryfunction.
Merge branch 'devel-2.7'
Properly export errors while reading job list
In case of problems while reading the job list from disk (such as permissionerrors) confd would silently fail, writing a warning on the log file butsending an empty list and no error message to the client....
Abstract the individual query functions
After implementing a few of the query executor functions, it turns outthat we have the same general pattern:
- compile the filter- extract the selected fields- determine whether we need to run collectors- do a first pass filtering...
Allow confd to serve network list-fields queries
The fields are not yet complete, but at least we can enable thelist-field query to see what is there already.
Signed-off-by: Iustin Pop <iustin@google.com>Reviewed-by: Guido Trotter <ultrotter@google.com>
Rename/make uniform the other query entities
Following the new naming style introduced in Exports.hs, this patchrenames the other resources to export non-qualified names (fieldMap asopposed to nodeFieldMap), and to use qualified module imports.
Also fixes a haddock issue in a docstring....
Implement Export queries in Haskell
This is a simple query as it has only two fields, however it's thefirst query that doesn't have a clear 'base' object and 1:1correspondence between such objects and the results (groups, nodes andnetworks do so).
We keep nodes as the 'base' object, since that's what we want to...
First part of Network Queries in Haskell
This is the beginning of the implementation of networkqueries. This includes establishing all infrastructureto run the network queries and implement querying ofsome simpler fields and the node group listing.
Signed-off-by: Helga Velroyen <helgav@google.com>...
Rename htools/ to src/
Per offline discussions, this is the first patch of therenames. Tested with "make distcheck", seems to work fine.
The only change outside of the renaming is a bit of simplification inthe .gitignore rules; otherwise, simply s/htools/src/....