public override async Task <SystemInfo> GetSystemInfoAsync(CancellationToken cancellationToken)
        {
            using (HttpClient httpClient = HttpClientHelper.GetHttpClient(this.ManagementUri))
            {
                var edgeletHttpClient = new EdgeletHttpClient(httpClient)
                {
                    BaseUrl = HttpClientHelper.GetBaseUrl(this.ManagementUri)
                };
                GeneratedCode.SystemInfo systemInfo = await this.Execute(
                    () => edgeletHttpClient.GetSystemInfoAsync(this.Version.Name, cancellationToken),
                    "Getting System Info");

                return(new SystemInfo(systemInfo.OsType, systemInfo.Architecture, systemInfo.Version));
            }
        }
        public override async Task <SystemInfo> GetSystemInfoAsync(CancellationToken cancellationToken)
        {
            using (HttpClient httpClient = HttpClientHelper.GetHttpClient(this.ManagementUri))
            {
                var edgeletHttpClient = new EdgeletHttpClient(httpClient)
                {
                    BaseUrl = HttpClientHelper.GetBaseUrl(this.ManagementUri)
                };
                GeneratedCode.SystemInfo systemInfo = await this.Execute(
                    () => edgeletHttpClient.GetSystemInfoAsync(this.Version.Name, cancellationToken),
                    "Getting System Info");

                var provisioning = new ProvisioningInfo(systemInfo.Provisioning.Type, systemInfo.Provisioning.DynamicReprovisioning, systemInfo.Provisioning.AlwaysReprovisionOnStartup ?? true);
                return(new SystemInfo(systemInfo.OsType, systemInfo.Architecture, systemInfo.Version, provisioning, systemInfo.Server_version, systemInfo.Kernel_version, systemInfo.Operating_system, systemInfo.Cpus ?? 0));
            }
        }
        public async Task <SystemInfo> GetSystemInfo()
        {
            GeneratedCode.SystemInfo systemInfo = await this.moduleManager.GetSystemInfoAsync();

            return(new SystemInfo(systemInfo.OsType, systemInfo.Architecture, systemInfo.Version));
        }