You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/10/01 05:52:06 UTC
[GitHub] [arrow-ballista] onthebridgetonowhere opened a new pull request, #301: Add support for viewing the graph in the browser. It does not work at…
onthebridgetonowhere opened a new pull request, #301:
URL: https://github.com/apache/arrow-ballista/pull/301
Add support for viewing the graph in the browser. It does not work at the moment, as calling the d3.graphviz function fails due to the selector not being able to fetch the right node. Need some suggestions on what needs to be done here.
# Which issue does this PR close?
Closes #275 .
# Rationale for this change
Explained in the issue linked above.
# What changes are included in this PR?
Adds the possibility of viewing the diagram generated from the DOT file
# Are there any user-facing changes?
Yes, another button is added in the UI's scheduler table.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-ballista] andygrove merged pull request #301: [UI] Add ability to view query plans directly in the UI
Posted by GitBox <gi...@apache.org>.
andygrove merged PR #301:
URL: https://github.com/apache/arrow-ballista/pull/301
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-ballista] andygrove commented on pull request #301: Add support for viewing the graph in the browser. It does not work at…
Posted by GitBox <gi...@apache.org>.
andygrove commented on PR #301:
URL: https://github.com/apache/arrow-ballista/pull/301#issuecomment-1264481641
I tried this:
```
var graphDiv = useRef<HTMLDivElement | null>(null);
useEffect(() => {
if (isOpen) {
dot();
if (graphDiv.current != null) {
d3.graphviz(graphDiv.current).renderDot(dot_data);
}
}
}, [graphDiv.current]);
return (
<>
<Button onClick={onOpen}>View Graph</Button>
<Modal isOpen={isOpen} onClose={onClose}>
<ModalOverlay />
<ModalContent>
<ModalHeader>Graph for {props.value} job</ModalHeader>
<ModalCloseButton />
<ModalBody>
<div ref={node => graphDiv.current = node}></div>
</ModalBody>
<ModalFooter>
<Button colorScheme="blue" mr={3} onClick={onClose}>
Close
</Button>
</ModalFooter>
</ModalContent>
</Modal>
</>
);
```
This seemed to get farther but then failed with a wasm validation error - failed to match magic number.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-ballista] andygrove commented on pull request #301: Add support for viewing the graph in the browser. It does not work at…
Posted by GitBox <gi...@apache.org>.
andygrove commented on PR #301:
URL: https://github.com/apache/arrow-ballista/pull/301#issuecomment-1264383418
Thanks @onthebridgetonowhere! I will take a look this weekend and see if I can help.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-ballista] onthebridgetonowhere commented on pull request #301: Add support for viewing the graph in the browser. It does not work at…
Posted by GitBox <gi...@apache.org>.
onthebridgetonowhere commented on PR #301:
URL: https://github.com/apache/arrow-ballista/pull/301#issuecomment-1264555794
I made it work! :fireworks: I found the `wasm` error to be hard to grasp and hard to find understandable solutions. I went a different route by having a new backend API and rendering the SVG by reusing a React component.
There are a few tradeoffs though, which we need to consider:
- a new API that creates an SVG from the DOT string
- the new API requires a new crate, the `graphviz-rust` crate
- a new React dependency that allows us to easily render the SVG (`react-inlinesvg`)
- the backend does the conversion; I do not know of the performance of the `graphviz-rust` crate. I suggest we experiment with it, and optimize later if needed.
@andygrove let me know what you think, and thanks for your previous help.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-ballista] andygrove commented on pull request #301: Add support for viewing the graph in the browser. It does not work at…
Posted by GitBox <gi...@apache.org>.
andygrove commented on PR #301:
URL: https://github.com/apache/arrow-ballista/pull/301#issuecomment-1264459993
@onthebridgetonowhere Maybe this helps?
https://www.anycodings.com/1questions/3439897/getting-error-thisnode-is-null-using-react
I will try this out too later today
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org