Commit Graph
309 Commits
Author SHA1 Message Date
Mike Hillyer c060fc90f4 Odd parse error when the relational operators are in a lua formatted code block. 2023-03-10 23:35:44 -05:00
Mike Hillyer 51983d7891 Fixing issue in examples with unescaped values. 2023-03-10 23:31:34 -05:00
Mike Hillyer 2a4c53f953 Removing extra trailing line 2023-03-10 23:27:42 -05:00
Mike Hillyer a17e2bb22b One more linter error. 2023-03-10 23:21:45 -05:00
Mike Hillyer cb14f95fdd Fixing more markdown linting errors. 2023-03-10 23:21:14 -05:00
Mike Hillyer 1b62b8724b Update formatting in environmental considerations page to fix linter complaints. 2023-03-10 23:01:53 -05:00
Wez Furlong d22ac8251a timeq: adjust timing in unit test to reduce flakiness
The timing is sometimes a bit too tight for CI to
succeed 100% of the time, so relax it a bit.
2023-03-10 18:06:47 -07:00
Wez Furlong 0279dd9f0c add repo file for centos7 2023-03-10 17:37:39 -07:00
Wez Furlong 809b6bd1be publish continuous builds to a centos7 -dev version of the repo 2023-03-10 17:15:16 -07:00
Wez Furlong 7cd8aa1a63 ci: fixup sign, and maybe publish the rpm too 2023-03-10 16:49:52 -07:00
Wez Furlong 9452ca83eb ci: speculative attempt at signing the rpm 2023-03-10 16:10:24 -07:00
Tom Mairs 7b3d6d5f40 fix hugepages allocation 2023-03-10 10:42:33 -07:00
Wez Furlong d86b8df202 spool: expose a number of rocksdb tuning options
There are loads more; I got bored adding them for now,
and more can be added later.
2023-03-10 07:29:36 -07:00
Wez Furlong 79cef7c819 spool: improve unit tests, add coverage for rocksdb 2023-03-10 06:30:40 -07:00
Wez Furlong 7dcf953ccb fix doc build 2023-03-10 06:15:38 -07:00
Tom Mairs dad4083170 Adding OS Prep guides 2023-03-10 00:29:41 -07:00
Wez Furlong 4c1848ac7c Add explicit license 2023-03-09 20:56:02 -07:00
Wez Furlong 10017731ca format the manual 2023-03-09 19:56:00 -07:00
Wez Furlong 722876a144 first pass at memory awareness
This commit introduces awareness of memory limits that may
have been established for the process.

The idea is that the hard/soft limits are read from the active
cgroup, falling back to classic ulimit hard/soft limits, falling
back to the system RAM size.

In the absence of an explicitly configured hard limit, the RAM size
is used for the hard limit.

In the absence of an explicitly configured soft limit, 75% of the
hard limit is used for the soft limit.

A background thread monitors the memory usage and (potentially
adjusted) memory limits.

A low memory state is when the usage is within 10% of the soft limit.
In this state, we start to trim back memory usage, shrinking loaded
data when messages are placed into the ready queue.

A more severe memory state is when the usage exceeds the soft limit.
In this state, new message reception is rejected until the usage
recovers.

kumod doesn't do anything directly with the hard limit, but assumes
that the system will terminate the process with no opportunity to
safely clean up if that value is reached.

In order to reduce the memory usage, the allocator has been switched
to jemalloc which has superior management of fragmentation and
a control interface to request release of various memory caches.

We make use of jemalloc specific functions in the tokio thread pools;
when they park (idle), we release the thread local cache, and when
we reach the soft limit we aggressively flush the caches until
memory usage falls below the limit.

There's like some room for tuning of the thresholds around this,
but this is a reasonable start.

Note that there are no explicit config options in kumod to set
the soft and hard limits: those are taken from the process
environment and can be simply set either via ulimit in a calling
shell script, or via systemd service configuration.

