Community
All Communities
Products
ArcGIS Pro
ArcGIS Survey123
ArcGIS Online
ArcGIS Enterprise
Data Management
Geoprocessing
ArcGIS Experience Builder
ArcGIS Web AppBuilder
ArcGIS Dashboards
ArcGIS Field Maps
ArcGIS Spatial Analyst
All Products Communities
Industries
Education
Water Resources
State & Local Government
Transportation
Gas and Pipeline
Water Utilities
Roads and Highways
Telecommunications
Natural Resources
Electric
Public Safety
All Industries Communities
Developers
Python
JavaScript Maps SDK
Native Maps SDKs
ArcGIS API for Python
ArcGIS Pro SDK
ArcObjects SDK
Developers - General
ArcGIS REST APIs and Services
ArcGIS Online Developers
Game Engine Maps SDKs
File Geodatabase API
All Developers Communities
Global
Comunidad Esri Colombia - Ecuador - Panamá
ArcGIS 開発者コミュニティ
Czech GIS
ArcNesia
Esri India
GeoDev Germany
ArcGIS Content - Esri Nederland
Comunidad GEOTEC
Esri Italia Community
Europe
Asia Pacific
All Global Communities
All Communities
Developers
User Groups
Industries
Services
Community Resources
Global
Events
Learning
Networks
ArcGIS Topics
Products
View All Communities
ArcGIS Ideas
GIS Life
Community Resources
Community Help Documents
Community Blog
Community Feedback
Member Introductions
Community Ideas
All Community Resources
Sign In
cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Show
only
|
Search instead for
Did you mean:
Cancel
Home
:
All Communities
:
Developers
:
ArcGIS REST APIs and Services
:
ArcGIS REST APIs & Services Ques.
:
is it possible to clear the rest cache programmati...
Options
Subscribe to RSS Feed
Mark Topic as New
Mark Topic as Read
Float this Topic for Current User
Bookmark
Subscribe
Mute
Printer Friendly Page
Select to view content in your preferred language
Translate Now
is it possible to clear the rest cache programmatically in 9.3.1?
Subscribe
1161
3
07-19-2011 06:12 AM
by
PrashantKhanal
Emerging Contributor
07-19-2011
06:12 AM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Report Inappropriate Content
The arcgis server 10 has an option where you can generate the admin cache token and use the token to clear the rest cache.
Is there any way we can clear the rest cache programmatically in 9.3.1?
Tags
(3)
Tags:
_rest
developers
rest_api
Reply
0
Kudos
All Posts
Previous Topic
Next Topic
3 Replies
by
Ranga_Tolapi
Frequent Contributor
08-04-2011
08:01 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Report Inappropriate Content
http://forums.arcgis.com/threads/6654-Question-about-clearing-the-cache
Reply
0
Kudos
by
Ranga_Tolapi
Frequent Contributor
08-15-2011
10:42 PM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Report Inappropriate Content
This java code works...
import org.apache.http.client.methods.HttpGet;
import org.apache.http.impl.client.DefaultHttpClient;
private static void clearRestCache(String server, String username, String password) {
DefaultHttpClient httpclient = new DefaultHttpClient();
try {
String loginUrl = "
http://
" + server + ":8399/arcgis/rest/admin/login";
String cacheClearUrl = "
http://
" + server + ":8399/arcgis/rest/admin/cache/clear";
HttpGet httpget = new HttpGet(loginUrl + "?username=" + username + "&password=" + password + "&redirect=" + cacheClearUrl);
httpclient.execute(httpget);
} catch (Exception e) {
e.printStackTrace();
} finally {
httpclient.getConnectionManager().shutdown();
}
}
Reply
0
Kudos
by
RussellChiles
Deactivated User
09-25-2013
06:39 AM
Mark as New
Bookmark
Subscribe
Mute
Subscribe to RSS Feed
Permalink
Print
Report Inappropriate Content
Where would you run this script?
Reply
0
Kudos
Post Reply