ravening commented on a change in pull request #4396:
URL: https://github.com/apache/cloudstack/pull/4396#discussion_r503886888
##########
File path: server/src/main/java/com/cloud/vm/UserVmManagerImpl.java
##########
@@ -3821,7 +3821,7 @@ private void checkIfHostNameUniqueInNtwkDomain(String
hostName, List<? extends N
// * verify that there are no duplicates
if (hostNames.contains(hostName)) {
throw new InvalidParameterValueException("The vm with
hostName " + hostName + " already exists in the network domain: " +
ntwkDomain.getKey() + "; network="
- + _networkModel.getNetwork(ntwkId));
+ + _networkModel.getNetwork(ntwkId).getName());
Review comment:
> > > @ravening How about just adding the network name to the NetworkVO
toString(), so this remains the same, and we get to see the network's name
along with other details like networkId, traffic type, etc?
>
> >
>
> > @Pearl1594 should we all those detail in exception message? It makes
sense to add entire networkVO object tostring in log message
>
>
>
> It actually depends, we may not want to show the network Id (i.e, DB id)
to users, so maybe replace id with name in the toString()
That will involve extra code changes which I want to avoid
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]