dev@glassfish.java.net

Adding PostConstruct to an AdminCommand

From: Kumar Jayanti <Vbkumar.Jayanti_at_Sun.COM>
Date: Mon, 05 Jul 2010 15:49:23 +0530

Hi,

  I am trying to make a Class that implements AdminCommand to also
implement org.jvnet.hk2.component.PostConstruct. If i do this then the
AdminCommand is no longer recognized as an admin command. Is this a
Feature or a Bug or is this expected.

For example i changed the class CreateFileUser.java

public class CreateFileUser implements AdminCommand, PostConstruct {
 ...
}

After doing this when i try create-file-user i get the following error :

>.\asadmin create-file-user test

Closest matching local and remote command(s):
    create-file-user
Command create-file-user failed.


regards,
kumar