Mercurial > prosody-modules
annotate mod_log_slow_events/README.markdown @ 4260:c539334dd01a
mod_http_oauth2: Rescope oauth client config into users' storage
This produces client_id of the form owner@host/random and prevents
clients from being deleted by registering an account with the same name
and then deleting the account, as well as having the client
automatically be deleted when the owner account is removed.
On one hand, this leaks the bare JID of the creator to users. On the
other hand, it makes it obvious who made the oauth application.
This module is experimental and only for developers, so this can be
changed if a better method comes up.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 21 Nov 2020 23:55:10 +0100 |
parents | d276bf3f0464 |
children |
rev | line source |
---|---|
2896
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
1 --- |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
2 labels: |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
3 - 'Stage-Stable' |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
4 summary: Log warning when event handlers take too long |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
5 ... |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
6 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
7 Introduction |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
8 ============ |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
9 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
10 Most activities in Prosody take place within our built-in events framework, for |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
11 example stanza processing and HTTP request handling, authentication, etc. |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
12 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
13 Modules are able to execute code when an event occurs, and they should return |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
14 as quickly as possible. Poor performance (e.g. slow or laggy server) can be caused |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
15 by event handlers that are slow to respond. |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
16 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
17 This module is able to monitor how long each event takes to be processed, and |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
18 logs a warning if an event takes above a certain amount of time, including |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
19 providing any details about the event such as the user or stanza that triggered it. |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
20 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
21 The aim is to help debug why a server may not be as responsive as it should be, |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
22 and ultimately which module is to blame for that. |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
23 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
24 Configuration |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
25 ====================== |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
26 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
27 There is a single configuration option: |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
28 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
29 ``` |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
30 -- Set the number of seconds an event may take before |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
31 -- logging a warning (fractional values are ok) |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
32 log_slow_events_threshold = 0.5 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
33 ``` |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
34 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
35 Metrics |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
36 ======= |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
37 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
38 In addition to the log messages, a new 'slow_events' metric will be exported to |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
39 your configured stats backend (if any). |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
40 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
41 Compatibility |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
42 ------------- |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
43 |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
44 ------- -------------- |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
45 trunk Works |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
46 0.10 Works |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
47 0.9 Doesn't work |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
48 0.8 Doesn't work |
d276bf3f0464
mod_log_slow_events: Add README
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
49 ------- -------------- |