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

Investigate running the back end without Redis non-production purposes #1065

Closed
fabcor-maxiv opened this issue Sep 27, 2023 · 6 comments
Closed

Comments

@fabcor-maxiv
Copy link
Contributor

Currently the Sphinx documentation (in docs) relies on the usage of autoflask directive in order to build the REST API documentation based on the Flask routes. This requires actually running the back end end server, which requires running a Redis server.

Maybe for this specific purpose -- building the documentation -- and other similar, non-production purposes such as unit testing, it would be possible to run the back end server without having a Redis server. This would simplify those processes greatly and surely improve the performance of CI/CD (less time needed to finish the pipelines/workflows).

@fabcor-maxiv
Copy link
Contributor Author

Currently the Sphinx documentation (in docs) relies on the usage of autoflask directive

As far as I can tell, his is also true for autodoc and autosummary.

@fabcor-maxiv
Copy link
Contributor Author

See also: #1262 (comment)

@axelboc
Copy link
Collaborator

axelboc commented Jul 11, 2024

Redis is tricky to install/run on Windows, and this currently prevents me from working on MXCuBE when I work from home.

@fabcor-maxiv
Copy link
Contributor Author

Redis is tricky to install/run on Windows

Even with conda, Docker or WSL?

Anyway, yes, I feel like we could make it possible to at least start MXCuBE without Redis. It seems like it would simplify a bunch of things (generating documentation is only one of them).

My impression is that we check early on if Redis is running and fail if it isn't. Maybe I am completely wrong, because I have not actually investigated this, but it feels like it fails even though in many cases Redis is not used at all and maybe we could get rid of of this check without breaking anything. It seems like there are many other dependencies that might not be available and MXCuBE still starts fine, not sure why Redis seems to be a special case here.

@axelboc
Copy link
Collaborator

axelboc commented Jul 11, 2024

Even with conda, Docker or WSL?

I tried only with conda but I should try with Docker and WSL, you're right.

@marcus-oscarsson
Copy link
Member

We used to persist the queue, session and certain settings for recovery to redis but we are no longer using this. So we can actually remove the redis dependency on mxcube-web it will however still be needed in mxcubecore. The dependency on mxubecore wont prevent the application from running but the DataPublisher, for instance` wont work so its perhaps to be avoided for tests. It should work fine for docs and demo/mockups.

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

3 participants