[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Joel Knighton updated CASSANDRA-12273: -- Status: Open (was: Patch Available) > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Murukesh Mohanan >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Joel Knighton updated CASSANDRA-12273: -- Status: Awaiting Feedback (was: Open) > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Murukesh Mohanan >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Joel Knighton updated CASSANDRA-12273: -- Assignee: Murukesh Mohanan > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Murukesh Mohanan >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Joel Knighton updated CASSANDRA-12273: -- Assignee: (was: Christopher Batey) > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Joshua McKenzie updated CASSANDRA-12273: Reviewer: Joel Knighton > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Christopher Batey >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Murukesh Mohanan updated CASSANDRA-12273: - Status: Patch Available (was: Open) > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Christopher Batey >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Murukesh Mohanan updated CASSANDRA-12273: - Attachment: 12273.patch The attached patch uses {{Files.createDirectories}} to create any missing parent directories. {{Files.createDirectories}} will just return {{false}} if the parent directory path already exists and is a directory, or {{true}} if it could create the directory, so we can safely ignore the return value and look only at the exceptions it throws. If the path was a file, it will throw an exception. Unfortunately, it will *also* throw an exception if the path was a symbolic link, so I have added a check for that. Result when running {{tools/bin/cassandra-stress write n=1900 -graph file=bar/foo.html -port native=9142 > /dev/null; find bar -ls}}: h4. Before Case: {{bar/}} exists {code} 17013858 lrwxr-xr-x1 user group3 Oct 18 19:39 bar -> foo {code} Case: {{bar/}} doesn't exist {code} java.lang.RuntimeException: Couldn't write stats html. at org.apache.cassandra.stress.StressGraph.generateGraph(StressGraph.java:95) at org.apache.cassandra.stress.Stress.run(Stress.java:146) at org.apache.cassandra.stress.Stress.main(Stress.java:62) find: {{bar/}}: No such file or directory {code} Case: {{bar/}} is a file {code} java.lang.RuntimeException: Couldn't write stats html. at org.apache.cassandra.stress.StressGraph.generateGraph(StressGraph.java:95) at org.apache.cassandra.stress.Stress.run(Stress.java:146) at org.apache.cassandra.stress.Stress.main(Stress.java:62) 17014670 -rw-r--r--1 user group0 Oct 18 19:41 bar {code} Case: {{bar/}} is a link to non-existing file {code} java.lang.RuntimeException: Couldn't write stats html. at org.apache.cassandra.stress.StressGraph.generateGraph(StressGraph.java:95) at org.apache.cassandra.stress.Stress.run(Stress.java:146) at org.apache.cassandra.stress.Stress.main(Stress.java:62) 17014728 lrwxr-xr-x1 user group8 Oct 18 19:41 bar -> /nothing {code} Case: {{bar/}} is a link to an existing directory {code} 17014778 lrwxr-xr-x1 user group3 Oct 18 19:41 bar -> foo 17014760 drwxr-xr-x3 user group 102 Oct 18 19:41 bar 1701484 520 -rw-r--r--1 user group 265292 Oct 18 19:41 bar/foo.html {code} h4. After Case: {{bar/}} exists {code} 17010940 drwxr-xr-x3 user group 102 Oct 18 19:30 bar 1701099 520 -rw-r--r--1 user group 265295 Oct 18 19:30 bar/foo.html {code} Case: {{bar/}} doesn't exist {code} 17010940 drwxr-xr-x3 user group 102 Oct 18 19:30 bar 1701095 520 -rw-r--r--1 user group 265381 Oct 18 19:30 bar/foo.html {code} Case: {{bar/}} is a file {code} java.lang.RuntimeException: Parent directory of stats html is a file. at org.apache.cassandra.stress.StressGraph.generateGraph(StressGraph.java:104) at org.apache.cassandra.stress.Stress.run(Stress.java:146) at org.apache.cassandra.stress.Stress.main(Stress.java:62) 17011000 -rw-r--r--1 user group0 Oct 18 19:30 bar {code} Case: {{bar/}} is a link to non-existing file {code} java.lang.RuntimeException: Couldn't write stats html. at org.apache.cassandra.stress.StressGraph.generateGraph(StressGraph.java:108) at org.apache.cassandra.stress.Stress.run(Stress.java:146) at org.apache.cassandra.stress.Stress.main(Stress.java:62) 17011078 lrwxr-xr-x1 user group8 Oct 18 19:30 bar -> /nothing {code} Case: {{bar/}} is a link to an existing directory {code} 17011128 lrwxr-xr-x1 user group3 Oct 18 19:30 bar -> foo 1700 drwxr-xr-x3 user group 102 Oct 18 19:31 bar 1701116 520 -rw-r--r--1 user group 265301 Oct 18 19:31 bar/foo.html {code} > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Christopher Batey >Priority: Minor > Labels: lhf > Attachments: 12273.patch > > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CASSANDRA-12273) Casandra stess graph: option to create directory for graph if it doesn't exist
[ https://issues.apache.org/jira/browse/CASSANDRA-12273?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sylvain Lebresne updated CASSANDRA-12273: - Labels: lhf (was: ) > Casandra stess graph: option to create directory for graph if it doesn't exist > -- > > Key: CASSANDRA-12273 > URL: https://issues.apache.org/jira/browse/CASSANDRA-12273 > Project: Cassandra > Issue Type: Improvement > Components: Tools >Reporter: Christopher Batey >Assignee: Christopher Batey >Priority: Minor > Labels: lhf > > I am running it in CI with ephemeral workspace / build dirs. It would be > nice if CS would create the directory so my build tool doesn't have to -- This message was sent by Atlassian JIRA (v6.3.4#6332)