_id
stringlengths
2
7
title
stringclasses
1 value
partition
stringclasses
3 values
text
stringlengths
6
2.61k
language
stringclasses
1 value
meta_information
dict
c4400
train
// Manifold returns a dependency.Manifold that will run an apiserver-based // raft transport worker.
{ "resource": "" }
c4401
train
// APIRequestDuration indicates an expected call of APIRequestDuration
{ "resource": "" }
c4402
train
// DeprecatedAPIRequestDuration mocks base method
{ "resource": "" }
c4403
train
// DeprecatedAPIRequestsTotal mocks base method
{ "resource": "" }
c4404
train
// NewMockCounterVec creates a new mock instance
{ "resource": "" }
c4405
train
// NewMockSummaryVec creates a new mock instance
{ "resource": "" }
c4406
train
// processPost handles resources upload POST request after // authentication.
{ "resource": "" }
c4407
train
// DialInfo returns information on how to dial // the state's mongo server with the given info // and dial options.
{ "resource": "" }
c4408
train
// DialWithInfo establishes a new session to the cluster identified by info, // with the specified options. If either Tag or Password are specified, then // a Login call on the admin database will be made.
{ "resource": "" }
c4409
train
// Login logs in to the mongodb admin database.
{ "resource": "" }
c4410
train
// MaybeUnauthorizedf checks if the cause of the given error is a Mongo // authorization error, and if so, wraps the error with errors.Unauthorizedf.
{ "resource": "" }
c4411
train
// VolumeSource is defined on storage.Provider.
{ "resource": "" }
c4412
train
// FilesystemSource is defined on storage.Provider.
{ "resource": "" }
c4413
train
// ValidateConfig is defined on storage.Provider.
{ "resource": "" }
c4414
train
// Supports is defined on storage.Provider.
{ "resource": "" }
c4415
train
// Scope is defined on storage.Provider.
{ "resource": "" }
c4416
train
// DefaultPool is defined on storage.Provider.
{ "resource": "" }
c4417
train
// NewMockRbacV1Interface creates a new mock instance
{ "resource": "" }
c4418
train
// ClusterRoleBindings mocks base method
{ "resource": "" }
c4419
train
// ClusterRoles mocks base method
{ "resource": "" }
c4420
train
// RoleBindings mocks base method
{ "resource": "" }
c4421
train
// RoleBindings indicates an expected call of RoleBindings
{ "resource": "" }
c4422
train
// Roles mocks base method
{ "resource": "" }
c4423
train
// NewMockClusterRoleBindingInterface creates a new mock instance
{ "resource": "" }
c4424
train
// NewMockClusterRoleInterface creates a new mock instance
{ "resource": "" }
c4425
train
// NewMockDatabase creates a new mock instance
{ "resource": "" }
c4426
train
// Copy mocks base method
{ "resource": "" }
c4427
train
// CopyForModel mocks base method
{ "resource": "" }
c4428
train
// GetCollectionFor mocks base method
{ "resource": "" }
c4429
train
// GetRawCollection mocks base method
{ "resource": "" }
c4430
train
// RunRawTransaction indicates an expected call of RunRawTransaction
{ "resource": "" }
c4431
train
// RunTransactionFor mocks base method
{ "resource": "" }
c4432
train
// Schema mocks base method
{ "resource": "" }
c4433
train
// TransactionRunner mocks base method
{ "resource": "" }
c4434
train
// TransactionRunner indicates an expected call of TransactionRunner
{ "resource": "" }
c4435
train
// Encode signs the data returned by the reader and returns an inline signed copy.
{ "resource": "" }
c4436
train
// BridgeEthernetById takes a deviceId and creates a bridge with this device // using this devices config
{ "resource": "" }
c4437
train
// BridgeVLANById takes a deviceId and creates a bridge with this device // using this devices config
{ "resource": "" }
c4438
train
// BridgeBondById takes a deviceId and creates a bridge with this device // using this devices config
{ "resource": "" }
c4439
train
// shouldCreateBridge returns true only if it is clear the bridge doesn't already exist, and that the existing device // isn't in a different bridge.
{ "resource": "" }
c4440
train
// createBridgeFromInterface will create a bridge stealing the interface details, and wiping the existing interface // except for MTU so that IP Address information is never duplicated.
{ "resource": "" }
c4441
train
// ReadDirectory reads the contents of a netplan directory and // returns complete config.
{ "resource": "" }
c4442
train
// Write writes merged netplan yaml to file specified by path. If path is empty filename is autogenerated
{ "resource": "" }
c4443
train
// Rollback moves backed up files to original locations and removes written file
{ "resource": "" }
c4444
train
// FindDeviceByMACOrName will look for an Ethernet, VLAN or Bond matching the Name of the device or its MAC address. // Name is preferred to MAC address.
{ "resource": "" }
c4445
train
// NewModelWatcher returns a new ModelWatcher. Active watchers // will be stored in the provided Resources. The two GetAuthFunc // callbacks will be used on each invocation of the methods to // determine current permissions. // Right now, model tags are not used, so both created AuthFuncs // are called with "" for tag,...
{ "resource": "" }
c4446
train
// WatchForModelConfigChanges returns a NotifyWatcher that observes // changes to the model configuration. // Note that although the NotifyWatchResult contains an Error field, // it's not used because we are only returning a single watcher, // so we use the regular error return.
{ "resource": "" }
c4447
train
// ModelConfig returns the current model's configuration.
{ "resource": "" }
c4448
train
// recoverViaBootstrap re-initializes the raft cluster. This should only be // used in the case that the raft directory has been completely wiped.
{ "resource": "" }
c4449
train
// NewStateApplication converts a state.Application into an Application.
{ "resource": "" }
c4450
train
// stateStepsFor21 returns upgrade steps for Juju 2.1 that manipulate state directly.
{ "resource": "" }
c4451
train
// NewContext returns a new hooks.ContextComponent for payloads.
{ "resource": "" }
c4452
train
// NewContextAPI returns a new hooks.ContextComponent for payloads.
{ "resource": "" }
c4453
train
// ContextComponent returns the hook context for the payload // payload component.
{ "resource": "" }
c4454
train
// Get returns the payload info corresponding to the given ID.
{ "resource": "" }
c4455
train
// List returns the sorted names of all registered payloads.
{ "resource": "" }
c4456
train
// Track records the payload info in the hook context.
{ "resource": "" }
c4457
train
// Untrack tells juju to stop tracking this payload.
{ "resource": "" }
c4458
train
// SetStatus sets the identified payload's status.
{ "resource": "" }
c4459
train
// NewAPI creates a new client-side machine undertaker facade.
{ "resource": "" }
c4460
train
// AllMachineRemovals returns all the machines that have been marked // ready to clean up.
{ "resource": "" }
c4461
train
// GetProviderInterfaceInfo gets the provider details for all of the // interfaces for one machine.
{ "resource": "" }
c4462
train
// CompleteRemoval finishes the removal of the machine in the database // after any provider resources are cleaned up.
{ "resource": "" }
c4463
train
// WatchMachineRemovals registers to be notified when a machine // removal is requested.
{ "resource": "" }
c4464
train
// AddBranch adds a new branch to the model.
{ "resource": "" }
c4465
train
// CommitBranch commits the branch with the input name to the model, // effectively completing it and applying all branch changes across the model. // The new generation ID of the model is returned.
{ "resource": "" }
c4466
train
// HasActiveBranch returns true if the model has an // "in-flight" branch with the input name.
{ "resource": "" }
c4467
train
// BranchInfo returns information about "in-flight" branches. // If a non-empty string is supplied for branch name, // then only information for that branch is returned. // Supplying true for detailed returns extra unit detail for the branch.
{ "resource": "" }
c4468
train
// Name returns the name of the service stored in enumService.
{ "resource": "" }
c4469
train
// CreateService wraps Mgr.CreateService method.
{ "resource": "" }
c4470
train
// CreateService wraps Mgr.OpenService method. It returns a windowsService object. // This allows us to stub out this module for testing.
{ "resource": "" }
c4471
train
// CloseHandle wraps the windows.CloseServiceHandle method. // This allows us to stub out this module for testing.
{ "resource": "" }
c4472
train
// Start starts a service.
{ "resource": "" }
c4473
train
// Stop stops a service.
{ "resource": "" }
c4474
train
// Delete deletes a service.
{ "resource": "" }
c4475
train
// Running returns the status of a service.
{ "resource": "" }
c4476
train
// Config returns the mgr.Config of the service. This config reflects the actual // service configuration in Windows.
{ "resource": "" }
c4477
train
// ChangeServicePassword can change the password of a service // as long as it belongs to the user defined in this package
{ "resource": "" }
c4478
train
// Upgrade upgrades the operator for the specified agent tag to v.
{ "resource": "" }
c4479
train
// cacheZones populates the allZones and availableZones cache, if it's // empty.
{ "resource": "" }
c4480
train
// AddSubnets adds.
{ "resource": "" }
c4481
train
// NewStorage returns a Storage for the model with the specified UUID.
{ "resource": "" }
c4482
train
// resourceName returns the string to use for a resource's Name tag, // to help users identify Juju-managed resources in the AWS console.
{ "resource": "" }
c4483
train
// runInstances calls ec2.RunInstances for a fixed number of attempts until // RunInstances returns an error code that does not indicate an error that // may be caused by eventual consistency.
{ "resource": "" }
c4484
train
// groupInfoByName returns information on the security group // with the given name including rules and other details.
{ "resource": "" }
c4485
train
// groupByName returns the security group with the given name.
{ "resource": "" }
c4486
train
// gatherInstances tries to get information on each instance // id whose corresponding insts slot is nil. // // This function returns environs.ErrPartialInstances if the // insts slice has not been completely filled.
{ "resource": "" }
c4487
train
// NetworkInterfaces implements NetworkingEnviron.NetworkInterfaces.
{ "resource": "" }
c4488
train
// Spaces is not implemented by the ec2 provider as we don't currently have // provider level spaces.
{ "resource": "" }
c4489
train
// Subnets returns basic information about the specified subnets known // by the provider for the specified instance or list of ids. subnetIds can be // empty, in which case all known are returned. Implements // NetworkingEnviron.Subnets.
{ "resource": "" }
c4490
train
// AllInstances is part of the environs.InstanceBroker interface.
{ "resource": "" }
c4491
train
// AllInstancesByState returns all instances in the environment // with one of the specified instance states.
{ "resource": "" }
c4492
train
// allControllerManagedInstances returns the IDs of all instances managed by // this environment's controller. // // Note that this requires that all instances are tagged; we cannot filter on // security groups, as we do not know the names of the models.
{ "resource": "" }
c4493
train
// destroyControllerManagedEnvirons destroys all environments managed by this // environment's controller.
{ "resource": "" }
c4494
train
// controllerSecurityGroups returns the details of all security groups managed // by the environment's controller.
{ "resource": "" }
c4495
train
// cleanEnvironmentSecurityGroups attempts to delete all security groups owned // by the environment.
{ "resource": "" }
c4496
train
// setUpGroups creates the security groups for the new machine, and // returns them. // // Instances are tagged with a group so they can be distinguished from // other instances that might be running on the same EC2 account. In // addition, a specific machine security group is created for each // machine, so that its ...
{ "resource": "" }
c4497
train
// newPermSetForGroup returns a set of all the permissions in the // given slice of IPPerms. It ignores the name and owner // id in source groups, and any entry with no source ips will // be granted for the given group only.
{ "resource": "" }
c4498
train
// ipPerms returns m as a slice of permissions usable // with the ec2 package.
{ "resource": "" }
c4499
train
// isZoneConstrainedError reports whether or not the error indicates // RunInstances failed due to the specified availability zone being // constrained for the instance type being provisioned, or is // otherwise unusable for the specific request made.
{ "resource": "" }