gradle-dependency-graph-generator-plugin icon indicating copy to clipboard operation
gradle-dependency-graph-generator-plugin copied to clipboard

Allow customization of timeouts

Open Grimoren opened this issue 3 years ago • 7 comments

Error occurring during run: Command took too long to execute, try setting a higher timout: '[/bin/sh, -c, dot -Kdot -Tsvg /tmp/GraphvizJava/DotEngine7925473131433663348/dotfile.dot -ooutfile.svg]'

The plugin should have an overridable default timeout.

Grimoren avatar Jun 15 '22 18:06 Grimoren

We might have to tell the timeout to the underlying graphviz library we're using

vanniktech avatar Jun 15 '22 18:06 vanniktech

Did you try to configure the Graphviz instance directly with a custom engine with the proper timeout?

Graphviz.useEngine(GraphvizCmdLineEngine().timeout(2, TimeUnit.MINUTES))

SimonMarquis avatar Aug 21 '22 09:08 SimonMarquis

@SimonMarquis what do you think if we provide a reasonable default lets say 30 seconds for the tasks that we create? And any one who needs more can use https://github.com/vanniktech/gradle-dependency-graph-generator-plugin/pull/183

vanniktech avatar Aug 21 '22 09:08 vanniktech

The issue with this approach is that it will force everyone to use this engine. And the Graphviz wrapper we use does rely on a default list of available engines.

https://github.com/nidi3/graphviz-java/blob/f0c1fdfa37c8b9876ef1dcccec1a6c19219e727e/graphviz-java/src/main/java/guru/nidi/graphviz/engine/Graphviz.java#L88

SimonMarquis avatar Aug 21 '22 10:08 SimonMarquis

Aaah I thought GraphvizEngine has a timeout as well :(

vanniktech avatar Aug 21 '22 12:08 vanniktech

How do I access graphViz?

Grimoren avatar Aug 30 '22 00:08 Grimoren