* docs(deployment): Explain how to setup metrics
close#2411close#2777
* Update docs with some info I found useful
Co-authored-by: mattwr18 <mattwr18@gmail.com>
Ok, so here is the plan. Let's give both our cucumber features and your
cypress tests a prominent place to live. That would be the root level
folder of our application. Second, let's revive formerly dead code step
by step.
Ie. move code from the former location `backend/features/` to `features/`
when it is ready. All edge cases should be tested with unit tests in
`backend/`, see my `webfinger.spec.js` as an example.
- I was getting an error locally Failed: error parsing query as Extended JSON: invalid JSON input
- updating the syntax to wrap the json in single quotes, and key/values
in double quotes fixed the issue
- update memory limits
- we need to remove the whitespaces first, then check if there are still illegitimate characters in the hashtag before removing them
- this is to maintain the maximum number of hashtags imported from the legacy database as possible
I think it's beneficial to have these settings in a central location.
That way, we're not running into the danger of overwriting the
`nitro-deployment` by accident with a `kubectl apply -f ...`.
Ok, so here are multiple issues:
1. In cypher, `NOT NULL` will return `NULL` not `FALSE`. If we want
`FALSE` to be set in the database import, we should use `COAELESCE`
to find the first not-null value.
See:
https://neo4j.com/docs/cypher-manual/current/syntax/working-with-null/https://markhneedham.com/blog/2017/02/22/neo4j-null-values-even-work/
2. I removed the `disabled` and `deleted` checks on the commented
counter. With `neo4j-graphql-js` it is not possible to filter on the
join models (at least not without a lot of complexity) for disabled or
deleted items. Let's live with the fact that the list of commented posts
will include those posts, where the user has deleted his comment or where
the user's comment was disabled. It's being displayed as "not available"
so I think this is OK for now.
3. De-couple the pagination counters from the "commented", "shouted"
etc. counters. It might be that the list of posts is different for
different users. E.g. if the user has blocked you, the "posts" list
will be empty. The "shouted" or "commented" list will not have the
posts of the author. If you are a moderator, the list will include
disabled posts. So the counters are not in sync with the actual list
coming from the backend. Therefore I implemented "fetch and check if
resultSet < pageSize" instead of a global counter.
- allows the client to send files at least the size we agreed in the vue-dropzone
- we don't need such a small split size as we don't run it on the remote server
- I think this does what you want @Tirokk, but let me know if I missed something
- this removes all white spaces in the hashtag, then removes any hashtags that have special characters, or that start with a number, but do not have any letters after
- it does not check that the size is greater or equal to 1 because the regex already removes anything that does not have at least one character
I cannot increase the memory above "2G" without getting an error that no
node has capacity for it. So I believe we have to change the kubernetes
cluster if we want to assign more memory to neo4j.
The other settings were suggested to me by neo4j-admin memrec:
https://neo4j.com/docs/operations-manual/current/tools/neo4j-admin-memrec/
Bug:
> apoc.cluster.graph is unavailable because it is sandboxed and has dependencies
> outside of the sandbox. Sandboxing is controlled by the
> dbms.security.procedures.unrestricted setting
See: https://stackoverflow.com/a/48773575