Code

sysdb.git
9 years agostore: Drop the global (default) store.
Sebastian Harl [Sat, 8 Aug 2015 07:34:56 +0000 (09:34 +0200)]
store: Drop the global (default) store.

Instead, register a store from sysdbd and make sure to re-register it on
reconfigure. Previously, the store plugin would have been dropped in that
case.

9 years agostore: All store functions now accept a store object.
Sebastian Harl [Fri, 7 Aug 2015 16:26:51 +0000 (18:26 +0200)]
store: All store functions now accept a store object.

That is, instead of operating on a global, shared instance.

9 years agostore: Add wrapper functions to store an object in an arbitrary store.
Sebastian Harl [Thu, 6 Aug 2015 15:39:45 +0000 (17:39 +0200)]
store: Add wrapper functions to store an object in an arbitrary store.

9 years agocore: Export the sdb_store, sdb_store_reader, sdb_store_writer types.
Sebastian Harl [Thu, 6 Aug 2015 15:22:31 +0000 (17:22 +0200)]
core: Export the sdb_store, sdb_store_reader, sdb_store_writer types.

This is in preparation to more flexible store handling.

9 years agot/valgrind.suppress: Refine the suppression in the libc exit handler.
Sebastian Harl [Thu, 6 Aug 2015 06:56:24 +0000 (08:56 +0200)]
t/valgrind.suppress: Refine the suppression in the libc exit handler.

9 years agofrontend: Use the plugin query interface instead of direct store access.
Sebastian Harl [Wed, 5 Aug 2015 08:45:11 +0000 (10:45 +0200)]
frontend: Use the plugin query interface instead of direct store access.

The built-in store is registered as a reader automatically at the moment.

9 years agocore: Add support for reader/query plugins.
Sebastian Harl [Wed, 5 Aug 2015 08:38:48 +0000 (10:38 +0200)]
core: Add support for reader/query plugins.

A reader plugin can be used to query a data-store based on a query described
by an AST. The plugin module provides a generic function for this purpose.

At the moment, only a single reader plugin can be used at a time. Supporting
multiple readers requires a good merge strategy. The challenge is to handle
filters and query conditions correctly which may evaluate differently after
two stores have been merged.

9 years agot/valgrind.suppress: Add an invalid free in a libc exit handler.
Sebastian Harl [Tue, 4 Aug 2015 07:13:47 +0000 (09:13 +0200)]
t/valgrind.suppress: Add an invalid free in a libc exit handler.

9 years agoplugin: Drop sdb_plugin prefix from private names.
Sebastian Harl [Thu, 28 May 2015 08:29:21 +0000 (10:29 +0200)]
plugin: Drop sdb_plugin prefix from private names.

9 years agostore_exec: Remove unnecessary casts.
Sebastian Harl [Thu, 28 May 2015 08:08:45 +0000 (10:08 +0200)]
store_exec: Remove unnecessary casts.

9 years agostore: Let sdb_store_json_formatter_t inherit from sdb_object_t.
Sebastian Harl [Wed, 27 May 2015 20:49:20 +0000 (22:49 +0200)]
store: Let sdb_store_json_formatter_t inherit from sdb_object_t.

9 years agoDrop sdb_store_get_host() from tests.
Sebastian Harl [Wed, 27 May 2015 20:48:21 +0000 (22:48 +0200)]
Drop sdb_store_get_host() from tests.

9 years agostore: Drop unused sdb_store_has_host.
Sebastian Harl [Fri, 22 May 2015 07:21:26 +0000 (09:21 +0200)]
store: Drop unused sdb_store_has_host.

9 years agoReplaced sdb_store_<type> with sdb_plugin_store_<type>.
Sebastian Harl [Thu, 21 May 2015 22:47:24 +0000 (00:47 +0200)]
Replaced sdb_store_<type> with sdb_plugin_store_<type>.

That is, all store updates will now directly go through the plugin API and be
distributed to all store-writer plugins from there.

9 years agoMerged branch 'master' of git://git.tokkee.org/sysdb.
Sebastian Harl [Thu, 21 May 2015 22:46:58 +0000 (00:46 +0200)]
Merged branch 'master' of git://git.tokkee.org/sysdb.

9 years agostore: Register a store writer and handle all updates through the plugin API.
Sebastian Harl [Thu, 21 May 2015 22:18:25 +0000 (00:18 +0200)]
store: Register a store writer and handle all updates through the plugin API.

We still reference a global store object. This change further encapsulates the
store.

9 years agoplugin: sdb_plugin_store_* now return >0 if the new value was too old.
Sebastian Harl [Thu, 21 May 2015 22:16:04 +0000 (00:16 +0200)]
plugin: sdb_plugin_store_* now return >0 if the new value was too old.

That is, the return values now mean the same as for the sdb_store_* functions.

9 years agostore: Reordered some functions to group by general purpose.
Sebastian Harl [Thu, 21 May 2015 21:42:11 +0000 (23:42 +0200)]
store: Reordered some functions to group by general purpose.

9 years agoFix an uninitialized value warnings caused by clang not knowing about fail().
Sebastian Harl [Thu, 21 May 2015 21:39:22 +0000 (23:39 +0200)]
Fix an uninitialized value warnings caused by clang not knowing about fail().

9 years agostore: Make the actual store a separate object.
Sebastian Harl [Thu, 21 May 2015 21:36:57 +0000 (23:36 +0200)]
store: Make the actual store a separate object.

That'll allow us to use different store objects in multiple places in the
future.

9 years agostore: Drop sdb_ prefix from private symbols.
Sebastian Harl [Thu, 21 May 2015 18:17:42 +0000 (20:17 +0200)]
store: Drop sdb_ prefix from private symbols.

9 years agodata: Use a predefined format for sdb_strftime().
Sebastian Harl [Wed, 20 May 2015 21:53:48 +0000 (23:53 +0200)]
data: Use a predefined format for sdb_strftime().

Also, print the nanosecond fraction of a second.

9 years agot/: Use ck_assert() instead of assert() in all tests.
Sebastian Harl [Wed, 20 May 2015 20:04:54 +0000 (22:04 +0200)]
t/: Use ck_assert() instead of assert() in all tests.

9 years agosysdbql(7): Document 'value' and 'timeseries' fields.
Sebastian Harl [Wed, 20 May 2015 09:36:37 +0000 (11:36 +0200)]
sysdbql(7): Document 'value' and 'timeseries' fields.

9 years agoparser: Add support for metric timeseries fields.
Sebastian Harl [Wed, 20 May 2015 08:35:29 +0000 (10:35 +0200)]
parser: Add support for metric timeseries fields.

9 years agostore: Add the timeseries field to metrics.
Sebastian Harl [Wed, 20 May 2015 08:34:27 +0000 (10:34 +0200)]
store: Add the timeseries field to metrics.

This is a boolean field that specifies whether a timeseries for the metric is
known to SysDB.

9 years agoparser: Skip context-specific checks if the context is unspecified.
Sebastian Harl [Wed, 20 May 2015 08:32:37 +0000 (10:32 +0200)]
parser: Skip context-specific checks if the context is unspecified.

Else, the analyzer may reject valid queries. It's up to the caller to run the
analyzer using the right context once it's known.

9 years agostore: Remove (now unused) sdb_store_parse_*() helpers.
Sebastian Harl [Wed, 20 May 2015 06:49:38 +0000 (08:49 +0200)]
store: Remove (now unused) sdb_store_parse_*() helpers.

9 years agostore: Remove (now unused) sdb_store_nin_matcher().
Sebastian Harl [Wed, 20 May 2015 06:48:42 +0000 (08:48 +0200)]
store: Remove (now unused) sdb_store_nin_matcher().

9 years agosysdbql(7): Document IS [NOT] TRUE / FALSE.
Sebastian Harl [Tue, 19 May 2015 21:17:11 +0000 (23:17 +0200)]
sysdbql(7): Document IS [NOT] TRUE / FALSE.

