You can undeploy web modules and other types of enterprise applications by using either NetBeans IDE or the Ant tool.
Ensure that the GlassFish Server is running.
In the Services window, expand the Servers node, GlassFish Server instance, and the Applications node.
Right-click the hello1 module and choose Undeploy.
To delete the class files and other build artifacts, right-click the project and choose Clean.