Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update Samples folder with changed REST port #336

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Samples/CSharp/SwisClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ private async Task<JToken> SwisCallAsync(Func<HttpClient, Task<HttpResponseMessa

using (var client = new HttpClient(handler))
{
client.BaseAddress = new Uri(string.Format("https://{0}:17778/SolarWinds/InformationService/v3/Json/", _hostname));
client.BaseAddress = new Uri(string.Format("https://{0}:17774/SolarWinds/InformationService/v3/Json/", _hostname));
HttpResponseMessage response = await doRequest(client);
var result = JToken.Load(new JsonTextReader(new StreamReader(await response.Content.ReadAsStreamAsync())));
if (!response.IsSuccessStatusCode)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ public boolean verify(String s, SSLSession sslSession) {
Client client = Client.create(clientConfig);
client.addFilter(new HTTPBasicAuthFilter(username, password));

String url = "https://" + hostname + ":17778/SolarWinds/InformationService/v3/Json/" + relativeUrl;
String url = "https://" + hostname + ":17774/SolarWinds/InformationService/v3/Json/" + relativeUrl;
WebResource webResource = client.resource(url);
return webResource;
}
Expand Down
2 changes: 1 addition & 1 deletion Samples/Perl/query.pl
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
$client->getUseragent()->ssl_opts(SSL_verify_mode => 'SSL_VERIFY_NONE');

# add authentication header
$client->setHost('https://' . $hostname . ':17778');
$client->setHost('https://' . $hostname . ':17774');
$client->addHeader('Authorization', 'Basic ' . encode_base64("$username:$password", ''));

# build query string
Expand Down