updateApplication method
Updates the mutable configuration settings for a Amazon GameLift Streams
application resource. You can change the Description,
ApplicationLogOutputUri, and
ApplicationLogPaths.
To update application settings, specify the application ID and provide the new values. If the operation is successful, it returns the complete updated set of settings for the application.
May throw AccessDeniedException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter identifier :
An Amazon
Resource Name (ARN) or ID that uniquely identifies the application
resource. Example ARN:
arn:aws:gameliftstreams:us-west-2:111122223333:application/a-9ZY8X7Wv6.
Example ID: a-9ZY8X7Wv6.
Parameter applicationLogOutputUri :
An Amazon S3 URI to a bucket where you would like Amazon GameLift Streams
to save application logs. Required if you specify one or more
ApplicationLogPaths.
Parameter applicationLogPaths :
Locations of log files that your content generates during a stream
session. Enter path values that are relative to the
ApplicationSourceUri location, or relative to the user's home
directory when using a supported path variable. You can specify up to 10
log paths. Each individual log file cannot exceed 50 MB in size.
Each path can be a directory or an exact file path. When you specify a
directory, Amazon GameLift Streams collects only files with the following
extensions: .txt, .log, and
.utrace. To collect files with other extensions, specify the
exact file path. The copy operation is not performed recursively in
subfolders.
The following path variables are recognized when they appear as the first
component of a path: %USERPROFILE% (Windows and Proton),
$HOME or ~ (Linux). Use a path variable when
your application writes logs outside of the application directory.
Amazon GameLift Streams uploads designated log files to the Amazon S3
bucket that you specify in ApplicationLogOutputUri at the end
of a stream session. To retrieve stored log files, call GetStreamSession
and get the LogFileLocationUri.
Parameter description :
A human-readable label for the application.
Implementation
Future<UpdateApplicationOutput> updateApplication({
required String identifier,
String? applicationLogOutputUri,
List<String>? applicationLogPaths,
String? description,
}) async {
final $payload = <String, dynamic>{
if (applicationLogOutputUri != null)
'ApplicationLogOutputUri': applicationLogOutputUri,
if (applicationLogPaths != null)
'ApplicationLogPaths': applicationLogPaths,
if (description != null) 'Description': description,
};
final response = await _protocol.send(
payload: $payload,
method: 'PATCH',
requestUri: '/applications/${Uri.encodeComponent(identifier)}',
exceptionFnMap: _exceptionFns,
);
return UpdateApplicationOutput.fromJson(response);
}