Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

Commit

Permalink
Fixes EUCA-2345 where DNS lookup isn't properly happening.
Browse files Browse the repository at this point in the history
  • Loading branch information
gelinasc committed Jul 31, 2012
1 parent 97cddaa commit 31ba3b6
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ public static Name getInternalName( ) throws TextParseException {
public SetResponse findRecords( Name name, int type ) {
if( StackConfiguration.USE_INSTANCE_DNS && name.toString( ).matches("euca-.+{3}-.+{3}-.+{3}-.+{3}\\..*") ) {
try {
String[] tryIp = name.toString( ).replaceAll( "euca-", "" ).replaceAll("\\." + VmInstances.INSTANCE_SUBDOMAIN + ".*","").split("-");
String[] tryIp = name.toString( ).replaceAll( "euca-", "" ).replaceAll(VmInstances.INSTANCE_SUBDOMAIN + ".*","").split("-");
if( tryIp.length < 4 ) return super.findRecords( name, type );
String ipCandidate = new StringBuffer()
.append(tryIp[0]).append(".")
Expand Down

0 comments on commit 31ba3b6

Please sign in to comment.