aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* mod_mam,mod_muc_mam: Simplify deletion when multi-user-deletion is supportedKim Alvefur2021-11-302-13/+54
| | | | More code, but less of it needs to run and no extra tracking is needed.
* mod_storage_sql: Expose multi-user deletion capabilityKim Alvefur2021-11-301-0/+1
| | | | | archive_store:delete(true) deletes messages for all users, which would allow some simplification when this is supported.
* configure: Silence warning about echo -n [shellcheck]Kim Alvefur2021-11-291-1/+2
| | | | Seems SC2039 has been replaced, so should be phased out.
* configure: Remove variable noop (thanks shellcheck)Kim Alvefur2021-11-291-1/+0
|
* util.async tests: Explicitly import match from luassert (luacheck)Matthew Wild2021-11-291-0/+1
|
* util.startup: Initialize util.async at startupMatthew Wild2021-11-291-0/+9
|
* util.async: Add next-tick configurationMatthew Wild2021-11-292-2/+54
| | | | | | | | Running woken runners in the next iteration of the event loop prevents unexpected recursion, unexpected tracebacks, and is generally more predictable. The pattern is borrowed from util.promise, where we're now doing the same.
* util.async: Add sleep() method with configurable scheduling backendMatthew Wild2021-11-292-0/+69
| | | | | | | | | No scheduler set by default, so it will error (we plan to initialize it in util.startup). We wanted to avoid a hard dependency on util.timer (which in turn depends on network backends, etc.), and we didn't add timer.sleep() because we didn't want to add a hard dependency on util.async for things that don't need it.
* util.stanza: Adjust pretty printing for symmetryKim Alvefur2021-11-291-1/+1
| | | | | Self-closing <tags/> and <?processing instructions?> had some asymmetries in applied colors.
* util.dependencies: Discourage Lua 5.1Kim Alvefur2021-11-281-0/+2
| | | | Search for 'Lua 5.1' for reasons.
* util.dependencies: Consider Lua 5.4 Supported:tm:Kim Alvefur2021-11-281-1/+1
| | | | | I have been running my own server exclusively on Lua 5.4 for months and apart from packaging issues I remember on major issues.
* util.prosodyctl.check: Support direct TLS connectivity checksKim Alvefur2021-11-281-0/+6
| | | | | | Currently only supported with OJN Assumption: the direct_tls_ports are not empty when set.
* doap: Remove stray ... is that a tab or a space?Kim Alvefur2021-11-281-1/+1
|
* doap: Fill in the mandatory 'status' field everywhereKim Alvefur2021-11-281-2/+59
| | | | Some of these may be debatable, investigation and patches welcome.
* mod_admin_shell: Remove now redundant promise awaiting in dns:lookup()Kim Alvefur2021-11-271-6/+1
|
* mod_admin_shell: Remove now redundant promise awaiting in xmpp:ping()Kim Alvefur2021-11-271-6/+3
|
* mod_smacks: Remove left-over debug loggingKim Alvefur2021-11-271-1/+0
| | | | | Wrong level, missing argument, whatever it was meant to shed light on has been resolved and forgotten.
* util.promise: Fix testKim Alvefur2021-11-261-1/+1
| | | | | Could not reproduce locally but it complained in CI that > spec/util_promise_spec.lua:676: Cannot spy on type 'nil', only on functions or callable elements
* mod_admin_shell: Fix indentationKim Alvefur2021-11-261-13/+13
| | | | It was all of for some reason
* mod_admin_shell: Wait for promisesKim Alvefur2021-11-261-0/+5
| | | | I've typed `>require"util.async".wait_for(...)` for the last time!
* util.startup: Integrate util.promise with net.server main loopKim Alvefur2019-01-051-0/+8
|
* util.promise: Support delayed promise executionKim Alvefur2019-01-052-5/+26
|
* mod_admin_shell: Reduce width of 'Status' columnKim Alvefur2021-11-261-3/+3
| | | | | 'unavailable' was the longest possibility, dropping it probably differentiates available from unavailable more, in less space.
* mod_admin_shell: Reduce width of 'Security' column (thanks Link Mauve)Kim Alvefur2021-11-261-3/+3
| | | | Tricky to represent "secure, but no details" in short enough space.
* mod_vcard_legacy: Also respect avatar:metadata access restrictionsEmmanuel Gil Peyrot2021-11-251-1/+1
| | | | | Zash notes this seems to have been lost in 1b657605ea29, probably by mistake.
* mod_admin_shell: Fix showing default HTTP path in module:infoKim Alvefur2021-11-251-1/+1
| | | | Thanks mod_http_openmetrics
* mod_http_openmetrics: Serve HTTP from global contextKim Alvefur2021-11-251-9/+7
| | | | | | | | | | | | Makes GET /metrics work regardless of the value of the Host header. This was not possible before 220468f7a103 which added the ability to have global HTTP modules, which was partly why the per-host part was kept while the module lived among the community modules. Another reason was to provide some semblance of security by obscurity by only loading the module on e.g. a 'localhost' VirtualHost or Component. The new IP limits obsoletes this.
* teal: Describe the module API interfaceKim Alvefur2021-03-241-0/+145
| | | | Helps when writing modules in Teal
* util.prosodyctl.check: Add mod_http_openmetrics settings to known globalsKim Alvefur2021-11-251-0/+2
|
* CHANGES: Mention mod_http_openmetricsKim Alvefur2021-11-241-0/+1
|
* mod_smacks: Optimize scheduling of ack requestsKim Alvefur2021-11-241-1/+2
| | | | | | Taking advantage of the new callbacks added in dcf38ac6a38c and 9c450185bac1 avoids extra timers, extra syscalls and sending the `<r>` in its own TCP segment, improving efficiency.
* mod_smacks: Refactor ack requesting to avoid some timer roundtripsKim Alvefur2021-11-241-56/+62
| | | | | | | | | | The function was too large to comprehend! Breaking it up helps readability and reuse. The timer round rip is only to avoid ordering weirdness when sending from inside a stanza filter. No need when handling <r> and <a> CSI interactions both boiled down to sending an <r> immediately.
* mod_smacks: Fix timer lifetimes to follow session instead of moduleKim Alvefur2021-11-241-8/+12
| | | | | | | module:add_timer() creates a timer that stops working after the module is reloaded or unloaded, in order to prevent leaks. However, when the timers control vital session behavior, breakage occurs after reload. E.g. sessions would stop requesting acks and stop responding to acks.
* mod_smacks: Clean up compat code etcKim Alvefur2021-11-241-54/+39
| | | | | | | | Unstoppable stoppable timer compat not needed since 26f54b462601 ca 0.11.0 module:hook_stanza was renamed in 2012 No idea what was going on with the indentation and such
* mod_smacks: Import from prosody-modules @ eb63890ae8fcKim Alvefur2021-11-163-0/+700
|
* mod_external_services: Warn about missing recommended fieldsKim Alvefur2021-11-241-0/+4
| | | | | | | | These are RECOMMENDED in XEP-0215 so most likely a mistake if they are left out. Of the two REQUIRED fields, 'host' falls back to module.host and 'type' rejects the whole item.
* mod_admin_shell: Factor out simple function in module:info for reuseKim Alvefur2021-11-241-4/+6
| | | | Marginal improvement in readability
* mod_admin_shell: List collected metrics in module:infoKim Alvefur2021-11-242-0/+18
| | | | Lets you know what to look for with stats:show()
* mod_admin_shell: List net providers in module:infoKim Alvefur2021-11-231-0/+1
|
* mod_http_openmetrics: Imported from prosody-modules mod_prometheus @df2246b15075Matthew Wild2021-11-242-0/+141
| | | | | | | | | This version has several changes from the earlier mod_prometheus: - Conversion of metrics into the text-based OpenMetrics format is moved to util.openmetrics - Support for IP-based access control - Compatibility with earlier Prosody versions removed
* mod_csi_simple: Skip initiating flush in all but inactive stateKim Alvefur2021-11-201-1/+1
| | | | | | Both in the flushing and active states the right thing to do is skip directly to returning the data. Also in any unknown state, like if the filter is somehow left behind on module unload.
* mod_csi_simple: Early return on client activity while flushing bufferKim Alvefur2021-11-201-1/+1
| | | | | Cuts down on log and measurement noise. We only want to do these things here when initiating a flush.
* mod_csi_simple: Allow some straggler traffic after flushing bufferKim Alvefur2021-11-201-3/+20
| | | | | | | | | | Statistics from my server shows a high rate of very short buffer hold times, most of which are the result of replies to pings or other iq traffic, or mod_smacks acks and ack requests just after a flush was completed. This grace period should eliminate noise and quick flipping between flushing and inactive mode.
* util.prosodyctl.check: Highlight inconsistency of AAAA records and ↵Kim Alvefur2021-11-201-0/+4
| | | | use_ipv6=false
* util.prosodyctl.check: Respect use_ipv4/v6 in proxy65 checkKim Alvefur2021-11-201-4/+4
| | | | | | | Previously it would complain about lack of an AAAA record for proxy65_target even in an IPv6-less environment. Thanks to libertas for unintentionally calling attention to this.
* util.prosodyctl.check: Take IPv6 support in LuaSocket into accountKim Alvefur2021-11-201-1/+1
| | | | Shouldn't really matter these days, but portmanager checks this way.
* net.server_epoll: Fix streaming downloads (thanks Menel)Kim Alvefur2021-11-191-1/+1
| | | | | | | | | | ff4e34c448a4 broke the way net.http.server streams downloads from disk because it made writes from the ondrain callback no longer reset the want-write flag, causing the download to halt. Writes from the predrain handler still must not trigger anything but additions to the buffer, since it is about to do all the socket writing already.
* core.moduleapi: Fix name of renamed API in log messageKim Alvefur2021-11-181-1/+1
| | | | | | | hook_stanza was renamed hook_tag in 2012 in 2087d42f1e77 Why do we still have hook_stanza? Why is this only a warning anyway?
* net.server_epoll: Try harder to avoid reentrant opportunistic writesKim Alvefur2021-11-181-1/+4
| | | | | | Opportunistic writes sure do complicate things. This is especially intended to avoid opportunistic_writes from within the onpredrain callback.
* mod_csi_simple: Skip flushing of empty bufferKim Alvefur2021-11-181-0/+2
| | | | Just adds noise