Event log, Exporting a configuration, Importing a configuration – Google Search Appliance Administrative API Developers Guide: Java User Manual
Page 52
Google Search Appliance: Administrative API Developer’s Guide: Java
52
Exporting a Configuration
Export a search appliance configuration by sending an authenticated GET request to the importExport
entry of the config feed.
The following importExport entry is returned:
Map
queries.put("password","12345678");
GsaEntry entry = myClient.queryEntry("config", "importExport", queries);
System.out.println("XML Data: " + entry.getGsaContent("xmlData"));
Importing a Configuration
Import a search appliance configuration sending an authenticated PUT request to the importExport
entry of the config feed.
GsaEntry updateEntry = new GsaEntry();
updateEntry.addGsaContent("xmlData", "
updateEntry.addGsaContent("password", "12345678");
myClient.updateEntry("config", "importExport", updateEntry);
Event Log
Retrieve lines from the event log for a search appliance by using the eventLog entry of the logs feed.
The following parameters let you make a query, specify a starting line, and specify the number of event
log statements to retrieve.
Use the following properties to retrieve event log lines and event log content.
Parameter
Description
query
Query string for the logContent. The logContent contains many lines of logs.
The query string applies to each line, only lines that contain the query string are
returned.
startLine
The starting line number to retrieve from the event log. The default value is 1.
maxLines
The maximum number of lines in the event log to retrieve. The default value is
50 lines.
Property
Description
fromLine
The starting line of a log.
logContent
The log’s content.
toLine
The ending line of a log.
totalLines
Total lines of the log.