rrdd.git
16 years agosrc/rrdd.c: Try the default address if no other address is specified.
Florian Forster [Sun, 22 Jun 2008 12:18:51 +0000 (14:18 +0200)]
src/rrdd.c: Try the default address if no other address is specified.

16 years agosrc/rrdd.[ch]: Move DEFAULT_PORT to rrdd.h.
Florian Forster [Sun, 22 Jun 2008 12:18:20 +0000 (14:18 +0200)]
src/rrdd.[ch]: Move DEFAULT_PORT to rrdd.h.

16 years agosrc/rrdd.c: Implement listening on multiple sockets.
Florian Forster [Sun, 22 Jun 2008 11:28:52 +0000 (13:28 +0200)]
src/rrdd.c: Implement listening on multiple sockets.

16 years agosrc/rrdd.c: Only unlink UNIX domain sockets.
Florian Forster [Sun, 22 Jun 2008 11:28:29 +0000 (13:28 +0200)]
src/rrdd.c: Only unlink UNIX domain sockets.

16 years agosrc/rrdd.[ch]: Implement listening to arbitrary addresses.
Florian Forster [Sun, 22 Jun 2008 11:00:48 +0000 (13:00 +0200)]
src/rrdd.[ch]: Implement listening to arbitrary addresses.

16 years agosrc/rrdd.c: Implement option parsing.
Florian Forster [Sun, 22 Jun 2008 09:57:08 +0000 (11:57 +0200)]
src/rrdd.c: Implement option parsing.

The write interval is no longer hard coded. The other options are not
yet implemented.

16 years agosrc/rrdd.c: Add a debug message for disconnecting sockets.
Florian Forster [Sun, 22 Jun 2008 09:01:55 +0000 (11:01 +0200)]
src/rrdd.c: Add a debug message for disconnecting sockets.

16 years agosrc/rrdd.c: Complain if write(2) fails.
Florian Forster [Sun, 22 Jun 2008 09:01:18 +0000 (11:01 +0200)]
src/rrdd.c: Complain if write(2) fails.

16 years agosrc/rrdd.c: Ignore SIGPIPE.
Florian Forster [Sun, 22 Jun 2008 08:48:15 +0000 (10:48 +0200)]
src/rrdd.c: Ignore SIGPIPE.

This signal may be sent if a client closes the connection before reading
the reply. We don't want to die in this case.. ;)

16 years agosrc/rrdd.pod: Add a simple manpage stub for rrdd(1).
Florian Forster [Sun, 22 Jun 2008 08:34:24 +0000 (10:34 +0200)]
src/rrdd.pod: Add a simple manpage stub for rrdd(1).

16 years agosrc/{lib,}rrdc.c: Make `rrdd_connect' use the default path if path == NULL.
Florian Forster [Sun, 22 Jun 2008 08:17:10 +0000 (10:17 +0200)]
src/{lib,}rrdc.c: Make `rrdd_connect' use the default path if path == NULL.

16 years agosrc/rrdd.c: Actually pass the values to rrd_update_r.
Florian Forster [Sat, 21 Jun 2008 16:35:17 +0000 (18:35 +0200)]
src/rrdd.c: Actually pass the values to rrd_update_r.

16 years agosrc/rrdc.c: Use PACHAGE_VERSION rather than hard coding the version.
Florian Forster [Sat, 21 Jun 2008 16:23:46 +0000 (18:23 +0200)]
src/rrdc.c: Use PACHAGE_VERSION rather than hard coding the version.

16 years agosrc/rrdd.c: Signal the queue thread then shutting down.
Florian Forster [Sat, 21 Jun 2008 16:23:22 +0000 (18:23 +0200)]
src/rrdd.c: Signal the queue thread then shutting down.

Prevents a deadlock when shutting down.

16 years agosrc/rrdd.c: Let the connection thread add itself to the list of threads.
Florian Forster [Sat, 21 Jun 2008 16:22:44 +0000 (18:22 +0200)]
src/rrdd.c: Let the connection thread add itself to the list of threads.

This avoids an ugly race condition.

16 years agosrc/librrdc.c: When sending an `update', wait for the reply before closing the socket.
Florian Forster [Sat, 21 Jun 2008 16:17:07 +0000 (18:17 +0200)]
src/librrdc.c: When sending an `update', wait for the reply before closing the socket.

Not doing so will (still!) crash rrdd, but it's not nice either hence this fix.

16 years agosrc/rrdc.c: According to C99 argv is NULL terminated, so don't copy the array.
Florian Forster [Sat, 21 Jun 2008 15:43:07 +0000 (17:43 +0200)]
src/rrdc.c: According to C99 argv is NULL terminated, so don't copy the array.

16 years agosrc/rrdd.c: A first take at implementing a cache.
Florian Forster [Sat, 21 Jun 2008 13:44:43 +0000 (15:44 +0200)]
src/rrdd.c: A first take at implementing a cache.

This is WORK IN PROGRESS and not working correctly yet! Also in this commit:
Many other unstructured changes, since this we're still in the big bang phase
of this project ;)

16 years agosrc/rrdd.h: Include more neccessary files.
Florian Forster [Sat, 21 Jun 2008 13:44:27 +0000 (15:44 +0200)]
src/rrdd.h: Include more neccessary files.

16 years agosrc/librrdc.c: Send the `command' ("update" right now) to the daemon, too.
Florian Forster [Sat, 21 Jun 2008 13:43:46 +0000 (15:43 +0200)]
src/librrdc.c: Send the `command' ("update" right now) to the daemon, too.

16 years agobuild system: Search for <avl.h> and link with `avl'.
Florian Forster [Sat, 21 Jun 2008 13:43:19 +0000 (15:43 +0200)]
build system: Search for <avl.h> and link with `avl'.

16 years agosrc/librrdc.c: Sending to the daemon has been added.
Florian Forster [Sat, 21 Jun 2008 02:09:59 +0000 (04:09 +0200)]
src/librrdc.c: Sending to the daemon has been added.

Handling by the daemon is still missing.

16 years agosrc/rrdd.[ch]: Use package name and version from config.h.
Florian Forster [Sat, 21 Jun 2008 02:04:54 +0000 (04:04 +0200)]
src/rrdd.[ch]: Use package name and version from config.h.

16 years agoconfigure.ac: Add the forgotten configure.ac.
Florian Forster [Fri, 20 Jun 2008 17:58:55 +0000 (19:58 +0200)]
configure.ac: Add the forgotten configure.ac.

16 years agoInitial commit: rrdd, rrdc, librrdc.so
Florian Forster [Fri, 20 Jun 2008 17:55:05 +0000 (19:55 +0200)]
Initial commit: rrdd, rrdc, librrdc.so

Deamonization, socket opening and build system work, but the protocol is not
implemented yet. The protocol will be implemented in librrdc.so, so that
external programs can easily use the daemon.