We may introduce some knobs for the low memory state threshold
in the future.
2023-03-09 18:50:24 -07:00
Wez Furlong f26dfee19e fix round tripping of spool ids for rocksdb
Simlar to the previous commit, I broke spool enumeration
for rocks db when I refactored this stuff.
2023-03-09 18:50:24 -07:00
Wez Furlong d5d12fb622 fix: round trip spoolid<->path for local disk
I broke spool enumeration for local disk when I adjusted
the path hashing a little while back, and didn't notice
because I was using rocksdb more than regular disk.
2023-03-09 18:50:24 -07:00
Wez Furlong 86bdb39ea0 include line table debug info in release builds
This gives a higher quality panic stack trace at the cost of inflating
the executable size from ~50MB -> ~500MB.

Full debug info is a possibility, but the executable size is ~800MB,
which is high, but not completely crazy. I don't know if we'll really
need that, so going with line debug for now.
2023-03-09 18:50:24 -07:00
Mike Hillyer a5d6f46175 Fix a URL. 2023-03-09 14:59:39 -05:00
Mike Hillyer 18247dc199 Update the about page. 2023-03-09 14:00:17 -05:00
Mike Hillyer 5656505b90 Markdown formatting fixes in various docs pages, correct capitalization of Swaks to match that of the tool's website. 2023-03-09 13:51:15 -05:00
Mike Hillyer 088ae10d58 Fix a bad path reference in the build script for the docs. 2023-03-09 13:34:43 -05:00
Mike Hillyer f80f621faf Adding the legal notices. 2023-03-09 13:31:33 -05:00
Tom Mairs e9ce0e7c28 Update install_for_production_use.md 2023-03-09 10:26:01 -07:00
Tom Mairs fc26a60a22 Update install_for_production_use.md 2023-03-09 10:22:31 -07:00
Tom Mairs a0b34f4118 Update install_for_production_use.md 2023-03-09 10:13:10 -07:00
Tom Mairs 695c1e3fbd Rename special_for_centos7 to special_for_centos7.md 2023-03-09 09:59:25 -07:00
Tom Mairs 8b8d41bfec Update getting_started.md 2023-03-09 09:58:12 -07:00
Cloud User 3632889cdf Guide updates for CentOS7 2023-03-09 16:47:25 +00:00
Wez Furlong b3fa0dab3e raise integration test timeouts a bit 2023-03-08 22:54:49 -07:00
Wez Furlong d52c90a8ad ci: remove rpm changelog; just leave it blank 2023-03-08 22:12:54 -07:00
Wez Furlong c89546a51e ci: centos 7 build in release mode for rpm capture 2023-03-08 22:12:06 -07:00
Wez Furlong a638979464 ci: tweak centos7 build 2023-03-08 21:55:24 -07:00
Wez Furlong 50d2610186 ci: capture centos rpms as artifact 2023-03-08 21:33:39 -07:00
Wez Furlong 18c0b10fc1 add script that can build and rpm from an already built repo 2023-03-08 21:31:06 -07:00
Wez Furlong ad54ad8a63 ci: locked: true is deprecated; update to args: --locked 2023-03-08 21:07:30 -07:00
Wez Furlong 69a9eb7ed6 explicitly run integration tests as the current user
This helps when we're running as root in a container on CI
2023-03-08 21:05:48 -07:00
Wez Furlong c0d7944e25 ci: source llvm toolset enable script 2023-03-08 20:30:19 -07:00
Wez Furlong cfd5e3a924 ci: speculative start at centos7 build 2023-03-08 19:51:55 -07:00
Wez Furlong c191b086b2 kumod: make --policy a required argument
it was optional when I was bootstrapping the code; it really
is required because you can't do anything without defining
any spools, and you need the policy script to do that.
2023-03-08 18:17:05 -07:00
Wez Furlong 4cd913e7bf improve some error handling; enable printing panics, capture core
and report non-zero exit status if initialization failed
2023-03-08 18:15:31 -07:00
Wez Furlong 4b7cbf9299 build.rs: remove unused import 2023-03-08 17:42:33 -07:00
Wez Furlong 50a123a0e3 Add version info to kumod 2023-03-08 17:38:15 -07:00
Wez Furlong 772e1e1b89 format 2023-03-08 17:37:54 -07:00
Wez Furlong 815ed0c6fc add issue template 2023-03-08 17:05:36 -07:00
Wez Furlong 55d3343ac5 config: implement pooling of lua contexts
and export some counters so that we can see into their usage
2023-03-08 16:53:04 -07:00