<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Issue DELETE /search/jobs/{search_id} via Java SDK in Splunk Dev</title>
    <link>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447526#M8145</link>
    <description>&lt;P&gt;I'm trying to delete search jobs that I no longer need using the Java SDK. The reason is that, when I try to submit a new job, I'm getting the error message &lt;CODE&gt;com.splunk.HttpException: HTTP 503 -- reason="Search not executed: The maximum disk usage quota for this user has been reached. Use the Job Manager to delete some of your saved search results.", usage=210MB, quota=100MB, user=svc_splunk_mc2, concurrency_category="historical", concurrency_context="user_instance-wide&lt;/CODE&gt;.&lt;/P&gt;
&lt;P&gt;When I finish retrieving the results of my search, I do issue a &lt;CODE&gt;job.cancel()&lt;/CODE&gt; but that seems to issue a POST to &lt;CODE&gt;search/jobs/{search_id}/control&lt;/CODE&gt; with &lt;CODE&gt;action=cancel&lt;/CODE&gt;. That releases the cached search results alright but it doesn't seem to delete the search job. In other words, I'm looking for an Java SDK method that will issue a DELETE &lt;CODE&gt;search/jobs/{search_id}&lt;/CODE&gt;.&lt;/P&gt;
&lt;P&gt;I've looked in the &lt;CODE&gt;Job&lt;/CODE&gt; class but I can't seem to find a method that will issue the DELETE for the job. Am I missing something or do I just need to issue the REST call myself without the benefit of the Java SDK?&lt;/P&gt;</description>
    <pubDate>Sun, 07 Jun 2020 18:24:38 GMT</pubDate>
    <dc:creator>garypsplunk</dc:creator>
    <dc:date>2020-06-07T18:24:38Z</dc:date>
    <item>
      <title>Issue DELETE /search/jobs/{search_id} via Java SDK</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447526#M8145</link>
      <description>&lt;P&gt;I'm trying to delete search jobs that I no longer need using the Java SDK. The reason is that, when I try to submit a new job, I'm getting the error message &lt;CODE&gt;com.splunk.HttpException: HTTP 503 -- reason="Search not executed: The maximum disk usage quota for this user has been reached. Use the Job Manager to delete some of your saved search results.", usage=210MB, quota=100MB, user=svc_splunk_mc2, concurrency_category="historical", concurrency_context="user_instance-wide&lt;/CODE&gt;.&lt;/P&gt;
&lt;P&gt;When I finish retrieving the results of my search, I do issue a &lt;CODE&gt;job.cancel()&lt;/CODE&gt; but that seems to issue a POST to &lt;CODE&gt;search/jobs/{search_id}/control&lt;/CODE&gt; with &lt;CODE&gt;action=cancel&lt;/CODE&gt;. That releases the cached search results alright but it doesn't seem to delete the search job. In other words, I'm looking for an Java SDK method that will issue a DELETE &lt;CODE&gt;search/jobs/{search_id}&lt;/CODE&gt;.&lt;/P&gt;
&lt;P&gt;I've looked in the &lt;CODE&gt;Job&lt;/CODE&gt; class but I can't seem to find a method that will issue the DELETE for the job. Am I missing something or do I just need to issue the REST call myself without the benefit of the Java SDK?&lt;/P&gt;</description>
      <pubDate>Sun, 07 Jun 2020 18:24:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447526#M8145</guid>
      <dc:creator>garypsplunk</dc:creator>
      <dc:date>2020-06-07T18:24:38Z</dc:date>
    </item>
    <item>
      <title>Re: Issue DELETE /search/jobs/{search_id} via Java SDK</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447527#M8146</link>
      <description>&lt;P&gt;Did anyone find a solution to this? I am facing the same issue&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jan 2020 00:37:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447527#M8146</guid>
      <dc:creator>kenharness</dc:creator>
      <dc:date>2020-01-30T00:37:48Z</dc:date>
    </item>
    <item>
      <title>Re: Issue DELETE /search/jobs/{search_id} via Java SDK</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447528#M8147</link>
      <description>&lt;P&gt;Java has a delete method here &lt;A href="https://docs.splunk.com/DocumentationStatic/JavaSDK/1.6.4/com/splunk/HttpService.html"&gt;https://docs.splunk.com/DocumentationStatic/JavaSDK/1.6.4/com/splunk/HttpService.html&lt;/A&gt;&lt;BR /&gt;
"Issues a DELETE request against the service using a given path"&lt;/P&gt;

&lt;P&gt;I use the equivalent in Python as this &lt;BR /&gt;
sdkservice.delete("/services/search/jobs/%s" % (s.jobres.sid))&lt;/P&gt;

&lt;P&gt;Most if not all the Splunk SDKs appear to have generic "get" "post" and "delete" functions under the service object returned from a connection. Sure you could do these without the Splunk SDK, but they are helpful since they deal with auth token management and headers for you.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Mar 2020 17:16:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Issue-DELETE-search-jobs-search-id-via-Java-SDK/m-p/447528#M8147</guid>
      <dc:creator>elewis1</dc:creator>
      <dc:date>2020-03-03T17:16:48Z</dc:date>
    </item>
  </channel>
</rss>

