How do I view logs from before the most recent deployment? (pro plan)
ronit-tiwary
PROOP

a year ago

Besides my last deployment (which says active), all my other deployments are greyed out and say skipped. That's fine, but I'm only able to view logs for my active deployment, and all other past deployments show "No deployment logs. All output sent to stdout will be displayed here".

I'm on a pro plan and so I believe my logs should be stored for up to 30 days.

19 Replies

ronit-tiwary
PROOP

a year ago

project id: 6f77d8dd-a5b1-444e-a5a1-0194447af261


a year ago

can you link to a specific service?



ronit-tiwary
PROOP

a year ago

does that link work for you?


a year ago

yes, can you also provide a link to a deployement that shows no logs



a year ago

they are all skipped, can you explain why you would expect to see deployment logs for them?


ronit-tiwary
PROOP

a year ago

ah that is me being stupid- the removed and skipped tag looked the same to me


ronit-tiwary
PROOP

a year ago

I do see some logs that appear to be missing though from this deployment: https://railway.app/project/6f77d8dd-a5b1-444e-a5a1-0194447af261/service/d4328b3f-da6f-49c0-a642-1b8311c52077?id=ef588e61-341c-4f04-810e-31741c72c6d5

I see logs from one user's session but not another. Is there that might go wrong with concurrent requests being logged with railway? I'm a bit confused because I see records of user #2's session in our database which means the logs should have been written. <:thinkies:1238577143466692739>


ronit-tiwary
PROOP

a year ago

I do see some logs from user #2 session but it appears like a bunch of earlier ones are missing

1315011158612246500


a year ago

how are you logging? are you using some kind of logging library?


ronit-tiwary
PROOP

a year ago

yeah, winston


a year ago

are you making sure to disable log buffering


ronit-tiwary
PROOP

a year ago

I don't have it enabled and I think it's disabled by default. This is our setup:

const logger = winston.createLogger({
  level: 'info',
  format: winston.format.combine(
    winston.format.timestamp(),
    winston.format.json()
  ),
  defaultMeta: { service: 'audio-response-service' },
  transports: [
    new winston.transports.Console(),
  ],
});

a year ago

you'd want to explicitly disable it


ronit-tiwary
PROOP

a year ago

do you have an example of configuration of that? I remember seeing winston was your recommended one but your docs page seems to be down for me: https://docs.railway.com/guides/logs


a year ago

it wouldn't be railway specific configuration, you'd want to reference Winston's docs


ronit-tiwary
PROOP

a year ago

right, I just thought that there might be something in your docs since it was recommended. I've been looking for a while and I don't see anything about buffering or how to disable it, so I assume it doesn't exist by default. Any other recommendations?


a year ago

if buffering is off and those logs aren't there, your application never logged them


Loading...