0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-11-25 02:49:32 +01:00
Commit Graph

38 Commits

Author SHA1 Message Date
Tiina Turban
7ba84b406a
Update defaults based on self-hosted env values (#7709) 2022-01-13 00:45:30 +01:00
Karl-Aksel Puulmann
b431a65cb2
Set ASYNC_MIGRATIONS_DISABLE_AUTO_ROLLBACK (#7881) 2022-01-04 16:15:19 +02:00
Karl-Aksel Puulmann
76131a285c
Revert "Revert "Proposal: Clean up settings.py"" (#7669)
* Revert "Revert "Proposal: Clean up settings.py (#7630)" (#7668)"

This reverts commit 704110fe52.

* Handle dynamic settings

* Handle cloud imports differently, fail early

* update flags

* Port async migrations

* Update cloud tests

* Update task definitions

* Revert CI hack
2021-12-16 12:14:21 +02:00
James Greenhill
ab0c75414b
Make settings dynamic for MATERIALIZED_COLUMNS_ENABLED (#7662)
* Make settings dynamic for MATERIALIZED_COLUMNS_ENABLED

* migrate MATERIALIZED_COLUMNS_ENABLED to this and test

* allow tests that use materialized columns to hit django model for settings

* nicer installed apps config

* update snapshot from test

* make test_property more deterministic

Co-authored-by: James Greenhill <fuzionech@gmail.com>
Co-authored-by: yakkomajuri <yakko.majuri@gmail.com>
2021-12-14 17:56:08 -08:00
Karl-Aksel Puulmann
44ee58f5f4
Enable performance improvements on cloud for us + a client (#7578) 2021-12-08 17:17:03 +02:00
James Greenhill
1ee27642f2
re-enable materialized columns (#6500) 2021-10-17 10:43:39 -07:00
James Greenhill
507015b95e
Add Env var switch for Materialized Columns (#6498)
* Add Env var switch for Materialized Columns

* Disable Mat Cols for now

* false -> 0
2021-10-17 07:49:45 -07:00
Michael Matloka
e97c20ad33
Purge PLUGIN_SERVER_ACTION_MATCHING flag (#6358)
* Remove `PLUGIN_SERVER_ACTION_MATCHING` flag

* Fix action bug

* Try to fix mocking
2021-10-11 21:33:48 +02:00
James Greenhill
ed9237f121
Update ulimit and use settings from json in console (#6321) 2021-10-08 00:29:06 +00:00
James Greenhill
417d975b31
Bump ulimit for services on ECS (#6320) 2021-10-07 23:46:11 +00:00
Karl-Aksel Puulmann
3ac74a8472
Clickhouse flamegraphs (#5752)
* WIP: flamegraphs

* Get flame graphs generating

* Add files to bin

* Crude frontend for analyzing

* Hack: Use a stable clickhouse host instead of conn pool for flamegraphs

Otherwise no way to get back measurements due to LB.

* Error handling

* Only allow read queries

* Hide query analyze button for non-owners

* Make sure non-admins can't run queries

* Fix query issue
2021-09-08 16:24:44 +03:00
Tim Glaser
ae5664851d
Increase parallel cohorts to 50 (#5709) 2021-08-24 11:17:47 -07:00
Tim Glaser
2f0e0d08a5
Increase # cohorts to calculate in parallel (#5669) 2021-08-20 16:18:42 +02:00
Sam Winslow
1561cbb932
Add HUBSPOT_API_KEY secrets manager arn (#5517)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-08-09 22:18:34 +00:00
Karl-Aksel Puulmann
a860da9e90
Dynamic materialized columns (#5458)
* Add migration marking existing columns as materialized with a comment

* Add method to allow looking up materialized columns

* Add test for fetching and creating materialized columns

* Disable caching in tests

* Remove some callsites to CLICKHOUSE_DENORMALIZED_PROPERTIES

* Fixup caching logic

* Add (currently broken) test for denormalizing person properties

* Update funnel event query to work with new functionality

* Update other tests/queries

* Remove now-unused setting
2021-08-09 10:11:36 +03:00
Paolo D'Amico
0470359f1c
Maintain default feature flags behavior on cloud (#5296) 2021-07-30 10:37:29 -07:00
Karl-Aksel Puulmann
42df34418d
Set USING_PGBOUNCER env var everywhere (#5120)
We use it in settings.py to disable server-side cursors, but do not
explicitly set it. Fixing this.
2021-07-14 11:38:47 -07:00
PostHog bot
27144478f5
Update plugin server to 0.21.26 (#4809) 2021-06-19 02:40:49 +02:00
Michael Matloka
69afc5abc2
Set PLUGIN_SERVER_ACTION_MATCHING to 0 (#4805) 2021-06-18 15:08:50 +00:00
Michael Matloka
5394533bde
Don't fire webhooks and Zapier in case of PLUGIN_SERVER_ACTION_MATCHING (#4794)
* Don't fire webhooks and Zapier in case of PLUGIN_SERVER_ACTION_MATCHING

* Add PLUGIN_SERVER_ACTION_MATCHING to settings

* Add PLUGIN_SERVER_ACTION_MATCHING to ECS task defs

* Remove leftover print

* Update `AsyncActionMappingNotice`

* Remove stale import
2021-06-18 16:32:29 +02:00
Paolo D'Amico
01b7daacc2
Remove NewRelic from Cloud (#4716)
* remove NR

* remove secret key too
2021-06-14 11:01:57 +02:00
Karl-Aksel Puulmann
030529cfb3
Show internal metrics on /instance/status page (#4366)
* Extract function for capture

* Add capability to capture internal metrics

- This is behind an environment variable, we'll turn this on by default
on clickhouse-based installation.
- A special Org/Team gets created for this lazily, which is not accessible for
anyone. This makes avoiding issues with stats/billing/properties and easier.

* Capture some useful metrics into posthog

* Set up an unique constraint for for_internal_metrics organization

This avoids some nasty race conditions

* internal_metrics fixes

* Extract component OverviewTab

* New tabbing system for system status page

* Embed ClickhouseTab

* Generate a dashboard for internal metrics on demand

* More metrics

* Add more internal metrics, add tests

* Fix migration files

* Adjust copy

* Update task definitions

* Fix a typing issue

* Rename a component

* Migration fixup

* Try reset patch after test ends

* Clear lru_cache between tests
2021-05-20 13:42:39 +03:00
Karl-Aksel Puulmann
f4009c1e16
Allow migrating on a clickhouse cluster (#4197)
* Allow migrating clickhouse on cluster

Context under https://github.com/PostHog/posthog/issues/4090

* Add option to print sql
2021-05-05 14:38:39 +03:00
James Greenhill
b7bc93cfac
Enable cleanup of SSM Task that enables us to exec into containers on ecs (#4096) 2021-05-04 14:22:20 +00:00
Paolo D'Amico
2020c32c66
Add NewRelic to cloud deployment (#4005) 2021-04-15 11:53:19 -07:00
Michael Matloka
286287e8e1
Remove IS_DOCKER env var (#3843) 2021-04-01 17:10:00 +02:00
Paolo D'Amico
433d560b23
Fix proxy config (#3654) 2021-03-23 13:12:06 -07:00
Tim Glaser
e7c0f5f8cf
Enable event property usage env vars (#3664) 2021-03-16 11:27:58 +01:00
Paolo D'Amico
7c4b7eb811
Cloud billing trial period & free plan (#3259) 2021-02-11 18:42:39 +01:00
Tim Glaser
f1f8a0b7f5
Add denormalized prop config (#3009) 2021-01-20 13:53:45 +01:00
Marius Andra
606525644e
Add deployment environment variables (#2874)
* add deployment env to track instances

* Rename Production ECS

Co-authored-by: Karl-Aksel Puulmann <oxymaccy@gmail.com>
2021-01-11 13:25:40 +01:00
Paolo D'Amico
1ef890fbf2
add missing env vars to plugins & worker tasks (#2869) 2021-01-06 18:17:45 +01:00
Marius Andra
098343cbee
Deploy Plugins to AWS (#2755)
* create plugins task

* add plugins to container

* remove env vars that are probably not needed

* bump size of node for plugins

* don't run plugin server on worker

Co-authored-by: James Greenhill <fuziontech@gmail.com>
2020-12-15 18:10:00 -08:00
Michael Matloka
7ba9f7de09
Plugin server ingestion base (#2732)
* Add relevant settings to KEYS in bin/plugins-server

* Log all EE events to events_handoff Kafka topic for plugin server

* Clean up settings

* Fix FOSS

* Don't introduce KAFKA_EVENTS_HANDOFF

* Add cosmetic newline

* Add DEBUG WAL print()
2020-12-14 16:05:18 +01:00
James Greenhill
1ed68dcfb8
Actually set env var for DISABLE_SERVER_SIDE_CURSORS to True (#2692) 2020-12-07 13:35:15 -08:00
James Greenhill
7c90eb64fe
DISABLE_SERVER_SIDE_CURSORS to false for pgbouncer friendship (#2677)
* DISABLE_SERVER_SIDE_CURSORS to false for pgbouncer friendship

* USING_PGBOUNCER
2020-12-04 17:44:02 -08:00
James Greenhill
97280d56fc
update url env var for ECS containers (#2660) 2020-12-03 16:16:32 -08:00
James Greenhill
ed6eb5e796
Setup ecs configs for web, worker, migration tasks and services (#2458)
* add worker to the ecs config and deploy

* for testing

* pull from this branch for testing

* chain config renders

* split out events pipe

* Set is_heroku true because of heroku kafka

* update /e/ service to run on port 8001

* add 8001 to the container definition as well

* simplify

* test migrating w/ ecs task using aws cli

* split services

* typo in task def

* remove networkConfiguration from task definition

* duplicate

* task-def-web specific

* update events service name

* Handle base64 encoded kafka certs

* if it's empty then try to set it for env vars

* fix b64 decode call

* cleanups

* enable base64 encoding of keys for kafka

* depend on kafka-helper for deps

* reformat

* sort imports

* type fixes

* it's late, I can't type. typos.

* use get_bool_from_env

* remove debug bits. Trigger on master/main

* prettier my yaml

* add notes about ref in GA

* up cpu and memory
2020-12-03 15:51:37 -08:00