You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by "Lin Chen (JIRA)" <ji...@apache.org> on 2015/06/05 13:55:00 UTC

[jira] [Comment Edited] (DIRKRB-277) Extract Kadmin API

    [ https://issues.apache.org/jira/browse/DIRKRB-277?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14574357#comment-14574357 ] 

Lin Chen edited comment on DIRKRB-277 at 6/5/15 11:54 AM:
----------------------------------------------------------

Great thoughts!
And thanks Jiajia for the great work! The patch looks very good! 
A question: codes like:
{code}
+    public void addPrincipal(String principal, String password, KOptions kOptions) {
+
+        KrbIdentity identity = createIdentity(principal, password, kOptions);
+        try {
+            backend.addIdentity(identity);
+            System.out.println("Principal \"" + principal + "\" created.");
+        } catch (Exception e) {
+            System.err.println("Principal or policy already exists while creating \"" + principal + "\".");
+        }
+    }
{code} in Kadmin API.
As a API, I am not sure whether is it better to remove some print codes. And maybe it is better to throws exceptions to callers but not handle by itself.


was (Author: hazelc):
Great thoughts!
And thanks Jiajia for the great work! The patch looks very good! +1.

> Extract Kadmin API
> ------------------
>
>                 Key: DIRKRB-277
>                 URL: https://issues.apache.org/jira/browse/DIRKRB-277
>             Project: Directory Kerberos
>          Issue Type: Sub-task
>            Reporter: Kai Zheng
>            Assignee: Kai Zheng
>         Attachments: DIRKRB-277-v1.patch
>
>
> This is to propose extracting {{Kadmin}} API similar to {{KrbClient}} in library level from the {{kadmin}} tool for Kerby KDC. Base on this new API, kadmin tool will be refactored becoming much lightweight, and other KDC side tools will also be easier to come up.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)