This will make it easier to make changes and reuse code on the future.
They were grouped together by only the storybook title.
Now they are on the same folder, which is `frontend/libs/console/legacy-ce/src/lib/Permissions`.
Since now they are together, removed the title to all storybook stories.
Important: I did not make any behavior changes. Only moved code around. I need this for a separate PR but I thought it was good to create this isolated PR with non behavioral changes so it's easy to review (it has a lot of files changed).
Jira ticket: https://hasurahq.atlassian.net/browse/DSF-496
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9974
GitOrigin-RevId: 940020d06e0144eac95c614f84aea122852396b9
This turns on the `partial-fields` warning, which yells at you if you try and create fields on sum types that end up being partial functions. These are dangerous; we had a bug because we introduced a new case to a data type, making the field accessors partial, and leading to a crash in certain cases.
This means that we have introduced a few wrappers in various places where the field names are useful, but we want to avoid partial matches.
Unfortunately this can be turned off by prefixing the field name with an underscore. Ideally we would try and avoid exporting any field names with underscores, but lenses make this hard. I have removed some underscores for the areas in which we've seen this break in the past.
We will have to be vigilant.
[NDAT-794]: https://hasurahq.atlassian.net/browse/NDAT-794?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9991
GitOrigin-RevId: fd69b1ef999682969f3507f0e97513f983da4da6
I scratched out some changes to support this in the front end, mostly to test it easily, maybe this can be used without much rework (validation seems to work correctly, but the tests need to be extended and probably fixed):
<img width="648" alt="fd" src="https://github.com/hasura/graphql-engine-mono/assets/68095256/e5873a90-ef83-43c3-9d54-cfc0a693baca">
-------
## Fake OTel collector for testing
ChatGPT spit this out, and it's what I used to test, if it's useful to others:
``` python
from flask import Flask, request
from opentelemetry.proto.collector.trace.v1.trace_service_pb2 import ExportTraceServiceRequest
from opentelemetry.proto.collector.metrics.v1.metrics_service_pb2 import ExportMetricsServiceRequest
import google.protobuf.json_format as json_format
app = Flask(__name__)
@app.route("/v1/traces", methods=["POST"])
def handle_traces():
if request.method == 'POST':
binary_trace = request.get_data()
trace_request = ExportTraceServiceRequest()
trace_request.ParseFromString(binary_trace)
print("Received trace data:\n")
print(json_format.MessageToJson(trace_request, indent=2, preserving_proto_field_name=True))
return "Trace data received", 200
@app.route("/v1/metrics", methods=["POST"])
def handle_metrics():
if request.method == 'POST':
binary_metric = request.get_data()
metric_request = ExportMetricsServiceRequest()
metric_request.ParseFromString(binary_metric)
print("Received metrics data:\n")
print(json_format.MessageToJson(metric_request, indent=2, preserving_proto_field_name=True))
return "Metrics data received", 200
if __name__ == "__main__":
app.run(host="0.0.0.0", port=8080)
```
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9552
Co-authored-by: Puru Gupta <32328846+purugupta99@users.noreply.github.com>
Co-authored-by: Toan Nguyen <1615675+hgiasac@users.noreply.github.com>
Co-authored-by: Varun Choudhary <68095256+Varun-Choudhary@users.noreply.github.com>
Co-authored-by: Daniele Cammareri <5709409+dancamma@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Rob Dominguez <24390149+robertjdominguez@users.noreply.github.com>
GitOrigin-RevId: f340bfc5c135a7bb24735b524d015e05db422fd2
A fix for #9447
Before this change, for the workload in the ticket, we saw a memory stay at around 4 GB an hour after the workload ended. after this change we see both a lower memory high watermark, and also see memory come back to baseline at the end as we expect (after the `HASURA_GRAPHQL_PG_CONN_LIFETIME` and a subsequent `_idleStaleReaperThread` interval elapses). But note the numbers given on any given machine may be slightly different, since the behavior depends on the version of glibc and processor speed (Since the test case depends on the server being overloaded).
This might also help some users commenting in https://github.com/hasura/graphql-engine/issues/9592
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9823
GitOrigin-RevId: 5650aa42d10d46c418c21686983a982d69011884
This PR updates the docs on restified endpoints.
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9867
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Sean Park-Ross <94021366+seanparkross@users.noreply.github.com>
Co-authored-by: Rob Dominguez <24390149+robertjdominguez@users.noreply.github.com>
GitOrigin-RevId: 94b9ea60352e2ba6b096ef2686b5bfd38ff53d41