A module is basically the collection of resources from the VFS attached with some configuration. Typically, resources that are required to make up some functionality are grouped as a module. The group can either be very fine-granular, e.g., contain only a new resource type and provide schema, formatter, maybe some Java library and configuration of it, or, it can be very coarse, containing all the resources you need to build up a website, i.e., template JSP, resource types (with schemas and formatters), images, JavaScript, CSS, jars, classes, .... What's the correct choice for you depends on your use case and is discussed later on.
Grouping resources into modules has several advantages, because the modules are more than the simple collections of resources. You can:
- import and export modules
- define dependencies between modules
- use version numbers
- add module parameters to adjust a module's behavior for varying systems, e.g., configure data-base connections
- group related modules
- configure actions triggered when a module is imported, updated or removed.
To avoid naming conflicts, modules are named like Java packages, e.g., com.mydomain.mymodule
. This name is also called the module's package name.Your module may additionally also have a more human readable name, as well as a description etc.