Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 49 for responses (0.13 sec)

  1. internal/config/policy/opa/config.go

    	if err != nil {
    		return false, err
    	}
    
    	// Handle large OPA responses when OPA URL is of
    	// form http://localhost:8181/v1/data/httpapi/authz
    	type opaResultAllow struct {
    		Result struct {
    			Allow bool `json:"allow"`
    		} `json:"result"`
    	}
    
    	// Handle simpler OPA responses when OPA URL is of
    	// form http://localhost:8181/v1/data/httpapi/authz/allow
    	type opaResult struct {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  2. internal/grid/stream.go

    import (
    	"context"
    	"errors"
    )
    
    // A Stream is a two-way stream.
    // All responses *must* be read by the caller.
    // If the call is canceled through the context,
    // the appropriate error will be returned.
    type Stream struct {
    	// responses from the remote server.
    	// Channel will be closed after error or when remote closes.
    	// All responses *must* be read by the caller until either an error is returned or the channel is closed.
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri Jun 07 15:51:52 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  3. internal/http/response-recorder.go

    	"fmt"
    	"io"
    	"net"
    	"net/http"
    	"time"
    )
    
    // ResponseRecorder - is a wrapper to trap the http response
    // status code and to record the response body
    type ResponseRecorder struct {
    	http.ResponseWriter
    	io.ReaderFrom
    	StatusCode int
    	// Log body of 4xx or 5xx responses
    	LogErrBody bool
    	// Log body of all responses
    	LogAllBody bool
    
    	TimeToFirstByte time.Duration
    	StartTime       time.Time
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Sat Dec 02 00:13:19 UTC 2023
    - 4.9K bytes
    - Viewed (0)
  4. internal/grid/connection_test.go

    	errFatal(remoteConn.WaitForConnect(context.Background()))
    
    	stream, err := remoteConn.NewStream(context.Background(), handlerTest2, []byte(testPayload))
    	errFatal(err)
    	go func() {
    		for resp := range stream.responses {
    			t.Log("Resp:", resp, err)
    		}
    		gotResp <- struct{}{}
    	}()
    
    	<-gotCall
    	remote.debugMsg(debugKillOutbound)
    	local.debugMsg(debugKillOutbound)
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue Nov 21 01:09:35 UTC 2023
    - 6K bytes
    - Viewed (0)
  5. internal/grid/muxserver.go

    			select {
    			case <-m.ctx.Done():
    				return
    			case handlerIn <- in:
    				m.send(message{Op: OpUnblockClMux, MuxID: m.ID, Flags: c.baseFlags})
    			}
    		}
    	}
    }
    
    // sendResponses will send responses to the client.
    func (m *muxServer) sendResponses(ctx context.Context, toSend <-chan []byte, c *Connection, handlerErr *atomic.Pointer[RemoteErr], outBlock <-chan struct{}) {
    	for {
    		// Process outgoing message.
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri Jun 07 15:51:52 UTC 2024
    - 9.7K bytes
    - Viewed (0)
  6. internal/grid/README.md

        if err == nil {
            fmt.Println("Got response with field", resp["result"])
        }
    ```
    
    The wrapper will handle all serialization and de-seralization of the request and response,
    and furthermore provides reuse of the structs used for the request and response.
    
    Note that Responses sent for serialization are automatically reused for similar requests.
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Jan 18 07:03:17 UTC 2024
    - 9.4K bytes
    - Viewed (0)
  7. internal/s3select/errors.go

    package s3select
    
    import "strings"
    
    // SelectError - represents s3 select error specified in
    // https://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectSELECTContent.html#RESTObjectSELECTContent-responses-special-errors.
    type SelectError interface {
    	Cause() error
    	ErrorCode() string
    	ErrorMessage() string
    	HTTPStatusCode() int
    	Error() string
    }
    
    type s3Error struct {
    	code       string
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Mar 14 16:48:36 UTC 2022
    - 4.3K bytes
    - Viewed (0)
  8. internal/config/policy/plugin/config.go

    	if err != nil {
    		return false, err
    	}
    
    	// Handle large OPA responses when OPA URL is of
    	// form http://localhost:8181/v1/data/httpapi/authz
    	type opaResultAllow struct {
    		Result struct {
    			Allow bool `json:"allow"`
    		} `json:"result"`
    	}
    
    	// Handle simpler OPA responses when OPA URL is of
    	// form http://localhost:8181/v1/data/httpapi/authz/allow
    	type opaResult struct {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  9. cmd/sts-errors.go

    	apiErr, ok := e[errCode]
    	if !ok {
    		return e[ErrSTSInternalError]
    	}
    	return apiErr
    }
    
    // error code to STSError structure, these fields carry respective
    // descriptions for all the error responses.
    var stsErrCodes = stsErrorCodeMap{
    	ErrSTSAccessDenied: {
    		Code:           "AccessDenied",
    		Description:    "Generating temporary credentials not allowed for this request.",
    		HTTPStatusCode: http.StatusForbidden,
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Apr 04 12:04:40 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  10. cmd/api-headers.go

    // this in other places.
    func encodeResponseList(response interface{}) []byte {
    	var buf bytes.Buffer
    	buf.WriteString(xxml.Header)
    	if err := xxml.NewEncoder(&buf).Encode(response); err != nil {
    		bugLogIf(GlobalContext, err)
    		return nil
    	}
    	return buf.Bytes()
    }
    
    // Encodes the response headers into JSON format.
    func encodeResponseJSON(response interface{}) []byte {
    	var bytesBuffer bytes.Buffer
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue May 28 04:44:00 UTC 2024
    - 7K bytes
    - Viewed (0)
Back to top