Vert.x module概念
官网: http://vertx.io/vertx2/mods_manual.html#what-is-a-vertx-module
Module Identifier
一个Module有一个唯一标识:三部分组成的字符串
Owner~Name~Version
mod.json
Module descriptor file,每个Module必须有这个文件,在Module的根目录下
描述项:
main : runnable module 必备,指定module入口verticle类名
lang-impl : 多语言,复写langs.properties中配置
worker : 指定为Worker module,允许阻塞操作
includes : 嵌套其他modules
auto-redeploy : 若检测到资源变化则自动重部署,默认为false
system : 在安装modules至sys-mods目录,默认为false
description
licenses
author
keywords
developers
Module lib directory
如果module是直接使用jar,需要放在module根目录的lib/下
Module目录结构示例:
/mod.json
/com/mycompany/myothermod/App.class
/com/mycompany/myothermod/SomeOtherClass.class
/lib/somelib.jar
/lib/someotherlib.jar
Module classpath
module的classpath:根目录与lib/下