Blef-team / blef_game_engine

The game engine API service for the game of Blef
GNU Affero General Public License v3.0
1 stars 0 forks source link

Fix 500 status codes in deployment #78

Closed adrian-golian closed 4 years ago

adrian-golian commented 4 years ago

The current state the service, up-to-date with develop, tested on EC2, seems to have issues writing/reading data on the machine. This could be to do with the move of game_data to ~.

This is the observed behaviour:

$ curl $GAMEENGINEAPIURL/games/baf1fd82-5beb-45a1-8165-54b78853a6df
{"error":"Game does not exist"}
$ curl $GAMEENGINEAPIURL/games/create
{"error":"500 - Internal server error"}
$ curl $GAMEENGINEAPIURL/games
{"error":"500 - Internal server error"}
maciej-pomykala commented 4 years ago

For now i can confirm that this is happening and that it gets fixed by killing the R process initiated by automatic deployment and executing run_api.R manually.

maciej-pomykala commented 4 years ago

I think the R console output can be written to a file, but I think that trying this out to see what's happening inside the R process would involve pushing test code to master...

adrian-golian commented 4 years ago

Yeah, we should be capturing the logs either way. I’ll do that and redeploy manually.

adrian-golian commented 4 years ago

Ok.

  1. Redeploying develop seems to have fixed this issue. We should figure out what could've been going on though, if possible.
  2. Logging's added as part of a new issue (#79)

We should close this.

maciej-pomykala commented 4 years ago

Ok, I'm fine with closing