invalidateCache
Address HA requirements with cache synchronization.
/api/v1/schemaregistry/cache/{cacheType}/invalidate
Usage and SDK Samples
curl -X POST\
-H "Content-Type: */*"\
"//api/v1/schemaregistry/cache/{cacheType}/invalidate"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.Apiv1schemaregistryApi;
import java.io.File;
import java.util.*;
public class Apiv1schemaregistryApiExample {
public static void main(String[] args) {
Apiv1schemaregistryApi apiInstance = new Apiv1schemaregistryApi();
String cacheType = cacheType_example; // String | Cache Id to be invalidated
String body = ; // String | key
try {
apiInstance.invalidateCache(cacheType, body);
} catch (ApiException e) {
System.err.println("Exception when calling Apiv1schemaregistryApi#invalidateCache");
e.printStackTrace();
}
}
}
import io.swagger.client.api.Apiv1schemaregistryApi;
public class Apiv1schemaregistryApiExample {
public static void main(String[] args) {
Apiv1schemaregistryApi apiInstance = new Apiv1schemaregistryApi();
String cacheType = cacheType_example; // String | Cache Id to be invalidated
String body = ; // String | key
try {
apiInstance.invalidateCache(cacheType, body);
} catch (ApiException e) {
System.err.println("Exception when calling Apiv1schemaregistryApi#invalidateCache");
e.printStackTrace();
}
}
}
String *cacheType = cacheType_example; // Cache Id to be invalidated
String *body = ; // key (optional)
Apiv1schemaregistryApi *apiInstance = [[Apiv1schemaregistryApi alloc] init];
// Address HA requirements with cache synchronization.
[apiInstance invalidateCacheWith:cacheType
body:body
completionHandler: ^(NSError* error) {
if (error) {
NSLog(@"Error: %@", error);
}
}];
var SwaggerJsClient = require('swagger-js-client');
var api = new SwaggerJsClient.Apiv1schemaregistryApi()
var cacheType = cacheType_example; // {{String}} Cache Id to be invalidated
var opts = {
'body': // {{String}} key
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully.');
}
};
api.invalidateCache(cacheType, opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class invalidateCacheExample
{
public void main()
{
var apiInstance = new Apiv1schemaregistryApi();
var cacheType = cacheType_example; // String | Cache Id to be invalidated
var body = new String(); // String | key (optional)
try
{
// Address HA requirements with cache synchronization.
apiInstance.invalidateCache(cacheType, body);
}
catch (Exception e)
{
Debug.Print("Exception when calling Apiv1schemaregistryApi.invalidateCache: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\ApiApiv1schemaregistryApi();
$cacheType = cacheType_example; // String | Cache Id to be invalidated
$body = ; // String | key
try {
$api_instance->invalidateCache($cacheType, $body);
} catch (Exception $e) {
echo 'Exception when calling Apiv1schemaregistryApi->invalidateCache: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::Apiv1schemaregistryApi;
my $api_instance = WWW::SwaggerClient::Apiv1schemaregistryApi->new();
my $cacheType = cacheType_example; # String | Cache Id to be invalidated
my $body = WWW::SwaggerClient::Object::String->new(); # String | key
eval {
$api_instance->invalidateCache(cacheType => $cacheType, body => $body);
};
if ($@) {
warn "Exception when calling Apiv1schemaregistryApi->invalidateCache: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = swagger_client.Apiv1schemaregistryApi()
cacheType = cacheType_example # String | Cache Id to be invalidated
body = # String | key (optional)
try:
# Address HA requirements with cache synchronization.
api_instance.invalidate_cache(cacheType, body=body)
except ApiException as e:
print("Exception when calling Apiv1schemaregistryApi->invalidateCache: %s\n" % e)
Parameters
Name | Description |
---|---|
cacheType* |
String
Cache Id to be invalidated
Required
|
Name | Description |
---|---|
body |