Error during sync: UpdateURLMap: googleapi: Error 413: Value for field resource.pathMatchers[0].pathRules is too large

9/15/2018

When I add morethan 50 Paths in the Ingress file - getting below error from Google Cloud Platform.

"Error during sync: UpdateURLMap: googleapi: Error 413: Value for field 'resource.pathMatchers[0].pathRules' is too large: maximum size 50 element(s); actual size 51., fieldSizeTooLarge"

We are using Path based Ingress thru Traefik. This error coming from Google Cloud Platform.

Sample Ingress looklike:

apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  annotations:
    traefik.frontend.rule.type: PathPrefixStrip
  name: traefik-ingress
  namespace: default
spec:
  rules:
  - host: domain-name.com
    http:
      paths:
      - backend:
          serviceName: default-http-backend
          servicePort: 8080
        path: /
      - backend:
          serviceName: foo1-service
          servicePort: 8080
        path: /foo1/*
      - backend:
          serviceName: foo2-service
          servicePort: 8080
        path: /foo2/*
      - backend:
          serviceName: foo3-service
          servicePort: 8080
        path: /foo3/*
-- Asarudeen A
google-cloud-platform
google-kubernetes-engine
kubernetes
kubernetes-ingress

2 Answers

9/16/2018

Looks like your ingress is using a layer 7 load balancer in GCP and the limit for path rules is 50. I couldn't find a standard limit for the path rules in an HTTP(s) load balancer in GCP in their docs. You can see it host and path rules for your LB:

host and path rules

I recommend:

  1. Create another ingress controller.
  2. Open a support ticket with GCP so that they can increase the limit on path rules for your HTTP(s) load balancer for your project if they can.
-- Rico
Source: StackOverflow

6/24/2019

This is hard limitation of the URLMap resource, which cannot be increased.

URL maps

Host rules per URL map - 50 - This limit cannot be increased.

Here's a feature request to increase this limit: https://issuetracker.google.com/issues/126946582

-- Eduard Wirch
Source: StackOverflow