Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Service unable to restart after crashing #202

Open
doooooooooots opened this issue Mar 21, 2024 · 1 comment
Open

Service unable to restart after crashing #202

doooooooooots opened this issue Mar 21, 2024 · 1 comment

Comments

@doooooooooots
Copy link

Hi. I hope you're doing fine.

After trying to retreive some files using nhost.storage.getPublicUrl function, my hasura storage crashed.

image

Since then, the server is unabled to restart :

  • In log/hasura :
{
  "detail": {
    "http_info": {
      "content_encoding": null,
      "http_version": "HTTP/1.1",
      "ip": "10.110.27.195",
      "method": "POST",
      "status": 400,
      "url": "/v1/metadata"
    },
    "operation": {
      "error": {
        "code": "already-exists",
        "error": "field with name \"bucket\" already exists in table \"storage.files\"",
        "path": "$.args"
      },
      "query": { "type": "pg_create_object_relationship" },
      "request_id": "2803cfb1-7794-4151-8d2a-fb5a8204bcfa",
      "request_mode": "error",
      "response_size": 120,
      "uncompressed_response_size": 120,
      "user_vars": { "x-hasura-role": "admin" }
    },
    "request_id": "2803cfb1-7794-4151-8d2a-fb5a8204bcfa"
  },
  "level": "error",
  "timestamp": "2024-03-21T12:27:48.717+0000",
  "type": "http-log"
}
  • in log/storage :
2024-03-21 13:27:48 | hasura-storage | time="2024-03-21T12:27:48Z" level=info msg="starting server"
2024-03-21 13:27:48 | hasura-storage | time="2024-03-21T12:27:48Z" level=info msg="enabling fastly middleware"
2024-03-21 13:27:48 | hasura-storage | time="2024-03-21T12:27:48Z" level=info msg="applying hasura metadata"
2024-03-21 13:27:48 | hasura-storage | time="2024-03-21T12:27:48Z" level=info msg="applying postgres migrations"
2024-03-21 13:27:48 | hasura-storage | time="2024-03-21T12:27:48Z" level=info msg="Using static aws credentials"
2024-03-21 13:27:48 | hasura-storage | time="2024-03-21T12:27:48Z" level=info msg="storage version 0.6.0"
2024-03-21 13:27:48 | hasura-storage | problem reading : Config File "hasura-storage" Not Found in "[/]"

I didn't change anything on the storage tables, neither in config files from nhost cli init.

Using storage 0.6.0

@dbarrosop
Copy link
Contributor

Hi,
based on the logs you shared the service started correctly. The error you are pointing out in hasura is benign, it is simply hasura-storage reapplying metadata in case something deviated and getting "not needed, already correct" back.

Regards.
David

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants