_id
stringlengths
2
7
title
stringclasses
1 value
partition
stringclasses
3 values
text
stringlengths
6
2.61k
language
stringclasses
1 value
meta_information
dict
c162500
train
// NodeObserver returns the node store observer of the configuration
{ "resource": "" }
c162501
train
// NewClusterMesh creates a new remote cluster cache based on the // provided configuration
{ "resource": "" }
c162502
train
// Close stops watching for remote cluster configuration files to appear and // will close all connections to remote clusters
{ "resource": "" }
c162503
train
// NumReadyClusters returns the number of remote clusters to which a connection // has been established
{ "resource": "" }
c162504
train
// LogCurrentSystemLoad logs the current system load and lists all processes // consuming more than cpuWatermark of the CPU
{ "resource": "" }
c162505
train
// LogPeriodicSystemLoad logs the system load in the interval specified until // the channel is closed
{ "resource": "" }
c162506
train
// ListAndWatch creates a new watcher which will watch the specified prefix for // changes. Before doing this, it will list the current keys matching the // prefix and report them as new keys. Name can be set to anything and is used // for logging messages. The Events channel is created with the specified // sizes. Upo...
{ "resource": "" }
c162507
train
// NewPolicyRepository allocates a new policy repository
{ "resource": "" }
c162508
train
// ResolveL4EgressPolicy resolves the L4 egress policy for a set of endpoints // by searching the policy repository for `PortRule` rules that are attached to // a `Rule` where the EndpointSelector matches `ctx.From`. `ctx.To` takes no effect and // is ignored in the search. If multiple `PortRule` rules are found, all ...
{ "resource": "" }
c162509
train
// ResolveCIDRPolicy resolves the L3 policy for a set of endpoints by searching // the policy repository for `CIDR` rules that are attached to a `Rule` // where the EndpointSelector matches `ctx.To`. `ctx.From` takes no effect and // is ignored in the search.
{ "resource": "" }
c162510
train
// AllowsIngressRLocked evaluates the policy repository for the provided search // context and returns the verdict for ingress. If no matching policy allows for // the connection, the request will be denied. The policy repository mutex must // be held.
{ "resource": "" }
c162511
train
// AllowsEgressRLocked evaluates the policy repository for the provided search // context and returns the verdict. If no matching policy allows for the // connection, the request will be denied. The policy repository mutex must be // held.
{ "resource": "" }
c162512
train
// SearchRLocked searches the policy repository for rules which match the // specified labels and will return an array of all rules which matched.
{ "resource": "" }
c162513
train
// AddListLocked inserts a rule into the policy repository with the repository already locked // Expects that the entire rule list has already been sanitized.
{ "resource": "" }
c162514
train
// removeIdentityFromRuleCaches removes the identity from the selector cache // in each rule in the repository. // // Returns a sync.WaitGroup that blocks until the policy operation is complete. // The repository read lock must be held until the waitgroup is complete.
{ "resource": "" }
c162515
train
// LocalEndpointIdentityRemoved handles local identity removal events to // remove references from rules in the repository to the specified identity.
{ "resource": "" }
c162516
train
// AddList inserts a rule into the policy repository. It is used for // unit-testing purposes only.
{ "resource": "" }
c162517
train
// UpdateRulesEndpointsCaches updates the caches within each rule in r that // specify whether the rule selects the endpoints in eps. If any rule matches // the endpoints, it is added to the provided IDSet, and removed from the // provided EndpointSet. The provided WaitGroup is signaled for a given endpoint // when it ...
{ "resource": "" }
c162518
train
// DeleteByLabelsLocked deletes all rules in the policy repository which // contain the specified labels. Returns the revision of the policy repository // after deleting the rules, as well as now many rules were deleted.
{ "resource": "" }
c162519
train
// DeleteByLabels deletes all rules in the policy repository which contain the // specified labels
{ "resource": "" }
c162520
train
// JSONMarshalRules returns a slice of policy rules as string in JSON // representation
{ "resource": "" }
c162521
train
// GetJSON returns all rules of the policy repository as string in JSON // representation
{ "resource": "" }
c162522
train
// GetRulesMatching returns whether any of the rules in a repository contain a // rule with labels matching the labels in the provided LabelArray. // // Must be called with p.Mutex held
{ "resource": "" }
c162523
train
// getMatchingRules returns whether any of the rules in a repository contain a // rule with labels matching the labels in the provided LabelArray, as well as // a slice of all rules which match. // // Must be called with p.Mutex held
{ "resource": "" }
c162524
train
// Empty returns 'true' if repository has no rules, 'false' otherwise. // // Must be called without p.Mutex held
{ "resource": "" }
c162525
train
// TranslateRules traverses rules and applies provided translator to rules
{ "resource": "" }
c162526
train
// BumpRevision allows forcing policy regeneration
{ "resource": "" }
c162527
train
// GetRulesList returns the current policy
{ "resource": "" }
c162528
train
// ResolvePolicyLocked returns the EndpointPolicy for the provided set of // labels against the set of rules in the repository, and the provided set of // identities. If the policy cannot be generated due to conflicts at L4 or L7, // returns an error. // // Must be performed while holding the Repository lock.
{ "resource": "" }
c162529
train
// computePolicyEnforcementAndRules returns whether policy applies at ingress or ingress // for the given set of labels, as well as a list of any rules which select // the set of labels. // // Must be called with repo mutex held for reading.
{ "resource": "" }
c162530
train
// NewGetIdentityID creates a new http.Handler for the get identity ID operation
{ "resource": "" }
c162531
train
// AddReservedIdentity adds the reserved numeric identity with the respective // label into the map of reserved identity cache.
{ "resource": "" }
c162532
train
// NewPutEndpointID creates a new http.Handler for the put endpoint ID operation
{ "resource": "" }
c162533
train
// NewCiliumHealthAPI creates a new CiliumHealth instance
{ "resource": "" }
c162534
train
// Validate validates the registrations in the CiliumHealthAPI
{ "resource": "" }
c162535
train
// Context returns the middleware context for the cilium health API
{ "resource": "" }
c162536
train
// ToNetwork converts CtKey4 ports to network byte order.
{ "resource": "" }
c162537
train
// Lookup opens a conntrack map if necessary, and does a lookup on it with a key constructed from // the parameters // 'epname' is a 5-digit represenation of the endpoint ID if local maps // are to be used, or "global" if global maps should be used.
{ "resource": "" }
c162538
train
// CloseLocalMaps closes all local conntrack maps opened previously // for lookup with the given 'mapname'.
{ "resource": "" }
c162539
train
// portRulesCoverContext determines whether L4 portions of rules cover the // specified port models. // // Returns true if the list of ports is 0, or the rules match the ports.
{ "resource": "" }
c162540
train
// resolveCIDRPolicy inserts the CIDRs from the specified rule into result if // the rule corresponds to the current SearchContext. It returns the resultant // CIDRPolicy containing the added ingress and egress CIDRs. If no CIDRs are // added to result, a nil CIDRPolicy is returned.
{ "resource": "" }
c162541
train
// canReachIngress returns the decision as to whether the set of labels specified // in ctx.From match with the label selectors specified in the ingress rules // contained within r.
{ "resource": "" }
c162542
train
// meetsRequirementsIngress returns whether the labels in ctx.From do not // meet the requirements in the provided rule. If a rule does meet the // requirements in the rule, that does not mean that the rule allows traffic // from the labels in ctx.From, merely that the rule does not deny it.
{ "resource": "" }
c162543
train
// meetsRequirementsEgress returns whether the labels in ctx.To do not // meet the requirements in the provided rule. If a rule does meet the // requirements in the rule, that does not mean that the rule allows traffic // from the labels in ctx.To, merely that the rule does not deny it.
{ "resource": "" }
c162544
train
// String returns the decision in human readable format
{ "resource": "" }
c162545
train
// UnmarshalJSON parses a JSON formatted buffer and returns a decision
{ "resource": "" }
c162546
train
// MarshalJSON returns the decision as JSON formatted buffer
{ "resource": "" }
c162547
train
// SetSocketOptions set's up 'conn' to be used with a SessionUDP.
{ "resource": "" }
c162548
train
// InitPool initializes a pool of buffers to be used with SessionUDP.
{ "resource": "" }
c162549
train
// ReadRequest reads a single request from 'conn' and returns the request context
{ "resource": "" }
c162550
train
// Discard returns 's' to the factory pool
{ "resource": "" }
c162551
train
// WriteResponse writes a response to a request received earlier
{ "resource": "" }
c162552
train
// parseDstFromOOB takes oob data and returns the destination IP.
{ "resource": "" }
c162553
train
// correctSource returns the oob data with the given source address
{ "resource": "" }
c162554
train
// ParseProxyID parses a proxy ID returned by ProxyID and returns its components.
{ "resource": "" }
c162555
train
// contains checks if the given `s` statusLogMsg is present in the // priorityStatus.
{ "resource": "" }
c162556
train
// sortByPriority returns a statusLog ordered from highest priority to lowest.
{ "resource": "" }
c162557
train
// getAndIncIdx returns current free slot index and increments the index to the // next index that can be overwritten.
{ "resource": "" }
c162558
train
// Context returns the middleware context for the cilium API
{ "resource": "" }
c162559
train
// UnmarshalBinary decodes the metadata from its binary representation.
{ "resource": "" }
c162560
train
// MarshalBinary encodes the metadata into its binary representation.
{ "resource": "" }
c162561
train
// ReadBinary reads the metadata from its binary representation.
{ "resource": "" }
c162562
train
// WriteBinary writes the metadata into its binary representation.
{ "resource": "" }
c162563
train
// Decode decodes the payload from its binary representation.
{ "resource": "" }
c162564
train
// Encode encodes the payload into its binary representation.
{ "resource": "" }
c162565
train
// ReadBinary reads the payload from its binary representation.
{ "resource": "" }
c162566
train
// WriteBinary writes the payload into its binary representation.
{ "resource": "" }
c162567
train
// EncodeBinary writes the payload into its binary representation.
{ "resource": "" }
c162568
train
// DecodeBinary reads the payload from its binary representation.
{ "resource": "" }
c162569
train
// ReadMetaPayload reads a Meta and Payload from a Cilium monitor connection.
{ "resource": "" }
c162570
train
// WriteMetaPayload writes a Meta and Payload into a Cilium monitor connection. // meta.Size is set to the size of the encoded Payload.
{ "resource": "" }
c162571
train
// BuildMessage builds the binary message to be sent and returns it
{ "resource": "" }
c162572
train
// Endpoint2IfName returns the host interface name for the given endpointID.
{ "resource": "" }
c162573
train
// WriteSysConfig tries to emulate a sysctl call by writing directly to the // given fileName the given value.
{ "resource": "" }
c162574
train
// GetNetInfoFromPID returns the index of the interface parent, the MAC address // and IP address of the first interface that contains an IP address with global // scope.
{ "resource": "" }
c162575
train
// Validate validates this debug info
{ "resource": "" }
c162576
train
// allocate creates an entry for key in localKeys if needed and increments the // refcnt. The value associated with the key must match the local cache or an // error is returned
{ "resource": "" }
c162577
train
// lookupID returns the key for a given ID or an empty string
{ "resource": "" }
c162578
train
// use increments the refcnt of the key and returns its value
{ "resource": "" }
c162579
train
// release releases the refcnt of a key. When the last reference was released, // the key is deleted and the returned lastUse value is true.
{ "resource": "" }
c162580
train
// Copy duplicates the hash and returns the copy.
{ "resource": "" }
c162581
train
// WithPayload adds the payload to the post Ip a m created response
{ "resource": "" }
c162582
train
// WithPayload adds the payload to the post Ip a m failure response
{ "resource": "" }
c162583
train
// GetPrefilter returns a list of all CIDR prefixes
{ "resource": "" }
c162584
train
// PatchPrefilter sets a list of CIDR prefixes
{ "resource": "" }
c162585
train
// DeletePrefilter deletes a list of CIDR prefixes
{ "resource": "" }
c162586
train
// WithTimeout adds the timeout to the get config params
{ "resource": "" }
c162587
train
// WithContext adds the context to the get config params
{ "resource": "" }
c162588
train
// WithHTTPClient adds the HTTPClient to the get config params
{ "resource": "" }
c162589
train
// WithPayload adds the payload to the get fqdn cache Id o k response
{ "resource": "" }
c162590
train
// WithPayload adds the payload to the get fqdn cache Id bad request response
{ "resource": "" }
c162591
train
// Validate ensures that pattern is a parseable matchPattern. It returns the // regexp generated when validating.
{ "resource": "" }
c162592
train
// Sanitize canonicalized the pattern for use by ToRegexp
{ "resource": "" }
c162593
train
// NewCIDR returns a new CIDR using a net.IPNet
{ "resource": "" }
c162594
train
// DeepCopy creates a deep copy of a CIDR
{ "resource": "" }
c162595
train
// ParseCIDR parses the CIDR string using net.ParseCIDR
{ "resource": "" }
c162596
train
// MustParseCIDR parses the CIDR string using net.ParseCIDR and panics if the // CIDR cannot be parsed
{ "resource": "" }
c162597
train
// WithTimeout adds the timeout to the get prefilter params
{ "resource": "" }
c162598
train
// WithContext adds the context to the get prefilter params
{ "resource": "" }
c162599
train
// WithHTTPClient adds the HTTPClient to the get prefilter params
{ "resource": "" }