[This article was first published on Revolutions, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
by Hong Ooi
This is a summary of the updates to AzureR family of packages in May and June 2021.
AzureAuth
- Change the default caching behaviour to disable the cache if running inside Shiny.
- Update Shiny vignette to clean up redirect page after authenticating (thanks to Tyler Littlefield).
- Add a
create_AzureR_dir
function to create the caching directory manually. This can be useful not just for non-interactive sessions, but also Jupyter and R notebooks, which are not technically interactive in the sense that they cannot read user input from a console prompt.
AzureGraph
- Add enhanced support for the paging API. Many Graph calls that return lists of objects do so in pages: the first response contains a subset of the full list, along with a link to the next subset. AzureGraph now features a new
ms_graph_pager
R6 class, which is an iterator for the pages in the result. Alllist_*
R6 methods have been rewritten to use this class, and havefilter
andn
arguments to filter the result set and cap the number of results. - Also add support for the batch request feature: you can pass multiple calls to the API with the
graph_request
R6 class andcall_batch_endpoint
function, and get the results back in a single response. - See the Batching and paging vignette for more information on these APIs.
- Add
list_users()
,list_groups()
,list_apps()
andlist_service_principals()
methods to the mainms_graph
client class. - There is also a new Authentication vignette to guide users through the various ways to authenticate to Microsoft Graph.
AzureRMR
- Similar to AzureGraph, AzureRMR has a new Authentication vignette that details how to authenticate to Resource Manager. This replaces the old “Service principal” vignette.
- Update Resource Manager API version to “2021-04-01”; also update
az_subscription$list_locations
to handle the new response format in this API version.
AzureStor
- Add support for generating a service SAS. There is a new S3 generic
get_service_sas
with methods foraz_storage
andstorage_endpoint
objects, and a similar R6 method foraz_storage
objects. See?sas
for more information. - Fix
storage_save_rds
andstorage_load_rds
to handle compression correctly. In particular,storage_load_rds
should now correctly load files saved withsaveRDS
(#83). - Fix a bug that caused
list_blobs
to fail when leases were present. - Use a raw connection instead of a raw vector when calling
readr::read_delim
andread_csv2
. This works around an issue introduced in readr 1.4.0 (#85, #86). - Update client API version to “2020-04-08”. In particular, this allows specifying
resource_type="d"
when creating a service or user delegation SAS for blob storage. - Add an optional
service
argument tostorage_endpoint
, to specify the service in question: blob, file, ADLS2, queue or table. This allows use of the generic endpoint function with URLs that don’t fit the usual pattern where the service is part of the hostname, eg custom domain names, IP addresses, etc.- For the same reason, remove the warning about an unrecognised endpoint URL from
blob_endpoint
,file_endpoint
andadls_endpoint
.
- For the same reason, remove the warning about an unrecognised endpoint URL from
Microsoft365R
Microsoft365R has some significant new features in the latest version:
OneDrive/SharePoint
- Add a
list_shared_items()
method for thems_drive
class to access files and folders shared with you (#45). - Allow getting drives for groups, sites and teams by name. The first argument to the
get_drive()
method for these classes is nowdrive_name
; to get a drive by ID, specify the argument name explicitly:get_drive(drive_id=*)
- Add a
by_item
argument to thedelete_item()
method for drives and thedelete()
method for drive items (#21). This is to allow deletion of non-empty folders on SharePoint sites with data protection policies in place. Use with caution.
Outlook
- Add a
search
argument to thems_outlook_folder$list_emails()
method. The default is to search in the from, subject and body of the emails.
Teams
- Add
list_members()
andget_member()
methods for teams and channels. - Add support for @mentions in Teams channel messages (#26).
Other
- All
list_*
class methods now havefilter
andn
arguments to filter the result set and cap the number of results, following the pattern in AzureGraph. The default values arefilter=NULL
andn=Inf
. Ifn=NULL
, anms_graph_pager
iterator object is returned instead to allow manual iteration over the results. Note that support for filtering in the underlying Graph API is somewhat uneven at the moment. - Experimental read-only support for plans, contributed by Roman Zenka.
- Add
get_plan()
andlist_plans()
methods to theaz_group
class. Note that only Microsoft 365 groups can have plans, not any other type of group. - To get the plan(s) for a site or team, call its
get_group()
method to retrieve the associated group, and then get the plan from the group. - A plan has methods to retrieve tasks and buckets, as well as plan details.
- Add
To leave a comment for the author, please follow the link and comment on their blog: Revolutions.
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.