Comment 3 for bug 1273790

Matt Bruzek (mbruzek) wrote :

Saurabh.

Thank you so much for the update on the wildfly charm. It is progressing nicely but there are still a few outstanding issues (that I have outlined below) which need to be resolved prior to accepting this charm in the charm store.

Cryptographic signature verification:

The Charm Store Policy (https://juju.ubuntu.com/docs/authors-charm-policy.html) states that charm code should verify the cryptographic signature of the files that are downloaded (in this case wildfly-8.0.0.CR1.tar.gz). You noted that the original web site does not publish the signatures for the files so I would suggest generating a sha1sum from a file that you have verified has worked.

Here is an example of how to get the sha1sum:
$ sha1sum wildfly-8.0.0.CR1.tar.gz
5f7289a4e8f05e3772808675342aaa8735bad704 wildfly-8.0.0.CR1.tar.gz

Store a valid value for that version in a variable and compare the sha1sum of the file the charm downloads to verify the file is complete and has not changed since the charm was created.

README.md

I saw the README was converted from text to markdown format. My tool (markdown available from apt-get install markdown) was not able to convert README.md to HTML correctly. It looks like there are too many spaces and too few spaces in other places. There are markdown validation tools available on-line (http://daringfireball.net/projects/markdown/dingus) that will help get the format correct.

Errors in the hooks:

I was watching the logs while the wildfly charm installed, and noticed a few errors involving the jboss.pid file:

2014-02-07 20:53:14 INFO juju-log Stopping wildfly apllication server
2014-02-07 20:53:14 INFO config-changed Notfound
2014-02-07 20:53:14 INFO config-changed cat: /opt/wildfly/bin/jboss.pid: No such file or directory
2014-02-07 20:53:14 INFO config-changed kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
2014-02-07 20:53:14 INFO juju-log wildfly stopped successfully

This looks like a problem with the wildfly.sh file that was created.

Open ports:

The charm must open all ports that are needed for operation.

I deployed the wildfly charm to the HP cloud which is an OpenStack environment. I am now able to get to the wildfly administration console on http://ip:9990/. However that is the only port open. I installed a sample war file and was not able to view the webapp context on port 8080. It looks like port 8080 needs to be opened for the webapps to be visible.

You might not have seen this problem because the local provider does not have any firewall on the instances, but providers such as AWS, and HP cloud will have firewalls that Juju handles for you with the open-port, and close-port commands.

It does not look like the code relates the configuration value http-port to any wildfly configuration. For example when I called: juju set wildfly http-port=9991 I was not able to access the admin console on port 9991. Normally the config-changed hook would set some value in wildfly configuration when the port changes. If the ports are not configurable then remove http-port from config.yaml and open the default ports in the install hook.

Thanks again for submitting this char to the charm store. Let us know if you have any questions. For the time being I have moved the bug to Incomplete. When you are ready for another review please move the bug status to either “New” or “Fix Committed” to have it added back to the queue for review.

Thanks again for the work in this last update. If you have additional questions, find us on #juju on freenode.net, <email address hidden>, or tag juju on askubuntu.com