Commit Graph
58 Commits
Author SHA1 Message Date
Umputun 0f433722da disable picture upload for anonymous 2019-04-04 01:53:47 -05:00
Umputun db3f22d9fd change image submit to single goroutine with active wait. flush all submitted on close 2019-03-23 19:13:58 -05:00
Umputun 58ec50e613 wire image submit to store.Service 2019-03-23 18:33:19 -05:00
Umputun c990b05c21 add image service with delayed commit. Move cleanup loop to service 2019-03-23 14:54:45 -05:00
Umputun b49e242891 wire image staging and image cleanup 2019-03-23 03:06:24 -05:00
Umputun bc714480d4 lint: multiple shadowed errors, missed comments for exported methods 2019-03-19 20:54:05 -05:00
Umputun 58eb4e8852 typos 2019-03-11 14:09:05 -05:00
Umputun 639f6c15f3 wire image save/load to rest and cmd 2019-03-11 01:16:25 -05:00
Umputun 0c950ae4f7 add anon option and direct provider #279 2019-02-19 13:59:43 -06:00
Umputun 0fe3f6dd7d fix bad default for restricted words 2019-02-02 13:38:40 -06:00
Umputun cb5fc79dbe add site-level positve score support #260 2019-01-26 01:38:56 -06:00
Aleksandr MelnikovandUmputun ab6c9a515c Support restricted words (#257)
* prepared interfaces and naive implementation for restricted words

* fixed whitespace tokenizer last token handling

* removed unnecessary check in whitespace tokenizer last token handling

* removed unnecessary interfaces, added matcher to service

* now using more explicit naming

* added config parameter/env variable to configure restricted words
provided simple matcher and lister implementation into service

* fixed linter warnings

* fixed linter warnings (part 2)

* added functional tests for rest api
moved check for restricted words into validation stage

* fixed missing error check in rest private test

* fixed failed test that expected validation in specific order

* fixed linter warning

* removed unnecessary 'else'

* removed redundant check from 'DataStore.EditComment'

* replaced exact matching for restricted words with wildcard matching

* fixed race condition when creating wildcardTrie
removed unnecessary wildcard masks
refactored tests in a table format

* improved documentation for restricted words param

* removed wildcardTrie caching as a premature optimization
removed unnecessary validation method ValidateCommentText
moved restricted words validation into service methods that create and update comment

* fixed error name due to linter warning
2019-01-21 16:48:35 -06:00
Umputun 62b54eb009 resort imports 2019-01-17 18:50:02 -06:00
Umputun 2a3051c620 allow separate limiter for updates and posts, agressive default limit 2019-01-17 14:56:11 -06:00
Umputun f7403f08b9 inject refresh cache to auth, revendor go-pkgz/auth to 0.4 2019-01-17 13:17:16 -06:00
Umputun 781d90e98b switch to lgr 2019-01-07 22:32:50 -06:00
Umputun 0fd8657992 make title extractor optional 2019-01-05 13:22:28 -06:00
Umputun 7b54b00c01 switched to auth 0.3 2019-01-04 18:09:18 -06:00
Umputun 7deee9aaa1 revendor with lateas auth lib, sets logger to stdout 2018-12-30 23:06:20 -06:00
Umputun 80467c39af switch utils commands to basic auth, remove secret passing 2018-12-30 18:00:32 -06:00
Umputun 195e65ca60 adjusted tests for new auth lib 2018-12-30 13:31:03 -06:00
Umputun acf19e73cf minor formatting 2018-12-29 18:36:34 -06:00
Umputun d33997c742 pass auth by reference 2018-12-28 00:49:46 -06:00
Umputun 60700d96c7 isolate authenticator creation to a separate methos 2018-12-28 00:37:02 -06:00
Umputun 09de97ffd6 resort imports 2018-12-28 00:02:35 -06:00
Umputun 085468e788 missing remark url in auth init 2018-12-27 23:49:06 -06:00
Umputun c4b10a395a most test passes with ext auth 2018-12-27 23:11:20 -06:00
UmputunandGitHub 2fc027299f Merge branch 'master' into migrator-meta 2018-12-24 00:35:09 -06:00
Umputun 094f4c66a1 replace confusing name for native import/export provider 2018-12-21 20:01:03 -06:00
UmputunandGitHub 2ecc08fb3e Ext cache (#236)
* remove  cache, switch to go-pkgz/rest/cache

* remove mongo cache from server test

* remove old caching code

* test tricky disqus inputs

* fix migrator test

* stacktrace dump test
2018-12-19 21:57:33 -06:00
Umputun 5c5abdd679 missing docs ro read-only age 2018-12-15 22:47:17 -06:00
Anton KosourovandUmputun 8f678ad04e Feature/add autocert support (#217)
* add le support

* fix log info

* change readme for autocert mode

* rename acme location param

* add test for http challenge

* add acme-email param

* do tls config more sane
2018-11-25 13:12:07 -06:00
Aleksandr MelnikovandUmputun f8e36551ea added maximum votes limit per comment (#223)
* added maximum votes limit per comment

* added 'max-votes' param description into README
2018-11-23 17:47:42 -06:00
Umputun a66886a731 add telegram init test with wrong port and fake token 2018-11-04 12:48:19 -06:00
Umputun 0f3243e19b close notifier in shutdown sequence 2018-11-04 11:51:08 -06:00
a.kosourov 0e84c61c96 move ssl parts to ssl.go 2018-11-04 16:15:45 +03:00
a.kosourovandakosourov 5ebfb1518a Add https support, static mode for rest server 2018-10-28 18:16:00 +05:00
Umputun d80b2d33cb and nop notifier 2018-10-26 00:37:58 -05:00
Umputun e514af76b0 unify none keys, explicit nil for failed notifier 2018-10-25 20:41:08 -05:00
Umputun 928f483021 don't fail app on failed notify init 2018-10-25 13:21:07 -05:00
UmputunandGitHub 8c5531b178 Notify (#211)
* add notify service with no destinations

* change to request for destinations

* add telegram notify and wire to main

* lint: missed err checks

* fix notify factory

* externalize timeout for notify

* fix race in notifier mock

* lint: check notify send status in tests

* lint: write warn

* lint: wrong assignment

* lint: two more writes in tests

* missing notif timeout default
2018-10-24 22:28:56 -05:00
Umputun ef5b18c3d1 add nop cache 2018-10-05 13:31:33 -05:00
UmputunandGitHub c70e060d22 Feature/avatar_bolt (#205)
* add bolt implementation of avatar store

* include bolt avatar store in main's test

* change docs with new avatart params

* lint: single line declaration

* separate bucket for avatars metas

* fix comments

* test for bolt params

* closable avatar store

* fix dbl-close
2018-09-14 20:33:40 -05:00
Umputun dc59fc9f7b adjust test for key store 2018-09-12 00:34:36 -05:00
Umputun 6458f622d2 refactor to combine admin and key store 2018-09-11 11:58:50 -05:00
Umputun 396b77e4ff info messages and less verbose auth with dev 2018-09-11 00:36:46 -05:00
Umputun 79b1c47005 more dbg info on types 2018-09-10 22:18:23 -05:00
Umputun 7934d9af73 add cli for AvatarCmd 2018-09-10 20:48:36 -05:00
Umputun a856fd9c7d pass revision as common opts instead of package global 2018-09-10 10:44:22 -05:00
UmputunandGitHub 75a1edcff3 feature/adm_mongo (#201)
* add admin akd key mongo implementations

* wire admin and key stores to mongo

* lint: wrong comment on keys store

* typos and comments corrections

* fix failed test on avatar resizer

* get rid of ineffectual assignment in test

* add tests for encoding fallback and mongo's keys & admin

* empty encode test adjusted
2018-09-09 16:59:33 -05:00