This is a very preliminary braindump on some ideas for a system model. I am no academic, and it's been a long time since I've taken my queueing theory class. This is all unvalidated, and may be wildly off-base. I welcome corrections with an open heart and mind.
First, an introduction to some queueing theory.
<--------R--------->
<---W---> <---S--->
+---------+
λ | | X
--> • • • | • |--> •
| |
+---------+
<---Q--->
From λ and S we can deduce other properties of the system.
For testing we can reasonably fix λ to some constant value. In contrast, S will be a function of the size of the work unit (record). For now let's fix each record at N bytes. Then, S = f(N).
The producer establishes the arrival rate of records λr, and the size of each record Nr.
We'll need to run experiments to figure out the service time function Sr. For now let's assume one nanosecond per byte.
Between the producer and the forwarding agent exists a pipe buffer. This has a maximum bandwidth which affects througput.
The first queue exists at the forward agent. The forwarder just writes records to the connection. So the service time at the forwarder is simple.
Again, we'll need to experiment to figure out Oconsumption and Wconnection. For now, let's fix them at some guesses.
Between the forwarder and the ingester exists a network. This has a maximum bandwidth which affects throughput.
Then, we reach the ingester. First, records are taken from connections and written to the active segment. This follows a similar model of the forwarder.
Again, we'll need to experiment to figure out Wsegment. For now, let's fix it with a guess.
Segments become available for consumption after they reach a defined age A or size S. A imposes a maximum age, and S imposes a maximum size. The ingester effectively changes the unit of work, from record to segment. So, we derive a new rate of segments λs, and segment size Nr.
Let λr = 100 records per second, Nr = 500 bytes, A = 1 second, and S = 1 megabyte. 100 records per second times 500 bytes per record yields 50000 bytes per second. This triggers A = 1 second, but doesn't trigger S = 1 megabyte. So Ns will be 50000 bytes, and λs will be 1 segment per second.
Let λr = 10000 records per second, Nr = 500 bytes, A = 1 second, and S = 1 megabyte. 10000 records per second times 500 bytes per record yields 5000000 bytes per second. This triggers S = 1 megabyte at (1MB / 5000000B) * second = 200ms. So Ns will be 1MB, and λs will be 5 segments per second.
Segments are made available by ingesters but consumed by store nodes. Store nodes consume when they have capacity, choosing arbitrarily from ingest nodes. We can model this as a virtual queue. Available segments across all ingesters form the virtual queue of waiting work. And all store nodes collectively form a single virtual server.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。