9 years agoparser: Add support for <expr> IS [NOT] TRUE / FALSE queries.
Sebastian Harl [Tue, 19 May 2015 21:11:35 +0000 (23:11 +0200)]
parser: Add support for <expr> IS [NOT] TRUE / FALSE queries.

9 years agostore: Add support for unary IS TRUE / IS FALSE matchers.
Sebastian Harl [Tue, 19 May 2015 21:08:30 +0000 (23:08 +0200)]
store: Add support for unary IS TRUE / IS FALSE matchers.

9 years agostore: Drop the special IS-NOT-NULL matcher.
Sebastian Harl [Tue, 19 May 2015 20:28:49 +0000 (22:28 +0200)]
store: Drop the special IS-NOT-NULL matcher.

In the AST world, this is NOT(IS-NULL).

9 years agoutils/proto: Support boolean values.
Sebastian Harl [Tue, 19 May 2015 20:11:50 +0000 (22:11 +0200)]
utils/proto: Support boolean values.

They are encoded as a single byte on the wire.

9 years agodata: Add basic support for a boolean type.
Sebastian Harl [Tue, 19 May 2015 19:42:20 +0000 (21:42 +0200)]
data: Add basic support for a boolean type.

This change breaks backward compatibility of the network protocol because it
changes the encoding of a datum. I felt this is still acceptable (given the
current (non-)compatibility promise) and it made the order of types feel more
natural ;-)

9 years agoDrop the old frontend parser.
Sebastian Harl [Tue, 19 May 2015 18:10:22 +0000 (20:10 +0200)]
Drop the old frontend parser.

It's fully replaced by the new parser module now.

9 years agostore: Add sdb_store_query_prepare_matcher().
Sebastian Harl [Tue, 19 May 2015 18:08:56 +0000 (20:08 +0200)]
store: Add sdb_store_query_prepare_matcher().

This prepares a logical expression described by an AST for execution as a
store matcher. This is useful for anything that uses the lower level store
lookup functions.

9 years agofrontend: Drop sdb_fe_store_* in favor of sdb_store_query_execute.
Sebastian Harl [Mon, 18 May 2015 21:57:06 +0000 (23:57 +0200)]
frontend: Drop sdb_fe_store_* in favor of sdb_store_query_execute.

Instead, build a temporary AST to represent the command to be executed.

9 years agofrontend: Drop sdb_fe_exec_* in favor of sdb_store_query_execute.
Sebastian Harl [Mon, 18 May 2015 21:14:54 +0000 (23:14 +0200)]
frontend: Drop sdb_fe_exec_* in favor of sdb_store_query_execute.

Instead, build a temporary AST to represent the command to be executed.

9 years agoRemove (now) usued sdb_fe_exec_timeseries().
Sebastian Harl [Mon, 18 May 2015 20:50:19 +0000 (22:50 +0200)]
Remove (now) usued sdb_fe_exec_timeseries().

9 years agofrontend/query_test: Add tests for the lower level functions.
Sebastian Harl [Mon, 18 May 2015 20:48:57 +0000 (22:48 +0200)]
frontend/query_test: Add tests for the lower level functions.

9 years agofrontend/query: Split AST execution into a separate function.
Sebastian Harl [Mon, 18 May 2015 19:18:40 +0000 (21:18 +0200)]
frontend/query: Split AST execution into a separate function.

9 years agostore: Use a separate type for prepared querys.
Sebastian Harl [Mon, 18 May 2015 19:04:18 +0000 (21:04 +0200)]
store: Use a separate type for prepared querys.

It's sufficiently different from the general matchers/filters approach to not
benefit from sharing a base type.

9 years agostore, frontend: Add sdb_store_query_execute use it instead of sdb_fe_exec.
Sebastian Harl [Sun, 17 May 2015 19:58:03 +0000 (21:58 +0200)]
store, frontend: Add sdb_store_query_execute use it instead of sdb_fe_exec.

