最简单的方式来使用LDAP在Java中(Eclipse中) [英] Easiest way to use LDAP in Java (Eclipse)

查看:1233
本文介绍了最简单的方式来使用LDAP在Java中(Eclipse中)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前工作的一个小项目,我必须使用LDAP在Eclipse(主动目录的访问)。我想要得到的用户名,创建一个新用户,删除用户...

I'm currently working on a small project where I have to use LDAP in Eclipse (for Active-Directory access). I want to get the Usernames, create a new user, delete a user...

我其实从来没有与LDAP工作之前,我曾与找到一个很好的解释一步一步的教程,开始有一些困难。此外,它似乎每个教程似乎使用不同的API(OpenLDAP的,Apache目录,UnboundID,Spring框架等。),这混淆了我。哪个API我应该使用?

I actually never worked with LDAP before and I had a few difficulties with finding a well explained step-by-step tutorial to start with. In addition it seems that every tutorial seems to use a different API (OpenLDAP, Apache Directory, UnboundID, Spring Framework ect.), which confuses me. Which API should I use?

我会很感激,如果你有一个关于如何开始使用LDAP一些提示

I would be very thankful if you would have some hints on how to get started with LDAP

推荐答案

我个人的选择是UnboindID这远非完美,但比其他人更近,而且至少不会像弹簧LDAP死的项目。这当然有一些恼人的问题,例如许多类在其API是最后这是不是特别测试友好的,因为你不能很容易地创建他们的嘲笑。

My personal choice was UnboindID which is far from perfect, but is more recent than the others, and at least not a dead project like spring-ldap. It certainly has some annoying problems, for example many classes in its API are final which is not particularly testing friendly, as you cannot easily create mocks of them.

但是,如果我开始一个新的项目,现在,我会考虑使用 ldaptive 这是不是另一个LDAP客户端实现,只是一个API层上的具体实现(提供者),其所代表的LDAP操作。它可以与许多不同的的工作,似乎提供了一个更漂亮的API和良好的文档

However if I started a new project now, I would consider using ldaptive which is not another LDAP client implementation, just an API layer above a concrete implementation (provider) to which it delegates LDAP operations. It can work with many different providers, and seems to offer a much nicer API and good documentation.

这篇关于最简单的方式来使用LDAP在Java中(Eclipse中)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