use of org.ovirt.engine.sdk4.services.GroupsService in project ovirt-engine-sdk-java by oVirt.
the class AddGroup method main.
public static void main(String[] args) throws Exception {
// Create the connection to the server:
Connection connection = connection().url("https://engine40.example.com/ovirt-engine/api").user("admin@internal").password("redhat123").trustStoreFile("truststore.jks").build();
// Get the reference to the groups service:
GroupsService groupsService = connection.systemService().groupsService();
// Use the "add" method to add group from a directory service. Please note that domain name is name of the
// authorization provider:
groupsService.add().group(group().name("Developers").domain(domain().name("internal-authz"))).send();
// Close the connection to the server:
connection.close();
}
Aggregations