Commit Graph

78 Commits

Author SHA1 Message Date
Danny van Kooten 5e4ce53eb8 sqlite re-uses ID for columns not marked as autoincrement, so use that. fixes #202 2019-02-04 13:58:25 +01:00
Danny van Kooten eb2eb726f3 keep running aggregator job until pageview pool is emptied. 2018-12-24 09:41:11 +01:00
Danny van Kooten 634baac518 explicitly declare innodb as storage engine for mysql databases & only index first 100 chars of index columns. closes #198 2018-12-24 09:10:11 +01:00
Danny van Kooten 67277ec26f increase busytimeout for sqlite to 10s 2018-12-24 09:09:22 +01:00
Danny van Kooten a04307e0de use LIMIT #, OFFSET # syntax for compat across all database drivers. fixes #188 2018-11-22 21:19:52 +01:00
Danny van Kooten 019b7c9743 show pagination arrows in table component which allows paginating the table results. closes #153 2018-11-20 12:11:35 +01:00
Danny van Kooten da87d2a173 fix aggregate queries for postgresql 2018-11-14 14:14:19 +01:00
Danny van Kooten da6ffde2ea speed up host & pathname migration by using UNION. perform VACUUM for SQLite migrations. 2018-11-14 12:40:01 +01:00
Danny van Kooten e92b4b9a29 clean-up route & func names 2018-11-14 11:47:47 +01:00
Danny van Kooten 7ccdea4535 don't COALESCE when it's unnecessary 2018-11-14 10:27:14 +01:00
Danny van Kooten b5ee8ea5f0 in postgresql, pageviews.timestamp column should be without timezone 2018-11-14 09:31:34 +01:00
Danny van Kooten 2ca1e0f36e switch to hourly storage for stats.
- allows showing an hourly chart on the 'today' view
- fixes timezone issues when in 'today' view #134
- increases size of stats tables by factor 24, but that should be less of an issue after dbcadcd737
2018-11-13 15:23:18 +01:00
Danny van Kooten 21c0f97b1b cannot vacuum from inside a transaction 2018-11-13 11:16:23 +01:00
Danny van Kooten dbcadcd737 normalize hostname and pathname columns
to save on disk storage
2018-11-12 14:45:21 +01:00
Danny van Kooten cb25b267da show only database name and maybe host when logging successful db connection. #174 2018-11-02 12:30:34 +01:00
Danny van Kooten 4dec431c4b use unexported values for sqlstore.Config struct fields 2018-11-02 11:50:43 +01:00
Christopher "Chief" Najewicz acd182689b Obfuscate DSN password when logging connection details, fixes #174 (#176) 2018-10-30 20:10:21 +01:00
Danny van Kooten f92d04a4ba default value for pageview.IsBounce should be true, not false. 2018-10-10 16:38:29 +02:00
Danny van Kooten 6bc1af3564 set sqlite _busy_timeout to 5s to handle database is locked errors 2018-10-10 11:59:21 +02:00
Danny van Kooten 3b99e78135 set sqlite _busy_timeout to 5s to handle database is locked errors 2018-10-10 11:59:17 +02:00
Danny van Kooten 470db5189d get rid of some column placeholders so we can increase buffer cap #132 2018-10-10 10:50:05 +02:00
Danny van Kooten 3c934b29fc add is_finished column indicating whether a pageview is done (ready to be aggregated). closes #123 2018-10-10 10:27:55 +02:00
Danny van Kooten c877319046 fix DROP INDEX statements for mysql 2018-10-10 10:27:16 +02:00
Danny van Kooten 051d0addb3 fix realtime visitor count query incl. bc for pageviews without an expliti site tracking ID 2018-10-10 09:45:17 +02:00
Danny van Kooten 2f64d56771 alter stats table constraints to take site_id column into consideration 2018-10-10 09:30:52 +02:00
Danny van Kooten ce8f585827 sqlstore GetXStats funcs should return nil when there are 0 results. #50 2018-10-10 09:02:32 +02:00
Danny van Kooten 1b06bd3179 change precision on numeric columns for postgres so we don't have to apply rounding. closes #116 2018-10-09 13:27:50 +02:00
Danny van Kooten 0f0db205ae account for empty site_tracking_id in realtime visitor query 2018-10-09 11:57:56 +02:00
Danny van Kooten 84cd897319 use auto increment column for pk on sites table 2018-10-09 11:17:26 +02:00
Danny van Kooten 80088570b0 default to site_id 1, even though it may not exist yet 2018-10-05 16:07:15 +02:00
Danny van Kooten 53c1702d0d only re-fetch data when needed 2018-10-05 15:13:48 +02:00
Danny van Kooten 876309ae59 clean-up sqlstore pkg 2018-10-05 14:34:39 +02:00
Danny van Kooten d4176de238 get aggregator to take site ID's into account 2018-10-05 14:19:11 +02:00
Danny van Kooten c1367325e6 modify all routes & queries to take a site ID parameter 2018-10-05 13:09:58 +02:00
Danny van Kooten dc8bf7fdc3 modify tracker.js to take a siteId and insert that into pageviews table. add siteId to tracking snippet. 2018-10-05 10:07:00 +02:00
Danny van Kooten 4c4a42879c fix ID assignment in SaveUser func 2018-10-04 13:44:36 +02:00
Danny van Kooten 927c50b419 add & delete sites through api 2018-10-03 15:27:36 +02:00
Danny van Kooten 61cc23eb0d fetch sites from server & update dashboard state from site switcher 2018-10-03 11:54:48 +02:00
Danny van Kooten f721b75f43 modify SaveUser to support updating existing users 2018-10-03 10:47:23 +02:00
Danny van Kooten 4b855c6d05 add site related func to sqlstore 2018-10-03 10:44:31 +02:00
Danny van Kooten 26d7ba5578 Merge branch 'master' into multiple-sites
* master:
  use classnames to determine main-col
  add actual lib 😅
  use classNames for table row width
  use classname for active state
  use classnames for loading state
  add classnames as a dependency
  update README on new user command
  rework user cli management
2018-10-02 11:02:19 +02:00
Danny van Kooten 7c3adcb10b rework user cli management 2018-09-26 14:44:13 +02:00
Danny van Kooten f0eecc04cd add sites table & site_id columns for multi-site tracking #50 2018-09-25 15:03:07 +02:00
Danny van Kooten d116f1fd70 limit buffer capacity to 99 pageviews, hotfix for #132 2018-09-21 09:30:05 +02:00
Danny van Kooten 2ff9676043 always show at least 1 visitor if there are pageviews. #129 2018-09-19 08:21:04 +02:00
Vincent Boutour e712f0fcdd
Adding /health endpoint and using it in container 2018-09-17 17:20:48 +02:00
Danny van Kooten 291d53fcaf add CountUsers func to sqlstore 2018-09-12 09:11:50 +02:00
Danny van Kooten 4ecaff85ac don't parse database driver from URL to also support mysql and sqlite. 2018-07-31 15:29:15 +02:00
Charley DAVID 98970057a2
Add support for FATHOM_DATABASE_URL 2018-07-31 08:41:08 -03:00
Danny van Kooten e90e100f18 fix query args for batch updating pageviews 2018-07-30 10:51:20 +02:00