mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
Change post to put
This commit is contained in:
parent
7eb352159a
commit
f349dbf240
3 changed files with 7 additions and 7 deletions
|
|
@ -979,7 +979,7 @@ If you work with Apache Zeppelin and find a need for an additional REST API, ple
|
|||
<col width="200">
|
||||
<tr>
|
||||
<td>Description</td>
|
||||
<td>This ```POST``` method clear all paragraph results from note of given id.
|
||||
<td>This ```PUT``` method clear all paragraph results from note of given id.
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
|
@ -999,4 +999,4 @@ If you work with Apache Zeppelin and find a need for an additional REST API, ple
|
|||
<td><pre>{"status": "OK"}</pre></td>
|
||||
</tr>
|
||||
</tr>
|
||||
</table>
|
||||
</table>
|
||||
|
|
|
|||
|
|
@ -467,7 +467,7 @@ public class NotebookRestApi {
|
|||
* @param noteId ID of Note
|
||||
* @return JSON with status.ok
|
||||
*/
|
||||
@POST
|
||||
@PUT
|
||||
@Path("{noteId}/clear")
|
||||
@ZeppelinApi
|
||||
public Response clearAllParagraphOutput(@PathParam("noteId") String noteId)
|
||||
|
|
|
|||
|
|
@ -191,10 +191,10 @@ public class NotebookRestApiTest extends AbstractTestRestApi {
|
|||
p2.setReturn(result, new Throwable());
|
||||
|
||||
// clear paragraph result
|
||||
PostMethod post = httpPost("/notebook/" + note.getId() + "/clear", "");
|
||||
LOG.info("test clear paragraph output response\n" + post.getResponseBodyAsString());
|
||||
assertThat(post, isAllowed());
|
||||
post.releaseConnection();
|
||||
PutMethod put = httpPut("/notebook/" + note.getId() + "/clear", "");
|
||||
LOG.info("test clear paragraph output response\n" + put.getResponseBodyAsString());
|
||||
assertThat(put, isAllowed());
|
||||
put.releaseConnection();
|
||||
|
||||
// check if paragraph results are cleared
|
||||
GetMethod get = httpGet("/notebook/" + note.getId() + "/paragraph/" + p1.getId());
|
||||
|
|
|
|||
Loading…
Reference in a new issue