This new function executes a generic QUERY matcher as returned by
sdb_store_query_prepare and writes the reply to a string buffer.

9 years agoMerged branch 'master' of git://git.tokkee.org/sysdb.
Sebastian Harl [Fri, 15 May 2015 20:53:44 +0000 (22:53 +0200)]
Merged branch 'master' of git://git.tokkee.org/sysdb.

9 years agofrontend/query_test: Test various QUERY functions.
Sebastian Harl [Fri, 15 May 2015 20:41:43 +0000 (22:41 +0200)]
frontend/query_test: Test various QUERY functions.

These will, in turn, call the sdb_fe_exec_<CMD> functions, thus guaranteeing
good test coverage.

9 years agofrontend: Fixed reply from STORE command.
Sebastian Harl [Fri, 15 May 2015 20:40:00 +0000 (22:40 +0200)]
frontend: Fixed reply from STORE command.

9 years agostore: Fixed a memory leak in fetch_timeseries().
Sebastian Harl [Fri, 15 May 2015 20:39:26 +0000 (22:39 +0200)]
store: Fixed a memory leak in fetch_timeseries().

9 years agofrontend, parser: Allow typed access to host objects from any context.
Sebastian Harl [Fri, 15 May 2015 19:41:14 +0000 (21:41 +0200)]
frontend, parser: Allow typed access to host objects from any context.

That is, even from the "generic" or "filter" contexts.

9 years agostore: Add sdb_store_query_prepare().
Sebastian Harl [Fri, 15 May 2015 08:03:47 +0000 (10:03 +0200)]
store: Add sdb_store_query_prepare().

This function prepares a query, represented by its AST, for execution in a
store by generating a store matcher.

9 years agostore: Store a service/metric's parent hostname as an attribute.
Sebastian Harl [Thu, 14 May 2015 22:43:12 +0000 (00:43 +0200)]
store: Store a service/metric's parent hostname as an attribute.

