Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for redirectCode (0.32 sec)

  1. pilot/pkg/networking/core/route/route_test.go

    		Http: []*networking.HTTPRoute{
    			{
    				Redirect: &networking.HTTPRedirect{
    					Uri:          "example.org",
    					Authority:    "some-authority.default.svc.cluster.local",
    					RedirectCode: 308,
    				},
    			},
    		},
    	},
    }
    
    var virtualServiceWithRedirectPathPrefix = config.Config{
    	Meta: config.Meta{
    		GroupVersionKind: gvk.VirtualService,
    		Name:             "acme",
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 14 14:12:39 UTC 2024
    - 88.1K bytes
    - Viewed (0)
  2. pilot/pkg/networking/core/route/route.go

    			action.Redirect.PortRedirect = 0
    		}
    		if action.Redirect.PortRedirect == 443 && scheme == "https" {
    			action.Redirect.PortRedirect = 0
    		}
    	}
    
    	switch redirect.RedirectCode {
    	case 0, 301:
    		action.Redirect.ResponseCode = route.RedirectAction_MOVED_PERMANENTLY
    	case 302:
    		action.Redirect.ResponseCode = route.RedirectAction_FOUND
    	case 303:
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 14 14:12:39 UTC 2024
    - 56.1K bytes
    - Viewed (0)
  3. pilot/pkg/config/kube/gateway/conversion.go

    	if filter == nil {
    		return nil
    	}
    	resp := &istio.HTTPRedirect{}
    	if filter.StatusCode != nil {
    		// Istio allows 301, 302, 303, 307, 308.
    		// Gateway allows only 301 and 302.
    		resp.RedirectCode = uint32(*filter.StatusCode)
    	}
    	if filter.Hostname != nil {
    		resp.Authority = string(*filter.Hostname)
    	}
    	if filter.Scheme != nil {
    		// Both allow http and https
    		resp.Scheme = *filter.Scheme
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri Jun 14 04:34:37 UTC 2024
    - 84.7K bytes
    - Viewed (0)
  4. src/net/http/client_test.go

    	}
    	if ue.Err != context.Canceled {
    		t.Errorf("url.Error.Err = %v; want %v", ue.Err, context.Canceled)
    	}
    }
    
    type redirectTest struct {
    	suffix       string
    	want         int // response code
    	redirectBody string
    }
    
    func TestPostRedirects(t *testing.T) {
    	postRedirectTests := []redirectTest{
    		{"/", 200, "first"},
    		{"/?code=301&next=302", 200, "c301"},
    		{"/?code=302&next=302", 200, "c302"},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 21:30:50 UTC 2024
    - 63.8K bytes
    - Viewed (0)
Back to top