You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficcontrol.apache.org by zr...@apache.org on 2021/08/31 18:56:27 UTC

[trafficcontrol] branch 6.0.x updated (7bcf4ea -> 3a3e76a)

This is an automated email from the ASF dual-hosted git repository.

zrhoffman pushed a change to branch 6.0.x
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git.


    from 7bcf4ea  Make TM recover from TO being unavailable at startup (#6146)
     new e1be679  Enable GH wiki
     new a50693e  Re-enable accidentally disabled features (#6150)
     new 3a3e76a  Fix a null pointer exception when delivery service doesn't exist (#6153)

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .asf.yaml                                            |  4 ++++
 .../traffic_router/core/dns/ZoneManager.java         | 20 ++++++++++++--------
 2 files changed, 16 insertions(+), 8 deletions(-)

[trafficcontrol] 03/03: Fix a null pointer exception when delivery service doesn't exist (#6153)

Posted by zr...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

zrhoffman pushed a commit to branch 6.0.x
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git

commit 3a3e76af8a1c461c8fd2e7ca11a7d2692e47b4ab
Author: Steve Malenfant <sm...@users.noreply.github.com>
AuthorDate: Tue Aug 31 14:40:46 2021 -0400

    Fix a null pointer exception when delivery service doesn't exist (#6153)
    
    * Fix a null pointer exception when delivery service doesn't exist
    
    * Fixing white spaces
    
    * Fixes tab
    
    * Removing space and adding tabs
    
    Co-authored-by: Steve Malenfant <st...@cox.com>
    (cherry picked from commit a4334ad4a65d3a43463ad23142241957fc72c581)
---
 .../traffic_router/core/dns/ZoneManager.java         | 20 ++++++++++++--------
 1 file changed, 12 insertions(+), 8 deletions(-)

diff --git a/traffic_router/core/src/main/java/org/apache/traffic_control/traffic_router/core/dns/ZoneManager.java b/traffic_router/core/src/main/java/org/apache/traffic_control/traffic_router/core/dns/ZoneManager.java
index a040bd6..674b8cf 100644
--- a/traffic_router/core/src/main/java/org/apache/traffic_control/traffic_router/core/dns/ZoneManager.java
+++ b/traffic_router/core/src/main/java/org/apache/traffic_control/traffic_router/core/dns/ZoneManager.java
@@ -701,10 +701,10 @@ public class ZoneManager extends Resolver {
 						ttl = ZoneUtils.getLong(ds.getTtls(), type, 60);
 					}
 					switch(type) {
-						case "A": 
+						case "A":
 							list.add(new ARecord(name, DClass.IN, ttl, InetAddress.getByName(value)));
 							break;
-						case "AAAA": 
+						case "AAAA":
 							list.add(new AAAARecord(name, DClass.IN, ttl, InetAddress.getByName(value)));
 							break;
 						case "CNAME":
@@ -741,7 +741,7 @@ public class ZoneManager extends Resolver {
 			// NSRecords will be replaced later if tr.isEdgeDNSRouting() is true; we need these to allow stub zones to be signed, etc
 			list.add(new NSRecord(name, DClass.IN, ZoneUtils.getLong(ttl, "NS", 60), getGlueName(ds, trJo, name, key)));
 			list.add(new ARecord(trName,
-					DClass.IN, ZoneUtils.getLong(ttl, "A", 60), 
+					DClass.IN, ZoneUtils.getLong(ttl, "A", 60),
 					InetAddress.getByName(JsonUtils.optString(trJo, IP))));
 
 			String ip6 = trJo.get("ip6").asText();
@@ -866,7 +866,7 @@ public class ZoneManager extends Resolver {
 
 	/**
 	 * Gets trafficRouter.
-	 * 
+	 *
 	 * @return the trafficRouter
 	 */
 	public TrafficRouter getTrafficRouter() {
@@ -875,7 +875,7 @@ public class ZoneManager extends Resolver {
 
 	/**
 	 * Attempts to find a {@link Zone} that would contain the specified {@link Name}.
-	 * 
+	 *
 	 * @param name
 	 *            the Name to use to attempt to find the Zone
 	 * @return the Zone to use to resolve the specified Name
@@ -922,7 +922,7 @@ public class ZoneManager extends Resolver {
 	/**
 	 * Creates a dynamic zone that serves a set of A and AAAA records for the specified {@link Name}
 	 * .
-	 * 
+	 *
 	 * @param staticZone
 	 *            The Zone that would normally serve this request
 	 * @param builder
@@ -940,8 +940,12 @@ public class ZoneManager extends Resolver {
 			if (result != null) {
 				final Zone dynamicZone = fillDynamicZone(dynamicZoneCache, staticZone, request, result);
 				track.setResultCode(dynamicZone, request.getName(), request.getQueryType());
-				builder.deliveryServiceXmlIds(result.getDeliveryService().getId());
-				return dynamicZone;
+				if (result.getDeliveryService() == null) {
+					builder.deliveryServiceXmlIds(null);
+        			} else {
+				        builder.deliveryServiceXmlIds(result.getDeliveryService().getId());
+			        }
+        			return dynamicZone;
 			} else {
 				return null;
 			}

[trafficcontrol] 02/03: Re-enable accidentally disabled features (#6150)

Posted by zr...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

zrhoffman pushed a commit to branch 6.0.x
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git

commit a50693ea625f034e107aa53271153cb9c052e574
Author: ocket8888 <oc...@gmail.com>
AuthorDate: Tue Aug 31 11:00:01 2021 -0600

    Re-enable accidentally disabled features (#6150)
    
    (cherry picked from commit 53975b3a20bdc63fad5d5506423473ec47c9d761)
---
 .asf.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/.asf.yaml b/.asf.yaml
index 04f3db4..a3db4f8 100644
--- a/.asf.yaml
+++ b/.asf.yaml
@@ -26,3 +26,5 @@ github:
   - hacktoberfest
   features:
     wiki: true
+    issues: true
+    projects: true

[trafficcontrol] 01/03: Enable GH wiki

Posted by zr...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

zrhoffman pushed a commit to branch 6.0.x
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git

commit e1be67939767ab6136f39e693b5e20d543f1701d
Author: ocket8888 <oc...@gmail.com>
AuthorDate: Tue Aug 31 10:19:32 2021 -0600

    Enable GH wiki
    
    (cherry picked from commit 59bceb85a90e22feb9b47a4dd2b590c50e23b4c5)
---
 .asf.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/.asf.yaml b/.asf.yaml
index a67d580..04f3db4 100644
--- a/.asf.yaml
+++ b/.asf.yaml
@@ -24,3 +24,5 @@ github:
   - cdn
   - contentdelivery
   - hacktoberfest
+  features:
+    wiki: true