9 years agostore: Fixed handling of metric store values.
Sebastian Harl [Thu, 14 May 2015 22:41:12 +0000 (00:41 +0200)]
store: Fixed handling of metric store values.

 - Call sdb_plugin_store_metric() even if store=NULL (don't return early).
 - Don't drop old values if strdup failed when storing store type/id.
 - Fixed a segfault in sdb_plugin_store_metric() when using store=NULL.

9 years agoparser/analyzer: Fixed iterator type checks.
Sebastian Harl [Fri, 8 May 2015 16:49:59 +0000 (18:49 +0200)]
parser/analyzer: Fixed iterator type checks.

Also, added some more test-cases covering affected cases.

9 years agot/coverage: Ignore parser/scanner and parser/grammar.
Sebastian Harl [Wed, 6 May 2015 22:32:35 +0000 (00:32 +0200)]
t/coverage: Ignore parser/scanner and parser/grammar.

9 years agot/Makefile: Update EXTRA_DIST based on recent changes.
Sebastian Harl [Wed, 6 May 2015 22:27:32 +0000 (00:27 +0200)]
t/Makefile: Update EXTRA_DIST based on recent changes.

9 years agoparser/analyzer: Migrate value expression checks.
Sebastian Harl [Wed, 6 May 2015 22:01:42 +0000 (00:01 +0200)]
parser/analyzer: Migrate value expression checks.

The new parser and analyzer now pass the full test-suite of frontend/parser.

9 years agoparser/analyzer: Migrate type and iterator checks.
Sebastian Harl [Wed, 6 May 2015 21:33:52 +0000 (23:33 +0200)]
parser/analyzer: Migrate type and iterator checks.

9 years agoparser: Add support for analyzing conditional and arithmetic expressions.
Sebastian Harl [Tue, 5 May 2015 22:15:49 +0000 (00:15 +0200)]
parser: Add support for analyzing conditional and arithmetic expressions.

Let all parser functions call the respective analyzer. For now, this is only
used to propagate data-type information but it will later ensure a certain
amount of semantical correctness. Note that the new analyzers usually don't
have any context information, so they might accept expressions that are not
right for their later target use case. If that matters, the caller will have
to check again providing the right context.

9 years agoparser: Convert AST op types to data op types when necessary.
Sebastian Harl [Tue, 5 May 2015 22:15:09 +0000 (00:15 +0200)]
parser: Convert AST op types to data op types when necessary.

9 years agoparser: Determine the data-type of each node.
Sebastian Harl [Tue, 5 May 2015 21:52:41 +0000 (23:52 +0200)]
parser: Determine the data-type of each node.

For now, we only use this for arithmetic expressions. The field will be
populated by the analyzer.

9 years agoparser: Fixed setup of iterator nodes.
Sebastian Harl [Tue, 5 May 2015 21:36:14 +0000 (23:36 +0200)]
parser: Fixed setup of iterator nodes.

The iterator value was supposed to be an "incomplete operator" node, that is,
one of the operands should be NULL. This is actually the case now and this
also means we don't have to store the operator type separately.

9 years agoparser/ast: Add some helper defines.
Sebastian Harl [Tue, 5 May 2015 21:33:04 +0000 (23:33 +0200)]
parser/ast: Add some helper defines.

9 years agoMigrate top-level checks to the new parser/analyzer.
Sebastian Harl [Wed, 15 Apr 2015 09:38:26 +0000 (11:38 +0200)]
Migrate top-level checks to the new parser/analyzer.

Call the analyzer from sdb_parser_parse().

9 years agoparser_test: Make sure that TIMESERIES end times are greater than start times.
Sebastian Harl [Wed, 15 Apr 2015 09:29:55 +0000 (11:29 +0200)]
parser_test: Make sure that TIMESERIES end times are greater than start times.

9 years agoparser/grammar: Fix the hostname in a 'FETCH host' node.
Sebastian Harl [Wed, 15 Apr 2015 09:28:53 +0000 (11:28 +0200)]
parser/grammar: Fix the hostname in a 'FETCH host' node.

9 years agoMigrate parser from frontend/ to parser/ and to use the AST.
Sebastian Harl [Sun, 12 Apr 2015 13:12:45 +0000 (15:12 +0200)]
Migrate parser from frontend/ to parser/ and to use the AST.

The new parser now returns AST nodes instead of a "compiled" store lookup
operator. The old parser is still in place unmodified and currently still in
use.

9 years agoparser/ast: Introduce a data-structure representing a SysQL AST.
Sebastian Harl [Sun, 12 Apr 2015 12:45:49 +0000 (14:45 +0200)]
parser/ast: Introduce a data-structure representing a SysQL AST.

This will be used by the parser in the future.

9 years agofrontend/parser: Renamed SDB_PARSE_EXPR to SDB_PARSE_ARITH.
Sebastian Harl [Sat, 11 Apr 2015 16:04:27 +0000 (18:04 +0200)]
frontend/parser: Renamed SDB_PARSE_EXPR to SDB_PARSE_ARITH.

That's a bit more specific ;-)

9 years agobuild system: Fix VPATH (out-of-tree) builds.
Sebastian Harl [Sat, 11 Apr 2015 13:56:04 +0000 (15:56 +0200)]
build system: Fix VPATH (out-of-tree) builds.

9 years agot/cibuild: Ignore missing field initializer warnings for tests.
Sebastian Harl [Sun, 15 Mar 2015 15:18:23 +0000 (11:18 -0400)]
t/cibuild: Ignore missing field initializer warnings for tests.

Old versions of clang and gcc complain about { 0 } initializers even though
they are well defined by C99.

9 years agoquery language: Add support for attribute.value access.
Sebastian Harl [Sun, 15 Mar 2015 14:54:21 +0000 (10:54 -0400)]
query language: Add support for attribute.value access.

9 years agoanalyzer: Improve some error messages.
Sebastian Harl [Sun, 15 Mar 2015 14:45:53 +0000 (10:45 -0400)]
analyzer: Improve some error messages.

9 years agoanalyzer: attributes and backends are always iterable, even in filters.
Sebastian Harl [Sun, 15 Mar 2015 14:40:04 +0000 (10:40 -0400)]
analyzer: attributes and backends are always iterable, even in filters.

Before, this was not allowed because the execution context for a filter is not
know (generic) and this case was to handled separately.

9 years agostore: Added field type VALUE for attribute values.
Sebastian Harl [Sun, 15 Mar 2015 02:05:50 +0000 (22:05 -0400)]
store: Added field type VALUE for attribute values.

9 years agostore: Test get_field() more extensively and fix a small bug.
Sebastian Harl [Sun, 15 Mar 2015 01:46:41 +0000 (21:46 -0400)]
store: Test get_field() more extensively and fix a small bug.

Use a table-driven test now.

9 years agoAdd tests for expression iterators.
Sebastian Harl [Wed, 11 Mar 2015 19:03:46 +0000 (20:03 +0100)]
Add tests for expression iterators.

9 years agostore_expr: iterator: Support constant arrays without a stored object.
Sebastian Harl [Wed, 11 Mar 2015 19:02:07 +0000 (20:02 +0100)]
store_expr: iterator: Support constant arrays without a stored object.

9 years agostore_expr: Fix iter_has_next if the first elements are filtered.
Sebastian Harl [Wed, 11 Mar 2015 19:01:19 +0000 (20:01 +0100)]
store_expr: Fix iter_has_next if the first elements are filtered.

9 years agodata: Let sdb_data_array_get support DATETIME, BINARY, REGEX values.
Sebastian Harl [Wed, 11 Mar 2015 19:00:27 +0000 (20:00 +0100)]
data: Let sdb_data_array_get support DATETIME, BINARY, REGEX values.

9 years agodata: sdb_data_strcmp supports arrays because sdb_data_format supports it.
Sebastian Harl [Wed, 11 Mar 2015 18:59:13 +0000 (19:59 +0100)]
data: sdb_data_strcmp supports arrays because sdb_data_format supports it.

9 years agostore: Use iterable expressions for iterators.
Sebastian Harl [Sun, 8 Mar 2015 21:57:06 +0000 (22:57 +0100)]
store: Use iterable expressions for iterators.

Rather than having a separate iterator implementation in store_lookup.

9 years agostore: When advancing an iterator don't loop endlessly on filtered objects.
Sebastian Harl [Sun, 8 Mar 2015 21:56:09 +0000 (22:56 +0100)]
store: When advancing an iterator don't loop endlessly on filtered objects.

9 years agostore: Apply iterator expressions to the iterated objects.
Sebastian Harl [Sun, 8 Mar 2015 21:52:49 +0000 (22:52 +0100)]
store: Apply iterator expressions to the iterated objects.

9 years agostore: Advance expression iterators even if array access fails.
Sebastian Harl [Sun, 8 Mar 2015 21:47:51 +0000 (22:47 +0100)]
store: Advance expression iterators even if array access fails.

Else, we'd have an endless loop as the caller doesn't know about that.

9 years agostore: Fixed a memory leak in sdb_store_expr_iter_destroy().
Sebastian Harl [Sun, 8 Mar 2015 21:46:45 +0000 (22:46 +0100)]
store: Fixed a memory leak in sdb_store_expr_iter_destroy().

9 years agoLet iterator operators fill in the left operand of child operators.
Sebastian Harl [Sun, 8 Mar 2015 16:15:33 +0000 (17:15 +0100)]
Let iterator operators fill in the left operand of child operators.

This avoids the need for repeating the same operand in two places and better
reflects what's actually going on.

9 years agoLet the first operand of ANY/ALL iterators be an expression.
Sebastian Harl [Sun, 8 Mar 2015 10:56:33 +0000 (11:56 +0100)]
Let the first operand of ANY/ALL iterators be an expression.

For now, the same restrictions apply as before (iterate child objects or the
backends field). This is in preparation for more generic iterators.

9 years agoquery language: Change iterator syntax to ANY/ALL <iter>.<field> <op> <v>.
Sebastian Harl [Sat, 7 Mar 2015 13:14:56 +0000 (14:14 +0100)]
query language: Change iterator syntax to ANY/ALL <iter>.<field> <op> <v>.

That is, make it explicit that iterators access the object name and make it
easier to support other fields as well.

9 years agodata: Return the number of bytes that would have been returned.
Sebastian Harl [Sat, 7 Mar 2015 13:01:17 +0000 (14:01 +0100)]
data: Return the number of bytes that would have been returned.

That is, behave as documented, even if the buffer is NULL or otherwise too
small. Return size_t instead of an integer.

9 years agodata: Let strlen/format handle NULL values correctly.
Sebastian Harl [Sat, 7 Mar 2015 12:56:32 +0000 (13:56 +0100)]
data: Let strlen/format handle NULL values correctly.

9 years agostore: Add support for iterable expressions.
Sebastian Harl [Thu, 5 Mar 2015 20:25:40 +0000 (21:25 +0100)]
store: Add support for iterable expressions.

It can be used to iterate through either the list of child nodes or through
arbitrary arrays. An expression is iterable either if it stores / evaluates to
an array or if it's a typed expression evaluated in the context of an object
where the specified type represents child nodes.

9 years agoavltree: Add sdb_avltree_iter_peek_next().
Sebastian Harl [Thu, 5 Mar 2015 07:13:42 +0000 (08:13 +0100)]
avltree: Add sdb_avltree_iter_peek_next().

The function returns the next element without advancing the iterator.

9 years agoAllow the left operand of comparison operations to be NULL (initially).
Sebastian Harl [Wed, 4 Mar 2015 20:13:49 +0000 (21:13 +0100)]
Allow the left operand of comparison operations to be NULL (initially).

However, when evaluating the expression, the operand has to be set. We'll use
this as a placeholder for inserting values dynamically.

9 years agoanalyzer: Check that all iterators use ary operators.
Sebastian Harl [Wed, 4 Mar 2015 09:54:49 +0000 (10:54 +0100)]
analyzer: Check that all iterators use ary operators.

All iterators are based on a comparison <iter> <op> <expr> and the same
restrictions apply to all of them.

9 years agofrontend/grammar: Fixed format argument used in yyerrorf().
Sebastian Harl [Mon, 2 Mar 2015 06:41:55 +0000 (07:41 +0100)]
frontend/grammar: Fixed format argument used in yyerrorf().

9 years agot/integration: Split query.sh into multiple tests.
Sebastian Harl [Sun, 1 Mar 2015 18:34:14 +0000 (19:34 +0100)]
t/integration: Split query.sh into multiple tests.

9 years agointegration/query.sh: Check that empty commands work fine.
Sebastian Harl [Sun, 1 Mar 2015 18:16:23 +0000 (19:16 +0100)]
integration/query.sh: Check that empty commands work fine.

9 years agoparser_test: Test further error cases and error propagation in the analyzer.
Sebastian Harl [Sun, 1 Mar 2015 18:13:04 +0000 (19:13 +0100)]
parser_test: Test further error cases and error propagation in the analyzer.

9 years agofrontend/grammar: Check arithmetic expressions early.
Sebastian Harl [Sun, 1 Mar 2015 17:36:34 +0000 (18:36 +0100)]
frontend/grammar: Check arithmetic expressions early.

Constant expressions are evaluated early. Thus, creating an expression object
may fail if there's a semantics error. Catch this early and report a (generic)
error to avoid propagating a NULL value.

9 years agosysdbql(7): Document typed expressions.
Sebastian Harl [Sun, 1 Mar 2015 16:31:29 +0000 (17:31 +0100)]
sysdbql(7): Document typed expressions.