Created
January 29, 2018 15:11
-
-
Save nickname55/eb5771829b3e9e17994dd51339ce492d to your computer and use it in GitHub Desktop.
Confluence REST - получаем группу по имени
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.pampushko.confluence.rest; | |
import com.pampushko.confluence.models.group.Group; | |
import com.pampushko.confluence.settings.SettingsManager; | |
import lombok.extern.slf4j.Slf4j; | |
import java.io.IOException; | |
import java.util.Properties; | |
@Slf4j | |
public class Main | |
{ | |
public static final String url = ""; | |
private static final String username = ""; | |
private static final String password = ""; | |
public static void main(String[] args) throws IOException | |
{ | |
//читаем настройки приложения | |
Properties settings = SettingsManager.getValues(); | |
//вызываем билдер и создаем клиент | |
ConfluenceClient confluence = ConfluenceClient.newBuilder() | |
.baseUrl(settings.getProperty("baseUrl")) | |
.username(settings.getProperty("username")) | |
.password(settings.getProperty("password")) | |
.build(); | |
String groupName = "jira-core-users"; | |
Group group = confluence.getGroupsByName(groupName); | |
System.out.println(group); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment