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

Auto-start UML server in a docker container (I'll be willing to make a PR on this feature) #65

Open
stroiman opened this issue Jun 28, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@stroiman
Copy link

stroiman commented Jun 28, 2024

First of all, if you think the suggestion is a good idea, I'd be willing to see if I could make a PR with the contribution.

Is your feature request related to a problem? Please describe.

Not to much a problem, but it would simplify my workflow slightly.

When using this plugin, I use docker to easily start a local server, like this:

docker run -d -p 8081:8080 plantuml/plantuml-server:jetty

And configure plugin server URL to http://localhost:8081. (I use 8081 as I have other stuff running on 8080)

This makes it extremely easy to have a local server and gives me the benefit of running a server but I get faster responses due to lower network latency, and not having to share the server with thousands of other users. And I don't have to worry about java versions, jetty/tomcat/other HTTP servers, etc. One command line, and I have a running server.

It could be helpful, if the plugin could just start the server, and stop it again, when no longer needed.

This should work on all desktop platforms, i.e. Windows, MacOS, and Linux. However, I doubt it would work on mobile devices.

Describe the solution you'd like

  • Add an option to "auto start" plantuml from from a docker container which would manage the server URL.
    • Keep the server URL as a fallback option, if docker isn't available.
      • That way, you can enable it for a vault, but it will only be used on platforms that support it, i.e. has docker is installed and running.
    • We can let docker automatically pick an available port, allowing the user to not having to specify that themselves.
  • Automatically start the docker container on a reasonable event (probably user configurable)
    • Plugin load, makes the server available quicker, but consumes resources on the user's computer
    • When first showing a UML diagram. Makes the first UML diagram show slower, but avoids.
  • Detect if a server is already running, e.g. because of an unclean exit.
  • Stop (and remove) the container (if started) on plugin unload event.

Describe alternatives you've considered

I'll just continue what I do now, start the container manually.

@stroiman stroiman added the enhancement New feature or request label Jun 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant