Capture Interface type, motherboard model#110
Capture Interface type, motherboard model#110Avinash1423 wants to merge 2 commits intoJDiskMark:devfrom
Conversation
|
@jamesmarkchan pls take a look at the PR. |
src/jdiskmark/Util.java
Outdated
|
|
||
| line=line.trim(); | ||
|
|
||
| if(line.isEmpty()) { continue;} |
There was a problem hiding this comment.
very minor but if you could add spaces around the keywords like if to avoid others formatting your code and you don't loose the line authorship. same with the = assignment operator and before the {. :)
src/jdiskmark/Util.java
Outdated
|
|
||
| try { | ||
| if (App.os.startsWith("Windows")) { | ||
| process = new ProcessBuilder("wmic", "diskdrive", "get", "InterfaceType").start(); |
src/jdiskmark/Util.java
Outdated
|
|
||
| if(line.isEmpty()) { continue;} | ||
|
|
||
| if(line.equalsIgnoreCase("InterfaceType") || line.equalsIgnoreCase("TRAN")|| line.equalsIgnoreCase("NAME")) { continue;} |
There was a problem hiding this comment.
What I've found helpful for code reviews and future maintenance is to show the normal output of the command being used in the java docs or comments. I'm definitely interested in collecting more information on the drives interface so happy to see you are looking at this. worth looking at disk-model.ps1 to see how the drive and target attribute column can be queried in order to create the mapping. might be able to do it with command line also. @jslcom might have thoughts on the linux solutions.
|
|
||
| try { | ||
| if (App.os.startsWith("Windows")) { | ||
| process = new ProcessBuilder("wmic", "baseboard", "get", "Product").start(); |
| } else if (App.os.contains("Linux")) { | ||
| process = new ProcessBuilder("cat", "/sys/devices/virtual/dmi/id/board_name").start(); | ||
| } else if (App.os.startsWith("Mac OS")) { | ||
| process = new ProcessBuilder("system_profiler", "SPHardwareDataType").start(); |
src/jdiskmark/Util.java
Outdated
| } else if (App.os.contains("Linux")) { | ||
| process = new ProcessBuilder("lsblk", "-d", "-o", "tran").start(); | ||
| } else if (App.os.startsWith("Mac OS")) { | ||
| process = new ProcessBuilder("diskutil", "info", "disk0").start(); |
|
@Avinash1423 i'm not sure if the title and graph title are getting too cluttered but nice to explore making this info easily read. For certain we want this information stored as part of the benchmark and accessible to us and the user.
my thoughts to make look more consistent are:
|
Signed-off-by: Avinash Niyas <avinashNiyaz1423@gmail.com>
Signed-off-by: Avinash Niyas <avinashNiyaz1423@gmail.com>
88d6f95 to
d9dc368
Compare
|
@jamesmarkchan i made some changes, please take a look. |
|
@Avinash1423 definitely interesting to see how this looks, ty for preparing it, it is possible that it is a little cluttered at the top so we'll have to think about it. we still have some time before the target 1.0.0 release.
The above screenshot is on my old and aging intel NUC running Fedora. i'm working on a refactor of the data model where it will become pretty clear where this information can be captured so it is sent back to our community portal. i'll ping you once i get that working in case you would like to pull updates and incorporate that into this branch. after the information is collected at our community portal the web page is much more spacious for laying out more information and @JasmineRRod can think about where this information can be displayed. |
|
@Avinash1423 if you pull from 84dcfae#diff-34af0e420f17e3cfbdcaa620020617221c57b66aef920f5f34028cfe2763d285 |
|
windows on launch
if we resize the chart it wraps like this:
after a benchmark we loose the interface
@Avinash1423 i think we should detect when OS is not supported and not append the extra separater and interface and when a benchmark is done it would be good to update the method that is used to generate the label ideally in just a single function. not sure if we're manually building it twice. looks good on windows though. |
|
@jamesmarkchan |
|
@Avinash1423 sounds good! to get that into the future portal upload will want to add fields to the |









#87
Added a method getMotherBoardName and getInterfaceType methods in Util.java .
These methods are sensitive to platform.
Mother Board Name is displayed along w cpu info in title area
Interface Type is diplayed along with disk info