Use JSON or C for accessing urmurmurd server/client info using a sharedmemory API

21 views
Skip to first unread message

Michael Pounders

unread,
Sep 21, 2014, 11:32:06 PM9/21/14
to umurmur...@googlegroups.com

browser showing uMurmurd-Websocket output

I have added a sharedmemory API to uMurmurd for accessing server/client info

It runs fine here on a RaspberryPI. I need testers for 64bit, BSD, OSX, other CPU types, etc.



build umurmurd:
   
    git clone -b sharedmemory g...@github.com:snowblind/umurmur.git  umurmur_shm
    cd umurmur_shm
    mkdir build
    cd build
    cmake ../

Two programs added that use the umurmurd sharedmemory API have been added to shm_utils dir

mon-umurmurd
============

outputs server/client data to term using the sharedmemory API added to umurmur for testing

make
./mon-umurmurd

uMurmurd-Websocket - HTTP/JSON server example
=============================================

The pic is the browser connected to this program.

HTTP/JSON server in one. Using a js pretty print type lib to display the output.
It is not the best looking but its just a demo. Hoping someone else with better web
skills can make something better.
 

Instructions for building from source
-------------------------------------
1. Requirements
  * OpenSSL library
  * libwebsockets library. I used this tarball
  * Jansson library.  I used this tarball Jansson is a C library for encoding, decoding and manipulating JSON data
  * cmake

2. Build - CMake
    * Create a build folder and cd into it
    * `cmake ../`
    * `make`

3. Run
  * start umurmurd from this git like this ./umurmurd -d -c <conf file>
       - the -d option is just to make it easier to see debug info
  * start uMurmurd-Websocket with ./uMurmurd-Websocket --ssl
       - option --ssl is for https://, http:// otherwise
  * point web browser to https://localhost:7681     



Michael Pounders

unread,
Sep 27, 2014, 9:40:18 PM9/27/14
to umurmur...@googlegroups.com

ALL:
  1. Update to fix issue with shown time. Pointed out by martin
  2. code clean up

uMurmurd-Websocket:
  1.  web page now has a autoupdate button that will update page every second the clean way no page reload just the data gets updated
Reply all
Reply to author
Forward
0 new messages