glassfish
  1. glassfish
  2. GLASSFISH-19645

asadmin/nadmin help fails on some commands

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0_dev
    • Fix Version/s: 4.0_dev
    • Component/s: command_line_interface
    • Labels:
      None

      Description

      nadmin start-domain --help
      Cannot find man page for command: start-domain
      Command start-domain failed.

      nadmin stop-domain --help
      Cannot find man page for command: stop-domain
      Command stop-domain failed.

      nadmin monitor --help
      Cannot find man page for command: monitor
      Command monitor failed.

      etc...

        Activity

        Hide
        Tom Mueller added a comment -

        The root cause of this problem is that the manual pages for those commands are in the admin-cli.jar file rather than server-mgmt.jar (where the code is). Need to align the manual pages into the JAR files where the code lives.

        Show
        Tom Mueller added a comment - The root cause of this problem is that the manual pages for those commands are in the admin-cli.jar file rather than server-mgmt.jar (where the code is). Need to align the manual pages into the JAR files where the code lives.
        Hide
        Tom Mueller added a comment -

        Here are the GlassFish modules and the local commands they contain. The manpage module is in ():

        admin-cli.jar (admin-cli-manpage)

        • nadmin (we don't really need a manpage for this)
        • export
        • help
        • list-commands
        • login
        • more
        • multimode
        • unset
        • version

        cli-optional.jar (admin-cli-optional-manpage)

        • backup-domain
        • list-backups
        • restore-domain
        • start-database
        • stop-database

        server-mgmt.jar (none - need a new module)

        • change-admin-password
        • change-master-password
        • create-domain
        • create-service
        • delete-domain
        • delete-service
        • list-domains
        • monitor
        • restart-domain
        • start-domain
        • stop-domain
        • verify-domain-xml

        cluster-cli.jar (cluster-cli-manpage)

        • change-node-master-password
        • create-local-instance
        • create-node-agent (I'm surprised this is there since we don't actually support this. Probably just there for compatibility)
        • delete-local-instance
        • import-sync-bundle
        • install-node
        • install-node-ssh
        • install-node-dcom
        • restart-local-instance
        • setup-ssh
        • setup-dcom
        • start-local-instance
        • stop-local-instance
        • uninstall-node-dcom
        • uninstall-node-ssh
        • uninstall-node
        • validate-multicast

        appserver-cli.jar (none - need a new module)

        • asadmin
        Show
        Tom Mueller added a comment - Here are the GlassFish modules and the local commands they contain. The manpage module is in (): admin-cli.jar (admin-cli-manpage) nadmin (we don't really need a manpage for this) export help list-commands login more multimode unset version cli-optional.jar (admin-cli-optional-manpage) backup-domain list-backups restore-domain start-database stop-database server-mgmt.jar (none - need a new module) change-admin-password change-master-password create-domain create-service delete-domain delete-service list-domains monitor restart-domain start-domain stop-domain verify-domain-xml cluster-cli.jar (cluster-cli-manpage) change-node-master-password create-local-instance create-node-agent (I'm surprised this is there since we don't actually support this. Probably just there for compatibility) delete-local-instance import-sync-bundle install-node install-node-ssh install-node-dcom restart-local-instance setup-ssh setup-dcom start-local-instance stop-local-instance uninstall-node-dcom uninstall-node-ssh uninstall-node validate-multicast appserver-cli.jar (none - need a new module) asadmin
        Hide
        Tom Mueller added a comment -

        Fixed on the trunk in revision 59613.
        The manual pages were rearranged in to the correct modules and the man page modules were renamed. Serveral new manual pages modules were added.

        Show
        Tom Mueller added a comment - Fixed on the trunk in revision 59613. The manual pages were rearranged in to the correct modules and the man page modules were renamed. Serveral new manual pages modules were added.
        Hide
        Tom Mueller added a comment -

        Not fixed quite yet. Now the man page for asadmin itself is not found:

        $ asadmin -?
        Cannot find man page for command: help
        Command help failed.

        Show
        Tom Mueller added a comment - Not fixed quite yet. Now the man page for asadmin itself is not found: $ asadmin -? Cannot find man page for command: help Command help failed.
        Hide
        Tom Mueller added a comment -

        The problem is that the command framework is looking for the help file for the main command in the com/sun/enterprise/admin/cli directory of the JAR file, no matter what package the main for the command is actually in.
        This is the package of the "HelpCommand" class. If asadmin.1m is moved to that directory in the appserver-cli.jar file, then the manual page lookup works.

        We have two ways of fixing this:

        1. Just move the asadmin.1m file to the com/sun/enterprise/admin/cli directory.

        2. Modify the command skinning code (CLICommand) so that it has access to the class that actually implements the command. It could then get the right package name to use to look up the manual page.

        Assigning to Mike because he needs to make the fix if we choose #1. If we are going to do #2, assign it back to me.

        Show
        Tom Mueller added a comment - The problem is that the command framework is looking for the help file for the main command in the com/sun/enterprise/admin/cli directory of the JAR file, no matter what package the main for the command is actually in. This is the package of the "HelpCommand" class. If asadmin.1m is moved to that directory in the appserver-cli.jar file, then the manual page lookup works. We have two ways of fixing this: 1. Just move the asadmin.1m file to the com/sun/enterprise/admin/cli directory. 2. Modify the command skinning code (CLICommand) so that it has access to the class that actually implements the command. It could then get the right package name to use to look up the manual page. Assigning to Mike because he needs to make the fix if we choose #1. If we are going to do #2, assign it back to me.
        Hide
        Mike Fitch added a comment -

        Moved asadmin.1m to com/sun/enterprise/admin/cli in appserver-cli-manpage and made this change available as version 4.0-b16 of main-docs.

        All that remains is for GlassFish's top-level pom file to be set to pick up this version instead of 4.0-b15.

        Changing issue assignee back to Tom.

        Show
        Mike Fitch added a comment - Moved asadmin.1m to com/sun/enterprise/admin/cli in appserver-cli-manpage and made this change available as version 4.0-b16 of main-docs. All that remains is for GlassFish's top-level pom file to be set to pick up this version instead of 4.0-b15. Changing issue assignee back to Tom.
        Hide
        Tom Mueller added a comment -

        asadmin -? request resolved in revision 59678.

        Show
        Tom Mueller added a comment - asadmin -? request resolved in revision 59678.

          People

          • Assignee:
            Tom Mueller
            Reporter:
            Chris Kasso
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: