-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Registry staging #1
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add the BSD list implementation.
This patch adds a "local registry" which is basically a tree of nodes which try to mimic JSON nodes. The idea behind "lreg" is to provide a subsystem which can be used to hold arbitrary objects in a namespace which can be translated into KVs as needed. The first users of the lreg are log entries. The idea here is that each log entry is made into a static object which is installed into a node owned by the respective .c or .h file containing the log message. Later, we will allow users to modify the log levels via external input sources.
Add enum constructor_priorities for specifying the order in which constructor / initialization functions are called at startup. Add support for lreg entries which live in the root. Made macros for defining, declaring, and installing these. There's currently an example in log.[ch]. Cleanup the log.h macros a bit.
00pauln00
added a commit
that referenced
this pull request
Apr 18, 2020
This node is now available in JSON "system_info" : { "current_time" : "Sat Apr 18 17:01:15 2020", "pid" : 27608, "process_name" : "", "process_args" : "", "uts.nodename" : "localhost.localdomain", "uts.sysname" : "Linux", "uts.release" : "5.3.11-100.fc29.x86_64", "uts.version" : "#1 SMP Tue Nov 12 20:41:25 UTC 2019", "uts.machine" : "x86_64", "rusage.user_cpu_time_used" : 1.994547, "rusage.system_cpu_time_used" : 2.028652, "rusage.max_rss" : 61744, "rusage.min_fault" : 17367, "rusage.maj_fault" : 0, "rusage.in_block" : 0, "rusage.out_block" : 392, "rusage.vol_ctsw" : 103943, "rusage.invol_ctsw" : 542 },
00pauln00
added a commit
that referenced
this pull request
Apr 29, 2020
APPLY to read-only keys and value filterining on arrays / objects will now return an error via OUTFILE. The code here pretty messy atm and needs some TLC. -- Example #1 $ cat err.cmd GET /entry_map/log_entries@asdfas OUTFILE /err.out $ cat /tmp/.niova/5802f58a-41f2-11ea-a99d-90324b2d1e89/output/err.out { "log_entry_map" : [ { "error" : "May not apply value filter (`asdfas') to array or object (`log_entries')" } ] } -- Example #2 $ cat fault-inj.cmd APPLY frequency_seconds@100 WHERE /fault_injection_points/name@disabled\ injection OUTFILE /err.out $ cat /tmp/.niova/5802f58a-41f2-11ea-a99d-90324b2d1e89/output/err.out { "error" : "Key (`frequency_seconds') is read-only" }
00pauln00
added a commit
that referenced
this pull request
Apr 30, 2020
APPLY to read-only keys and value filterining on arrays / objects will now return an error via OUTFILE. The code here pretty messy atm and needs some TLC. -- Example #1 $ cat err.cmd GET /entry_map/log_entries@asdfas OUTFILE /err.out $ cat /tmp/.niova/5802f58a-41f2-11ea-a99d-90324b2d1e89/output/err.out { "log_entry_map" : [ { "error" : "May not apply value filter (`asdfas') to array or object (`log_entries')" } ] } -- Example #2 $ cat fault-inj.cmd APPLY frequency_seconds@100 WHERE /fault_injection_points/name@disabled\ injection OUTFILE /err.out $ cat /tmp/.niova/5802f58a-41f2-11ea-a99d-90324b2d1e89/output/err.out { "error" : "Key (`frequency_seconds') is read-only" }
Closed
bergstartup
pushed a commit
that referenced
this pull request
Aug 10, 2022
This patch enables the lookout to do some very basic monitoring operations. The results are reporting through http to the caller. The reported results are intentionally verbose, the http interface is meant to provide detailed info about the niova services on the node. Note there's still a lot of work to do.. For one, the cmd file inputs and outputs are not being cleaned up. Also, dead enpoints are not yet removed from the map (perhaps they will remain there forever but with a lower polling frequency?). Another item is replacing the UUID (used as a key below) with a short name like "raft-0" or "nosd-1". Example output: $ curl -s http://localhost:8080/v0/ { "bf69c910-a426-11ea-afe6-90324b2d1e89": { "name": "r-a4e1", "type": "raft", "port": 6666, "responsive": true, "ep_info": { "system_info": { "current_time": { "time": "2020-06-01T22:05:09Z" }, "start_time": { "time": "2020-06-01T16:41:32Z" }, "pid": 10173, "uuid": "bf69c910-a426-11ea-afe6-90324b2d1e89", "ctl_interface_path": "//tmp/.niova/bf69c910-a426-11ea-afe6-90324b2d1e89/", "command_line": "/home/pauln/Code/niovad/raft-server -R -r bf692320-a426-11ea-b661-90324b2d1e89 -u bf69c910-a426-11ea-afe6-90324b2d1e89", "uts.nodename": "localhost.localdomain", "uts.sysname": "Linux", "uts.release": "5.2.17-100.fc29.x86_64", "uts.version": "#1 SMP Mon Sep 23 14:09:29 UTC 2019", "uts.machine": "x86_64", "rusage.user_cpu_time_used": 86.786644, "rusage.system_cpu_time_used": 22.139437, "rusage.max_rss": 510516, "rusage.min_fault": 155418, "rusage.maj_fault": 66, "rusage.in_block": 17192, "rusage.out_block": 73592, "rusage.vol_ctsw": 79335, "rusage.invol_ctsw": 10392 } } } }
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.