Krisztian Litkey [Thu, 13 Dec 2012 13:11:17 +0000 (15:11 +0200)]
collect-symbols: more diagnostic messages.
Krisztian Litkey [Thu, 13 Dec 2012 13:03:15 +0000 (15:03 +0200)]
collect-symbols: ignore forward declarations and symbols from foreign files.
Krisztian Litkey [Mon, 10 Dec 2012 20:27:22 +0000 (22:27 +0200)]
utils: added collect-symbols in an attempt to eliminate depending on ctags.
collect-symbols is a primitive parser that tries to understand just enough
of (preprocessed) C that it can extract symbols exported from header files.
Krisztian Litkey [Mon, 11 Feb 2013 13:31:29 +0000 (15:31 +0200)]
console: removed console plugin from the old location.
Hmm... actually I'm not quite sure how I ended up having to do
this. I did a git mv of the console plugin from the old to the new
location. Maybe I should've included in the accompanying post-move
commit _both_ the old and the new paths. Go figure...
Krisztian Litkey [Mon, 11 Feb 2013 11:51:14 +0000 (13:51 +0200)]
console: auto-grow web console input area as needed.
Krisztian Litkey [Mon, 11 Feb 2013 11:27:47 +0000 (13:27 +0200)]
websocket: exposed wsl_server_http_file.
Krisztian Litkey [Fri, 8 Feb 2013 21:19:59 +0000 (23:19 +0200)]
wrt-resource: resource-api.js typo fix.
Krisztian Litkey [Fri, 8 Feb 2013 21:17:05 +0000 (23:17 +0200)]
console: added websocket support, PoC web console.
Krisztian Litkey [Thu, 7 Feb 2013 10:29:25 +0000 (12:29 +0200)]
common: support for partial strings.
Krisztian Litkey [Tue, 5 Feb 2013 17:55:40 +0000 (19:55 +0200)]
resource-wrt: (embarrassing) resource test audio hack.
Krisztian Litkey [Tue, 5 Feb 2013 17:51:42 +0000 (19:51 +0200)]
resource-wrt: basic support for serving HTTP content (javascript libs).
Krisztian Litkey [Tue, 5 Feb 2013 17:38:57 +0000 (19:38 +0200)]
websockets: configurable limited HTTP content serving over transports.
It is now possible to serve content over HTTP on a websocket transport.
This is primarily intended to allow handing out javascript libraries that
interface the actual service exposed over the same websocket transport.
The javascript library can hide the dirty details of the underlying
communication protocol and present a more conventional and user-friendly
javascript API. By serving the interface library on demand from the same
transport as the service itself, the protocol can be freely reworked
behind the scenes, ideally keeping high-level API intact, without having
to worry about compatibility issues between the javascript library and
the protocol being used. In a way the library is an agent pushed by the
protocol implementation to the client...
Krisztian Litkey [Tue, 5 Feb 2013 17:37:33 +0000 (19:37 +0200)]
websockets: HTTP req. completion callback, preliminary SSL support.
Krisztian Litkey [Fri, 1 Feb 2013 19:29:26 +0000 (21:29 +0200)]
build-sys: fix to compile again without websockets.
Krisztian Litkey [Fri, 1 Feb 2013 19:28:47 +0000 (21:28 +0200)]
dbus-transport: get rid of a warning on the cleanup-path.
Krisztian Litkey [Fri, 1 Feb 2013 16:43:46 +0000 (18:43 +0200)]
resource-wrt: added forgotten header.
Krisztian Litkey [Fri, 1 Feb 2013 16:40:56 +0000 (18:40 +0200)]
common: updated linker script.
Krisztian Litkey [Fri, 1 Feb 2013 16:38:46 +0000 (18:38 +0200)]
Merge branch 'websocket-transport'
Krisztian Litkey [Fri, 1 Feb 2013 16:31:40 +0000 (18:31 +0200)]
resource-wrt: added resource-api.js and resource-test.js.
Krisztian Litkey [Fri, 1 Feb 2013 16:30:08 +0000 (18:30 +0200)]
resource-wrt: error fields are 'error', and 'message'.
Krisztian Litkey [Thu, 31 Jan 2013 15:32:37 +0000 (17:32 +0200)]
common: crash-fix: reset destroyed debug rule tables to NULL after reset.
Janos Kovacs [Wed, 30 Jan 2013 00:28:04 +0000 (02:28 +0200)]
resource: add resource user tables
Krisztian Litkey [Tue, 29 Jan 2013 21:54:21 +0000 (23:54 +0200)]
websockets: added support for pure HTTP websockets and file serving.
This patch adds support for pure HTTP sockets. Because connection
establishment is tied to websocket handshaking in libwebsockets, a
considerable amount of extra gymnastics is needed to get pure HTTP
clients, which don't handshake, be symmetric to genuine websocket
clients which do handshake.
We need to emulate the connection establishment event ourselves on
demand when the first HTTP content request comes in from a pure
HTTP client. Additionally we also need to handle the mapping from
libwebsockets ws's to our wsl_sck_t's differently because for pure
HTTP clients libwebsockets refuses to allocate user data even if
the registered user data size is non-zero for protocol 0. Pfoof...
Krisztian Litkey [Mon, 28 Jan 2013 21:58:20 +0000 (23:58 +0200)]
resource-wrt: correctly delay and force mask bits into first event.
Krisztian Litkey [Sun, 27 Jan 2013 21:40:24 +0000 (23:40 +0200)]
resource-wrt: added resource attributes to events.
Krisztian Litkey [Sat, 26 Jan 2013 18:48:23 +0000 (20:48 +0200)]
resource-wrt: implemented basic request and event handing.
Krisztian Litkey [Tue, 29 Jan 2013 13:56:06 +0000 (15:56 +0200)]
resource: export max. number of attributes in a macro.
Krisztian Litkey [Sat, 26 Jan 2013 20:16:01 +0000 (22:16 +0200)]
common: JSON fixes, more convenience macros, lookup failure reason in errno.
Krisztian Litkey [Sat, 26 Jan 2013 19:33:22 +0000 (21:33 +0200)]
resource-native: added console command for showing all resource definitions.
Krisztian Litkey [Sat, 26 Jan 2013 18:47:53 +0000 (20:47 +0200)]
websockets: make more explicitly sure we default to sending in text mode.
Otherwise decoding messages in the web runtime/a browser becomes a PITA.
Krisztian Litkey [Sat, 26 Jan 2013 18:46:49 +0000 (20:46 +0200)]
websockets: use JSON for websocket transports in custom mode.
Krisztian Litkey [Sat, 26 Jan 2013 18:44:52 +0000 (20:44 +0200)]
common: added custom transport mode support (custom encoding/decoding).
Krisztian Litkey [Sat, 26 Jan 2013 14:20:07 +0000 (16:20 +0200)]
common: JSON fixes, allow length to be passed to parser.
Krisztian Litkey [Sat, 26 Jan 2013 12:06:17 +0000 (14:06 +0200)]
common: transport mode renamed: s/CUSTOM/DATA/g.
Krisztian Litkey [Sat, 26 Jan 2013 11:39:36 +0000 (13:39 +0200)]
resource-wrt: added WRT resource plugin skeleton.
Krisztian Litkey [Sat, 26 Jan 2013 11:30:27 +0000 (13:30 +0200)]
common: added websocket transport setopt interface.
Krisztian Litkey [Sat, 26 Jan 2013 11:29:34 +0000 (13:29 +0200)]
common: added websocklib write mode setting interface.
Krisztian Litkey [Sat, 26 Jan 2013 11:28:22 +0000 (13:28 +0200)]
common: added transport setopt interface.
Krisztian Litkey [Fri, 25 Jan 2013 14:24:05 +0000 (16:24 +0200)]
websockets: always run the low-level transport in framed mode.
Krisztian Litkey [Fri, 25 Jan 2013 14:21:51 +0000 (16:21 +0200)]
common: added functions for querying fragbuf state.
Krisztian Litkey [Thu, 24 Jan 2013 20:40:30 +0000 (22:40 +0200)]
websockets: don't hardcode framed reassembly, check the protocol descriptor.
Krisztian Litkey [Thu, 24 Jan 2013 18:09:11 +0000 (20:09 +0200)]
websockets: try to reject pure HTTP clients/connections for now.
Krisztian Litkey [Thu, 24 Jan 2013 18:07:50 +0000 (20:07 +0200)]
common: changed stream-transport to use fragbuf.
Krisztian Litkey [Thu, 24 Jan 2013 18:06:35 +0000 (20:06 +0200)]
console-client: saner command-line processing.
Krisztian Litkey [Thu, 24 Jan 2013 18:05:29 +0000 (20:05 +0200)]
common: added fragbuf trim and a check for uninitialized pull.
Krisztian Litkey [Thu, 24 Jan 2013 17:49:03 +0000 (19:49 +0200)]
console-client: added local Makefile.
Krisztian Litkey [Thu, 24 Jan 2013 16:33:02 +0000 (18:33 +0200)]
common/transport: separate mode bits from flags.
Krisztian Litkey [Thu, 24 Jan 2013 16:31:53 +0000 (18:31 +0200)]
domain-control: get rid of a few unused var warnings.
Krisztian Litkey [Thu, 24 Jan 2013 15:55:15 +0000 (17:55 +0200)]
common: added API for basic JSON object manipulation.
Although we do use json-c, we don't want direct json-c dependency
sneak in and spread all over the codebase. Therefore we define a
layer on top of it which will also hopefully provide a confined
space to patch things up if we're not happy with the underlying
interfaces.
Krisztian Litkey [Tue, 22 Jan 2013 14:53:17 +0000 (16:53 +0200)]
plugin-console: updated debug info.
Krisztian Litkey [Tue, 22 Jan 2013 14:46:01 +0000 (16:46 +0200)]
plugin-console: accept websockets for transport.
Krisztian Litkey [Tue, 22 Jan 2013 14:44:29 +0000 (16:44 +0200)]
common: force debug-site update when enabling/disabling debugging.
Krisztian Litkey [Wed, 23 Jan 2013 20:31:00 +0000 (22:31 +0200)]
common: WiP: websockets: updated linker-script.
Krisztian Litkey [Tue, 15 Jan 2013 12:20:07 +0000 (14:20 +0200)]
common: low-level websocket abstraction + a websocket transport
Our low-level websocket library is built on top of libwebsockets.
It basically provides the necessary bits of glue to pump websocket
connections from a Murphy mainloop. Additionally it attempts to do
most of the heavy lifting necessary to associate extra contextual
data with websockets (IOW attaching/detaching in a safe manner
user data with websocket contexts and connections) which I found
surprisingly hairy to do with libwebsockets itself.
Eventually the low-level library should map out all the useful
features of the underlying library. We're far not there at the
moment. We do not provide an interface for features that we do not
need ourselves at the moment. These include things like connection
filtering, pure HTTP connections, serving files to clients, extension-
negotiation, etc. Of these at least SSL-support, pure HTTP clients
and content-serving (for serving our own javascript libraries to
clients) are next on the list to map out.
The websocket transport basically integrates websockets to our
transport abstraction. IOW, it makes it possible to use a websocket
connection as the underlying IPC mechanism for a Murphy transport.
As a side-effect of implementing websocket transports, an automagic
defragmentation mechanism (fragbuf or mrp_fragbuf_t) has also been
added to the common murphy library.
Krisztian Litkey [Mon, 7 Jan 2013 09:44:38 +0000 (11:44 +0200)]
mainloop: epoll management overhaul, delayed destruction fixes.
Reworked main fdtable and epollfd manipulation to be more consistent
and clearer by separating them out to a set of epoll_* functions of
their own. Planted also quite a number of debug messages to the delete-
code paths.
Also fixed a few delayed destruction corner-case crashes. The code
now uses a dedicated hook for the pending deletion list instead of
reusing the main object hook (which cannot be done in some cases).
This turned the remaining type-specific delete_* functions practically
no-ops (they just unlinked the objects from their repective lists,
also done by the delayed purging code) so they were removed.
Probably we should make delayed destruction readiness more explicit
by putting the common deleted_t fields behind a macro.
Krisztian Litkey [Mon, 14 Jan 2013 15:28:08 +0000 (17:28 +0200)]
Merge branch 'master' of github.com:otcshare/policy-internal
Ismo Puustinen [Mon, 14 Jan 2013 11:32:13 +0000 (13:32 +0200)]
core: added getters for lua sink fields.
Ismo Puustinen [Fri, 11 Jan 2013 14:47:27 +0000 (16:47 +0200)]
lua-decision: added the sink access functions.
Ismo Puustinen [Fri, 11 Jan 2013 08:38:00 +0000 (10:38 +0200)]
common: can use msg and transport functions from C++.
Janos Kovacs [Fri, 11 Jan 2013 12:27:43 +0000 (14:27 +0200)]
lua-decision: add sink.lua
Janos Kovacs [Thu, 10 Jan 2013 23:04:07 +0000 (01:04 +0200)]
lua-decision: add C access routines to mrp_lua_element_t
Janos Kovacs [Thu, 10 Jan 2013 23:02:24 +0000 (01:02 +0200)]
lua-decision: add C access routines to mrp_lua_mdb_select_t
Janos Kovacs [Thu, 10 Jan 2013 23:00:00 +0000 (01:00 +0200)]
compilation: get rid of some unused variable warnings
Krisztian Litkey [Wed, 9 Jan 2013 07:46:06 +0000 (09:46 +0200)]
console: minor typo fix in debug command help.
Krisztian Litkey [Tue, 8 Jan 2013 11:17:32 +0000 (13:17 +0200)]
daemon: omit plugin info from basic command-line help.
Krisztian Litkey [Mon, 7 Jan 2013 09:34:15 +0000 (11:34 +0200)]
common/msg: handle any-type iterators in a valgrind-kosher way.
Ismo Puustinen [Tue, 8 Jan 2013 08:31:38 +0000 (10:31 +0200)]
common: make glib-glue work with C++.
Krisztian Litkey [Mon, 7 Jan 2013 16:24:02 +0000 (18:24 +0200)]
Merge branch 'master' of github.com:otcshare/policy-internal
Krisztian Litkey [Mon, 7 Jan 2013 16:09:29 +0000 (18:09 +0200)]
lua-bindings: added open_lualib() for on-demand loading of Lua libs.
Use open_lualib to load standard Lua libraries as needed. You can call
it with an argument list consisting of the names of the libraries you
want to load (IOW to luaopen_*()). Eg.
murphy.get():open_lualib('math', 'string', 'io')
will try to luaopen_math(), luaopen_string(), and luaopen_io().
The available libraries are 'math', 'string', 'io', 'os', 'table',
'debug', 'package', and 'base'.
Ismo Puustinen [Mon, 7 Jan 2013 15:50:25 +0000 (17:50 +0200)]
common: reference counting now plays nice with C++.
Janos Kovacs [Sun, 6 Jan 2013 04:23:04 +0000 (06:23 +0200)]
lua-utils: fixing mrp_lua_to_object() to return NULL instead of panicing
Janos Kovacs [Sun, 6 Jan 2013 03:22:15 +0000 (05:22 +0200)]
Merge branch 'master' of https://github.com/otcshare/policy-internal
Janos Kovacs [Sun, 6 Jan 2013 03:10:40 +0000 (05:10 +0200)]
lua-utils: fix mrp_lua_to_object() to not leave garbage on the stack
Krisztian Litkey [Fri, 4 Jan 2013 14:58:16 +0000 (16:58 +0200)]
Merge branch 'master' of github.com:otcshare/policy-internal
Ismo Puustinen [Thu, 3 Jan 2013 12:20:52 +0000 (14:20 +0200)]
docs: fixed the indentation in the style guide.
Ismo Puustinen [Fri, 4 Jan 2013 12:53:30 +0000 (14:53 +0200)]
resource-c: remove a compiler warning.
Ismo Puustinen [Fri, 4 Jan 2013 12:38:07 +0000 (14:38 +0200)]
resource-c: the preemption logic now appears to work.
Ismo Puustinen [Fri, 4 Jan 2013 11:07:56 +0000 (13:07 +0200)]
resource-c: removed printfs.
Ismo Puustinen [Thu, 3 Jan 2013 14:10:28 +0000 (16:10 +0200)]
resource-c: make the attribute handling smarter.
Ismo Puustinen [Thu, 3 Jan 2013 13:32:39 +0000 (15:32 +0200)]
resource-c: guard the header files, internal cleanups.
Ismo Puustinen [Thu, 3 Jan 2013 11:20:27 +0000 (13:20 +0200)]
build: Generate linker file for resource library.
Ismo Puustinen [Tue, 4 Dec 2012 11:31:36 +0000 (13:31 +0200)]
resource-c: cleaning up the code.
Krisztian Litkey [Wed, 2 Jan 2013 14:11:16 +0000 (16:11 +0200)]
common: don't register direct pointers with epoll events
At least with unix domain sockets epoll_wait seems to deliver
occasionally pending events for deleted fds. To protect against
this we don't register any more direct pointers to the associated
data structures with epoll. Rather we use an fd-table and either
the fd itself or an index as a key to fetch the associated data
structure from the table. If the event is for a deleted fd, lookup
fails and we ignore the event.
Krisztian Litkey [Wed, 2 Jan 2013 12:23:51 +0000 (14:23 +0200)]
common: removed unused superloop events.
Ismo Puustinen [Thu, 29 Nov 2012 12:24:22 +0000 (14:24 +0200)]
resource-c: implemented functions.
Jaska Uimonen [Thu, 22 Nov 2012 12:52:14 +0000 (14:52 +0200)]
resource-c: towards great success.
Ismo Puustinen [Mon, 12 Nov 2012 09:42:52 +0000 (11:42 +0200)]
build: added external resource API library to build.
Ismo Puustinen [Mon, 12 Nov 2012 09:38:58 +0000 (11:38 +0200)]
build: changed libresource -> libresource-backend.
Ismo Puustinen [Mon, 12 Nov 2012 09:26:48 +0000 (11:26 +0200)]
resource-c: initial version of external C resource library.
Ismo Puustinen [Fri, 4 Jan 2013 09:15:18 +0000 (11:15 +0200)]
build: require a recent enough version of ecore.
Ismo Puustinen [Fri, 4 Jan 2013 09:08:58 +0000 (11:08 +0200)]
common: add missing header to ecore-glue.
Krisztian Litkey [Thu, 3 Jan 2013 11:24:46 +0000 (13:24 +0200)]
transport: install a handler to catch (and ignore) SIGPIPEs.
Krisztian Litkey [Thu, 3 Jan 2013 11:23:58 +0000 (13:23 +0200)]
mainloop: #include signal.h, since mainloop provides a signal handling interface.
Janos Kovacs [Wed, 26 Dec 2012 20:11:11 +0000 (22:11 +0200)]
lua-utils: userdata of objects is aligned as structure not as char array
Janos Kovacs [Wed, 26 Dec 2012 20:14:46 +0000 (22:14 +0200)]
Merge branch 'master' of https://github.com/otcshare/policy-internal
Krisztian Litkey [Fri, 21 Dec 2012 15:10:57 +0000 (17:10 +0200)]
plugin-console: updated debug info.
Krisztian Litkey [Fri, 21 Dec 2012 15:10:34 +0000 (17:10 +0200)]
core: updated debug info.
Krisztian Litkey [Fri, 21 Dec 2012 15:10:25 +0000 (17:10 +0200)]
common: updated debug info.
Krisztian Litkey [Fri, 21 Dec 2012 15:09:40 +0000 (17:09 +0200)]
core: updated linker script.
Krisztian Litkey [Fri, 21 Dec 2012 15:09:34 +0000 (17:09 +0200)]
common: updated linker script.