Describe the bug
PlantUML server running in a Docker container is unable to generate a PDF file from a Gantt chart.
To Reproduce
Steps to reproduce the behavior:
Paste the following code:
@startgantt
Project starts the 1st of may 2023
[G1] happens at 2023-05-31
[G2] happens at 2023-12-20
@endgantt
The diagram will be generated.
Now click on PDF, the following error appears
Sorry, but things didn't work out as planned.
Mon Dec 11 19:39:51 UTC 2023
Request that failed: /pdf/SoWkIImgIK_CAodXuWeeoizAJIvH08iLAvHaf2eO5fSevASfv2PMAXWP61bpSKMx6yOgP2GM5AJc5Iiabe15TGrCTOqDWL96c5A6Hhf61bnS3gbvAM1R0000
Status code: 500
Exception: java.lang.UnsupportedOperationException: PDF
Expected behavior
A PDF is generated.
Desktop (please complete the following information):
OS: Windows 10
Browser Firefox
PlantUML version 1.2023.12 (Fri Oct 20 13:49:54 UTC 2023)
Additional context
Stack trace from logs:
2023-12-11 19:39:51.179:WARN :oejs.HttpChannel:qtp1576861390-14: /pdf/SoWkIImgIK_CAodXuWeeoizAJIvH08iLAvHaf2eO5fSevASfv2PMAXWP61bpSKMx6yOgP2GM5AJc5Iiabe15TGrCTOqDWL96c5A6Hhf61bnS3gbvAM1R0000
java.lang.UnsupportedOperationException: PDF
at net.atmp.ImageBuilder.createUGraphic(ImageBuilder.java:469)
at net.atmp.ImageBuilder.writeImageInternal(ImageBuilder.java:296)
at net.atmp.ImageBuilder.write(ImageBuilder.java:256)
at net.sourceforge.plantuml.project.GanttDiagram.exportDiagramNow(GanttDiagram.java:177)
at net.sourceforge.plantuml.AbstractPSystem.exportDiagram(AbstractPSystem.java:207)
at net.sourceforge.plantuml.servlet.DiagramResponse.sendDiagram(DiagramResponse.java:204)
at net.sourceforge.plantuml.servlet.UmlDiagramService.doDiagramResponse(UmlDiagramService.java:100)
at net.sourceforge.plantuml.servlet.UmlDiagramService.doGet(UmlDiagramService.java:62)
at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:500)
at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:587)
at org.eclipse.jetty.servlet.ServletHolder$NotAsync.service(ServletHolder.java:1410)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:764)
at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1665)
at org.eclipse.jetty.websocket.servlet.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:170)
at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:202)
at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1635)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:527)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:131)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:578)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:223)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1570)
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:221)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1381)
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:176)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:484)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1543)
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:174)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1303)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:129)
at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149)
at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:51)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)
at org.eclipse.jetty.server.Server.handle(Server.java:563)
at org.eclipse.jetty.server.HttpChannel.lambda$handle$0(HttpChannel.java:505)
at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:762)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:497)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:282)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:314)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:100)
at org.eclipse.jetty.io.SelectableChannelEndPoint$1.run(SelectableChannelEndPoint.java:53)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:969)
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.doRunJob(QueuedThreadPool.java:1194)
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1149)
at java.base/java.lang.Thread.run(Unknown Source)
if I manually replace /uml with /pdf, the online server redirects me to the "home" Bob -> Alice : hello diagram, probably because it hits the same exception as you report above
Describe the bug PlantUML server running in a Docker container is unable to generate a PDF file from a Gantt chart.
To Reproduce Steps to reproduce the behavior:
Paste the following code:
The diagram will be generated. Now click on PDF, the following error appears
Expected behavior A PDF is generated.
Desktop (please complete the following information):
Additional context Stack trace from logs: