This commit is contained in:
Redkale
2018-08-24 16:04:49 +08:00
parent 620fa0430c
commit 0dd55dc947
2 changed files with 5 additions and 2 deletions

View File

@@ -408,7 +408,10 @@ public abstract class NodeServer {
} else {
service = Sncp.createRemoteService(serverClassLoader, resourceName, serviceImplClass, appSncpTransFactory, NodeServer.this.sncpAddress, groups, entry.getProperty());
}
if (SncpClient.parseMethod(serviceImplClass).isEmpty() && serviceImplClass.getAnnotation(Priority.class) == null) return; //class没有可用的方法且没有标记启动优先级的 通常为BaseService
if (SncpClient.parseMethod(serviceImplClass).isEmpty() && serviceImplClass.getAnnotation(Priority.class) == null) { //class没有可用的方法且没有标记启动优先级的 通常为BaseService
logger.log(Level.FINE, serviceImplClass + " cannot load because not found less one public non-final method");
return;
}
final Class restype = Sncp.getResourceType(service);
if (rf.find(resourceName, restype) == null) {