summaryrefslogtreecommitdiff
path: root/src/weepinbell/processor.clj
AgeCommit message (Collapse)Author
2026-09-23processor: refactor processor; replace mf2j with mf2cljeltrac
- replace mf2j with mf2clj - remove utils.clj completely - refactored processor, use Chain of Responsibilities pattern and pass around maps to reuse data (so we don't have to make a separate HTTP request just to parse microformats, etc.) - test: add more test cases to verifier test - test: add basic test cases to all processing steps - add more logging to each processing steps. good for debugging.
2026-09-19processor, webhook: send webhooks with customizable payloadeltrac
- processor will call hook functions with webmention data - refactor webhook.clj massively - add dynamic parameter substitution for urls, e.g. {source} {target} {event}...... - add config option :webhook-request, a function with parameters [hook, data] that returns a map (resembling {:headers ... :body ...}). webhook.clj uses this function to generate payload. - allow map besids URL string in config option :webhook. if it's a URL, sends webhook request to it with payload generated by :webhook-request; if it's a map, it should be like {:url ... :request-fn ...}, which specifies a payload generator. - add request-fn preset :ntfy
2026-09-14processor, verifier, webhook: tidy up log msg/level; improve code styleeltrac
processor: tidy up log msg and level; improve code style - all messages start with a lower-case letter - all webmention-related logging contains first 8-digit of its id - use WARN level when something is deleted, not INFO - use WARN level when exceptional cases happen, not ERROR - get rid of emojis in log messages utils: digest-short function for logging verifier: tidy up log messages; improve code style - use `cond` instead of nested `if`s - same message format as processor's logs webhook: tidy up log messages; send webhooks robustly - use same logging formats as processor and verifier - handle error, 4xx, 5xx status and log them - move logging inside webhook module, away from core.clj
2026-05-12refactor(processor): do not depend on config directlyeltrac
2026-05-09style: format all source codeeltrac
2026-05-08fix(processor, verifier): not deleting wm when url respond with HTTP erroreltrac
Content-Type checks are somehow written in process-webmention function, when it should be in verify-mention function, which causes weepinbell not deleting Webmention when one of target and source is not found (or any other HTTP status code that is not 2**)
2026-05-06refactor(processor): separate verification from processor logiceltrac
2026-05-06fix(processor): make process-webmention publiceltrac
you can't test it if it's private
2026-05-06fix(processor): cannot use <! outside of go-loopeltrac
2026-05-06refactor(processor): a thin wrapper of process-webmentioneltrac
process-webmention used to start a go-loop directly. this commit separates go-loop from processing logic, core.clj now calls to processor/start, the wrapper function.
2026-05-06refactor(processor): remove storage dependency in processoreltrac
2026-05-06refactor(processor): make storage plug-in through callback funceltrac
2026-04-22refactor: simple DI using callbackseltrac
2026-04-20feat: add more webhookseltrac
on-create, on-update and on-delete
2026-03-23refactor: separate microformats and wrapper from processoreltrac
2026-03-17feat(webhook): trigger webhooks on receiving new mentionseltrac
2026-03-16feat: generate unique id for each Webmentioneltrac
2026-03-16feat: image proxy for microformats author photoseltrac
2026-03-16refactor: move javamap->map to utils.cljeltrac
2026-03-16perf: only get first 1MB of content when verifying mentioneltrac
according to https://www.w3.org/TR/webmention/#limits-on-get-requests-p-4:~:text=Receivers%20should%20place%20limits%20on%20the%20amount,JSON%20page%20will%20be%20smaller%20than%20that.
2026-03-16refactor: log with timbre instead of printlneltrac
2026-03-16chore: print logs when processing existing webmentioneltrac
2026-03-16fix: falsely receive webmention for non-HTML/text documentseltrac
2026-03-12fix: robust parse-microformatseltrac
2026-03-12fix: robust verify-mention, handle HTTP erroreltrac
2026-03-12chore: remove incorrect logeltrac
2026-03-10feat: store last modified timeeltrac
2026-03-10refactor(storage): rename append -> append-wmeltrac
2026-03-09feat: add microformats parser and wrap mf in webmention dataeltrac
2026-03-09chore(deps): remove unused java-time depeltrac
2026-03-09fix: store miliseconds instead of datetime objecteltrac
2026-03-05feat: UNFINISHED handle Webmention editing, deleting and appendingeltrac
the storage part was unfinished and unserviceable.
2026-03-05fix(dependency): incorrect namespace when requiring java-timeeltrac
2026-03-05style(processor): simplify code with when-leteltrac
2026-03-04refactor: move data structure to wrap-webmention functioneltrac
2026-03-03feat: UNFINISHED file-based storageeltrac
2026-03-03feat: verify webmention, GET source in search of mentioneltrac
2026-03-03refactor: move webmention channel to entry file; pass to receiver and processoreltrac