fixed target create
This commit is contained in:
parent
95b6222288
commit
631d3a1fd8
|
@ -77,6 +77,17 @@ public class TargetDiscoveryService {
|
|||
|
||||
InfraService dbInfraService = this.infraServiceService.readByService(infraHost.getId(), port.getPortNumber(), portType);
|
||||
|
||||
if(dbInfraService != null) {
|
||||
if(service.isTarget() && dbInfraService.getTarget() == null) {
|
||||
Target targetService = new Target();
|
||||
targetService.setDisplayName(service.getServiceName() + "-Service");
|
||||
this.targetService.regist(targetService);
|
||||
dbInfraService.setTarget(targetService);
|
||||
this.infraServiceService.regist(dbInfraService);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
InfraService infraService = new InfraService();
|
||||
infraService.setHost(infraHost);
|
||||
infraService.setPort(port.getPortNumber());
|
||||
|
|
Loading…
Reference in New Issue
Block a user