Alfresco RESTful client

A client library based on OpenFeign to communicate with Alfresco RESTful services.

Лицензия

Лицензия

Категории

Категории

CLI Взаимодействие с пользователем Dex Универсальные библиотеки Utility
Группа

Группа

pl.dexterxx.dev.alfresco
Идентификатор

Идентификатор

alfresco-restclient
Последняя версия

Последняя версия

1.3.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

Alfresco RESTful client
A client library based on OpenFeign to communicate with Alfresco RESTful services.
Ссылка на сайт

Ссылка на сайт

https://github.com/dexterxx-pl/alfresco-restclient/
Система контроля версий

Система контроля версий

https://github.com/dexterxx-pl/alfresco-restclient

Скачать alfresco-restclient

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/pl.dexterxx.dev.alfresco/alfresco-restclient/ -->
<dependency>
    <groupId>pl.dexterxx.dev.alfresco</groupId>
    <artifactId>alfresco-restclient</artifactId>
    <version>1.3.0</version>
</dependency>
// https://jarcasting.com/artifacts/pl.dexterxx.dev.alfresco/alfresco-restclient/
implementation 'pl.dexterxx.dev.alfresco:alfresco-restclient:1.3.0'
// https://jarcasting.com/artifacts/pl.dexterxx.dev.alfresco/alfresco-restclient/
implementation ("pl.dexterxx.dev.alfresco:alfresco-restclient:1.3.0")
'pl.dexterxx.dev.alfresco:alfresco-restclient:jar:1.3.0'
<dependency org="pl.dexterxx.dev.alfresco" name="alfresco-restclient" rev="1.3.0">
  <artifact name="alfresco-restclient" type="jar" />
</dependency>
@Grapes(
@Grab(group='pl.dexterxx.dev.alfresco', module='alfresco-restclient', version='1.3.0')
)
libraryDependencies += "pl.dexterxx.dev.alfresco" % "alfresco-restclient" % "1.3.0"
[pl.dexterxx.dev.alfresco/alfresco-restclient "1.3.0"]

Зависимости

compile (11)

Идентификатор библиотеки Тип Версия
io.github.openfeign : feign-core jar 9.5.1
io.github.openfeign : feign-jackson jar 9.5.1
io.github.openfeign : feign-jaxrs jar 9.5.1
io.github.openfeign : feign-slf4j jar 9.5.1
io.github.openfeign : feign-annotation-error-decoder jar 1.0.3
io.github.openfeign.form : feign-form jar 3.0.3
com.fasterxml.jackson.core : jackson-databind jar 2.9.3
org.apache.commons : commons-lang3 jar 3.7
org.slf4j : slf4j-api jar 1.7.9
org.apache.tika : tika-core jar 1.16
commons-io : commons-io jar 2.6

Модули Проекта

Данный проект не имеет модулей.

alfresco-restclient

Rest client written in Java 8 with OpenFeign to consume Alfresco RESTful services.

It's fork of techblue/alfresco-restclient project which:

  • Migrates from RestEasy to OpenFeign
  • Migrates from JDK7 to JDK8
  • Updates Jackson Mapper from 1.9 to 2.9
  • Changes JBoss logging to SFL4J bridge
  • [TODO] Migrates test to real unit tests
  • Makes some freshness, cleanup etc. ;)

It may not be compatible with base project and don't expect it will ever be.

Tested (and used right now) only with Alfresco 4.2 version.

Dependency

It's still in early development progress so remember - use at own risk!

Maven

<dependency>
    <groupId>pl.dexterxx.dev.alfresco</groupId>
    <artifactId>alfresco-restclient</artifactId>
    <version>1.3.0</version>
</dependency>

Gradle

compile 'pl.dexterxx.dev.alfresco:alfresco-restclient:1.3.0'

How to use (beta)

final String alfrescoUrl = "http://my-alfresco-host";

final String alfrescoUser = "alfresco-user";

final String alfrescoPass = "alfresco-password";

private void makeSomeStuff() {

    Credentials credentials = new Credentials(alfrescoUser, alfrescoPass);

    // Create AuthService which logins and logouts in Alfresco
    AuthService authService = new AuthService(alfrescoUrl, credentials);

    AuthResponse authResponse = authService.login();
    String token = authResponse.getAuthenticationData().getAuthenticationToken();

    // Let's get node content with our token
    String filePath = "workspace://SpacesStore/6cffe1dd-d4aa-4770-b371-7c9b4c808cc9";
    AlfrescoUtils.AlfrescoStorePath alfPath = AlfrescoUtils.extractPath(filePath);

    DocumentContent nodeContent = new ContentService(alfrescoUrl, token)
        .getNodeContent(alfPath.storeType, alfPath.storeId, alfPath.nodeId);
    
    // so easy!
}

What works and what not

Class / Module Method Status / Does work?
Auth login Works!
Auth logout Works!
Auth validateTicket Works!
Content getNodeContent Works!
Content uploadDocument Probably NOT!
Content getNodeMetadata Maybe
Content storeNodeMetadata ⚠️ Should
Content advancedSearch Probably NOT!
Content deleteDocument ⚠️ Should
Folder createFolder ⚠️ Should
Folder searchFolder Maybe
Folder createFolderByCmisAtomEntry ⚠️ Should
Group getGroups Partial
Group getGroup Works!
Group getRootGroups Probably NOT!
Group getChildAuthorities Probably NOT!
Group getParentAuthorities Probably NOT!
Group deleteGroup ⚠️ Should
Permission setPermissions ⚠️ Should
Permission readPermissions ⚠️ Should
Permission setPermissions ⚠️ Should
User getUsers Works!
User getUser Works!
User createUser ⚠️ Should
User changePassword ⚠️ Should
User deleteUser ⚠️ Should
User updateUser ⚠️ Should
User getUserHome Probably NOT!

Changelog

v1.3.0 - 2017-12-20

  • First public release after fork
  • TODO more info to place here

Contribute

Feel free to pull requests ;).

Версии библиотеки

Версия
1.3.0