datalust / seq-tickets

Issues, design discussions and feature roadmap for the Seq log server
https://datalust.co/seq
97 stars 5 forks source link

Unable to save any changes to the workspace #2053

Closed MarkLFT closed 10 months ago

MarkLFT commented 10 months ago

Describe the bug I am unable to save any changes to the workspace, and trying to save signals does not work. In all cases I receive an error saying "Could not update workspace", "The workspace was edited by another user. Please undo and re-apply your changes"

But there is only one user account the admin account, and I am logged in as that account. So how could another user have changed anything?

To Reproduce

  1. Use workspace selector to Edit the person workspace.
  2. Without changing anything, click the save button.
  3. See error

or

  1. Create a new Signal
  2. Enter the filter and use the add to signal button.
  3. Save the Signal
  4. See error

Expected behavior Should be able to save changes to the workspace without any warnings.

Screenshots If applicable, add screenshots to help explain your problem.

Environment (please complete the following information):

Additional context Add any other context about the problem here.

nblumhardt commented 10 months ago

Hi Mark, thanks for reaching out.

I don't hit the error you're describing in either of those scenarios, so it might take a little digging to find what's going wrong. I'll try to repro again using Edge when I'm back in the office, but I don't think the issue is likely to be browser-specific.

It could be caused by making edits to the same workspace from multiple different browser tabs within a fairly short window - any chance that's possible, here?

And does the issue resolve if you F5 your Seq browser session and try again?

Workspaces are served as JSON documents by the Seq API, and when they're retrieved, they have a Self link embedded in them, which includes a ?version=x item in the query string.

Later, when the workspace is saved, it's POSTed to this URL, and the version compared with the current version on the server.

If there's a reverse proxy in front of Seq that does URL rewriting, or that has some form of response caching built in, this could interfere with the scheme. Any chances that could be occurring?

Best regards, Nick

MarkLFT commented 10 months ago

All the changes were made in a single browser window.

Will try to f5 the window and see what happens.

There is a reverse proxy in front of this server, but it has been there for several years, but this is the first time I have experienced this error.

I will try to f5 it, I will also try to access the server bypassing the proxy server.

MarkLFT commented 10 months ago

The issue seems to be related to the docker container being behind a Cloudflare reverse proxy. I use Cloudflare Access to route traffic from a secure url to the docker container. When I bypass the Cloudflare and go directly to the docker container, it works as expected.

nblumhardt commented 10 months ago

Good to know, thanks @MarkLFT 👍