_id stringlengths 2 7 | title stringclasses 1
value | partition stringclasses 3
values | text stringlengths 6 2.61k | language stringclasses 1
value | meta_information dict |
|---|---|---|---|---|---|
c4100 | train | // unpinLeaders unpins leadership for applications
// represented by units running on this machine. | {
"resource": ""
} | ||
c4101 | train | // Unit services returns a map of unit agent service names,
// keyed on their unit IDs. | {
"resource": ""
} | ||
c4102 | train | // unitNames returns a comma-delimited string of unit names based on the input
// map of unit agent services. | {
"resource": ""
} | ||
c4103 | train | // NewEndpointPath returns the API URL path for the identified resource. | {
"resource": ""
} | ||
c4104 | train | // ExtractEndpointDetails pulls the endpoint wildcard values from
// the provided URL. | {
"resource": ""
} | ||
c4105 | train | // SendHTTPStatusAndJSON sends an HTTP status code and
// a JSON-encoded response to a client. | {
"resource": ""
} | ||
c4106 | train | // NewWorker returns a worker that unlocks the model upgrade gate. | {
"resource": ""
} | ||
c4107 | train | // NewAPI returns a new charm annotator API facade. | {
"resource": ""
} | ||
c4108 | train | // Get returns annotations for given entities.
// If annotations cannot be retrieved for a given entity, an error is returned.
// Each entity is treated independently and, hence, will fail or succeed independently. | {
"resource": ""
} | ||
c4109 | train | // Set stores annotations for given entities | {
"resource": ""
} | ||
c4110 | train | // UpgradeSeriesPrepare is the interface to the API server endpoint of the same
// name. Since this function's interface will be mocked as an external test
// dependency this function should contain minimal logic other than gathering an
// API handle and making the API call. | {
"resource": ""
} | ||
c4111 | train | // displayNotifications handles the writing of upgrade series notifications to
// standard out. | {
"resource": ""
} | ||
c4112 | train | // UpgradeSeriesComplete completes a series upgrade for a given machine,
// that is if a machine is marked as upgrading using UpgradeSeriesPrepare,
// then this command will complete that process and the machine will no longer
// be marked as upgrading. | {
"resource": ""
} | ||
c4113 | train | // Status returns the status of the unit agent. | {
"resource": ""
} | ||
c4114 | train | // SetStatus sets the status of the unit agent. The optional values
// allow to pass additional helpful status data. | {
"resource": ""
} | ||
c4115 | train | // Path returns the qualified name of the network. | {
"resource": ""
} | ||
c4116 | train | // newInterface builds up all the data needed by the GCE API to create
// a new interface connected to the network. | {
"resource": ""
} | ||
c4117 | train | // firewallSpec expands a port range set in to compute.FirewallAllowed
// and returns a compute.Firewall for the provided name. | {
"resource": ""
} | ||
c4118 | train | // ModelStatus returns a summary of the model. | {
"resource": ""
} | ||
c4119 | train | // ModelFilesystemInfo returns information about filesystems in the model. | {
"resource": ""
} | ||
c4120 | train | // ModelVolumeInfo returns information about volumes in the model. | {
"resource": ""
} | ||
c4121 | train | // NewRelationIdValue returns a gnuflag.Value for convenient parsing of relation
// ids in ctx. | {
"resource": ""
} | ||
c4122 | train | // Set interprets value as a relation id, if possible, and returns an error
// if it is not known to the system. The parsed relation id will be written
// to v.result. | {
"resource": ""
} | ||
c4123 | train | // FriendlyDuration renders a time pointer that we get from the API as
// a friendly string. | {
"resource": ""
} | ||
c4124 | train | // ModelInfoFromParams translates a params.ModelInfo to ModelInfo. | {
"resource": ""
} | ||
c4125 | train | // OwnerQualifiedModelName returns the model name qualified with the
// model owner if the owner is not the same as the given canonical
// user name. If the owner is a local user, we omit the domain. | {
"resource": ""
} | ||
c4126 | train | // NewCharmResourcesCommand returns a new command that lists resources defined
// by a charm. | {
"resource": ""
} | ||
c4127 | train | // ListCharmResources implements CharmResourceLister by getting the charmstore client
// from the command's ModelCommandBase. | {
"resource": ""
} | ||
c4128 | train | // body of generic pruner loop | {
"resource": ""
} | ||
c4129 | train | // finalizeConfig creates the config object from attributes,
// and calls EnvironProvider.PrepareConfig. | {
"resource": ""
} | ||
c4130 | train | // Provision returns a new machineId and nil if the provision process is done successfully
// The func will manual provision a linux machine using as it's default protocol SSH | {
"resource": ""
} | ||
c4131 | train | // NewCredentialInvalidatorFacade creates an API facade capable of invalidating credential. | {
"resource": ""
} | ||
c4132 | train | // NewCloudCallContext creates a cloud call context to be used by workers. | {
"resource": ""
} | ||
c4133 | train | // NewDisableCommand returns a disable-command command instance
// that will use the default API. | {
"resource": ""
} | ||
c4134 | train | // NewDeployerAPI creates a new server-side DeployerAPI facade. | {
"resource": ""
} | ||
c4135 | train | // SetStatus sets the status of the specified entities. | {
"resource": ""
} | ||
c4136 | train | // getAllUnits returns a list of all principal and subordinate units
// assigned to the given machine. | {
"resource": ""
} | ||
c4137 | train | // NewRestoreCommand returns a command used to restore a backup. | {
"resource": ""
} | ||
c4138 | train | // SetFlags handles known option flags. | {
"resource": ""
} | ||
c4139 | train | // Init is where the preconditions for this command can be checked. | {
"resource": ""
} | ||
c4140 | train | // Run is the entry point for this command. | {
"resource": ""
} | ||
c4141 | train | // NewWorker creates a new agent config updater worker. | {
"resource": ""
} | ||
c4142 | train | // SingularClaimer returns a lease.Claimer representing the exclusive right to
// manage the model. | {
"resource": ""
} | ||
c4143 | train | // counterpartRole returns the RelationRole that this RelationRole
// can relate to.
// This should remain an internal method because the relation
// model does not guarantee that for every role there will
// necessarily exist a single counterpart role that is sensible
// for basing algorithms upon. | {
"resource": ""
} | ||
c4144 | train | // CanRelateTo returns whether a relation may be established between e and other. | {
"resource": ""
} | ||
c4145 | train | // NewStateFirewallerAPIV3 creates a new server-side FirewallerAPIV3 facade. | {
"resource": ""
} | ||
c4146 | train | // NewStateFirewallerAPIV4 creates a new server-side FirewallerAPIV4 facade. | {
"resource": ""
} | ||
c4147 | train | // NewStateFirewallerAPIV5 creates a new server-side FirewallerAPIV5 facade. | {
"resource": ""
} | ||
c4148 | train | // NewFirewallerAPI creates a new server-side FirewallerAPIV3 facade. | {
"resource": ""
} | ||
c4149 | train | // WatchOpenedPorts returns a new StringsWatcher for each given
// model tag. | {
"resource": ""
} | ||
c4150 | train | // GetMachinePorts returns the port ranges opened on a machine for the specified
// subnet as a map mapping port ranges to the tags of the units that opened
// them. | {
"resource": ""
} | ||
c4151 | train | // GetExposed returns the exposed flag value for each given application. | {
"resource": ""
} | ||
c4152 | train | // WatchIngressAddressesForRelations creates a watcher that returns the ingress networks
// that have been recorded against the specified relations. | {
"resource": ""
} | ||
c4153 | train | // MacaroonForRelations returns the macaroon for the specified relations. | {
"resource": ""
} | ||
c4154 | train | // SetRelationsStatus sets the status for the specified relations. | {
"resource": ""
} | ||
c4155 | train | // FirewallRules returns the firewall rules for the specified well known service types. | {
"resource": ""
} | ||
c4156 | train | // NewDBInfo returns the information needed by backups to dump
// the database. | {
"resource": ""
} | ||
c4157 | train | // NewDBDumper returns a new value with a Dump method for dumping the
// juju state database. | {
"resource": ""
} | ||
c4158 | train | // Dump dumps the juju state-related databases. To do this we dump all
// databases and then remove any ignored databases from the dump results. | {
"resource": ""
} | ||
c4159 | train | // listDatabases returns the name of each sub-directory of the dump
// directory. Each corresponds to a database dump generated by
// mongodump. Note that, while mongodump is unlikely to change behavior
// in this regard, this is not a documented guaranteed behavior. | {
"resource": ""
} | ||
c4160 | train | // NewDBRestorer returns a new structure that can perform a restore
// on the db pointed in dialInfo. | {
"resource": ""
} | ||
c4161 | train | // ensureOplogPermissions adds a special role to the admin user, this role
// is required by mongorestore when doing oplogreplay. | {
"resource": ""
} | ||
c4162 | train | // NewUniter creates a new Uniter which will install, run, and upgrade
// a charm on behalf of the unit with the given unitTag, by executing
// hooks and operations provoked by changes in st. | {
"resource": ""
} | ||
c4163 | train | // StartUniter creates a new Uniter and starts it using the specified runner. | {
"resource": ""
} | ||
c4164 | train | // stopUnitError returns the error to use when exiting from stopping the unit.
// For IAAS models, we want to terminate the agent, as each unit is run by
// an individual agent for that unit. | {
"resource": ""
} | ||
c4165 | train | // acquireExecutionLock acquires the machine-level execution lock, and
// returns a func that must be called to unlock it. It's used by operation.Executor
// when running operations that execute external code. | {
"resource": ""
} | ||
c4166 | train | // ReadLegacyCloudCredentials reads cloud credentials off disk for an old
// LXD controller, and returns them as a cloud.Credential with the
// certificate auth-type.
//
// If the credential files are missing from the filesystem, an error
// satisfying errors.IsNotFound will be returned. | {
"resource": ""
} | ||
c4167 | train | // ValidateExistingModelCredential checks if the cloud credential that a given model uses is valid for it. | {
"resource": ""
} | ||
c4168 | train | // ValidateNewModelCredential checks if a new cloud credential could be valid for a given model. | {
"resource": ""
} | ||
c4169 | train | // checkMachineInstances compares model machines from state with
// the ones reported by the provider using supplied credential.
// This only makes sense for non-k8s providers. | {
"resource": ""
} | ||
c4170 | train | // BootstrapEnv bootstraps the Juju environment. | {
"resource": ""
} | ||
c4171 | train | // DestroyEnv destroys the Juju environment. | {
"resource": ""
} | ||
c4172 | train | // addPackageCommandsCommon is a helper function which applies the given
// packaging-related options to the given CloudConfig. | {
"resource": ""
} | ||
c4173 | train | // renderScriptCommon is a helper function which generates a bash script that
// applies all the settings given by the provided CloudConfig when run. | {
"resource": ""
} | ||
c4174 | train | // restrictRoot wraps the provided root so that the check function is
// called on all method lookups. If the check returns an error the API
// call is blocked. | {
"resource": ""
} | ||
c4175 | train | // FindMethod implements rpc.Root. | {
"resource": ""
} | ||
c4176 | train | // restrictAll blocks all API requests, returned a fixed error. | {
"resource": ""
} | ||
c4177 | train | // osVal will lookup the value of the key valname
// in the appropriate map, based on the series. This will
// help reduce boilerplate code | {
"resource": ""
} | ||
c4178 | train | // makeWatcherAPICaller creates a watcherAPICall function for a given facade name
// and watcherId. | {
"resource": ""
} | ||
c4179 | train | // init must be called to initialize an embedded commonWatcher's
// fields. Make sure newResult and call fields are set beforehand. | {
"resource": ""
} | ||
c4180 | train | // commonLoop implements the loop structure common to the client
// watchers. It should be started in a separate goroutine by any
// watcher that embeds commonWatcher. It kills the commonWatcher's
// tomb when an error occurs. | {
"resource": ""
} | ||
c4181 | train | // If an API call returns a NotifyWatchResult, you can use this to turn it into
// a local Watcher. | {
"resource": ""
} | ||
c4182 | train | // NewRelationStatusWatcher returns a watcher notifying of changes to
// relation life and suspended status. | {
"resource": ""
} | ||
c4183 | train | // NewOfferStatusWatcher returns a watcher notifying of changes to
// offer status. | {
"resource": ""
} | ||
c4184 | train | // NewVolumeAttachmentsWatcher returns a MachineStorageIdsWatcher which
// communicates with the VolumeAttachmentsWatcher API facade to watch
// volume attachments. | {
"resource": ""
} | ||
c4185 | train | // NewMigrationStatusWatcher takes the NotifyWatcherId returns by the
// MigrationSlave.Watch API and returns a watcher which will report
// status changes for any migration of the model associated with the
// API connection. | {
"resource": ""
} | ||
c4186 | train | // BridgeAndActivate will parse a set of netplan yaml files in a directory,
// create a new netplan config with the provided interfaces bridged
// bridged, then reconfigure the network using the ifupdown package
// for the new bridges. | {
"resource": ""
} | ||
c4187 | train | // New returns a Pollster that wraps the given reader and writer. | {
"resource": ""
} | ||
c4188 | train | // Select queries the user to select from the given list of options. | {
"resource": ""
} | ||
c4189 | train | // SelectVerify queries the user to select from the given list of options,
// verifying the choice by passing responses through verify. | {
"resource": ""
} | ||
c4190 | train | // Enter requests that the user enter a value. Any value except an empty string
// is accepted. | {
"resource": ""
} | ||
c4191 | train | // EnterPassword works like Enter except that if the pollster's input wraps a
// terminal, the user's input will be read without local echo. | {
"resource": ""
} | ||
c4192 | train | // EnterDefault requests that the user enter a value. Any value is accepted.
// An empty string is treated as defVal. | {
"resource": ""
} | ||
c4193 | train | // EnterOptional requests that the user enter a value. It accepts any value,
// even an empty string. | {
"resource": ""
} | ||
c4194 | train | // EnterVerifyDefault requests that the user enter a value. Values failing to
// verify will be rejected with the error message returned by verify. An empty
// string will be accepted as the default value even if it would fail
// verification. | {
"resource": ""
} | ||
c4195 | train | // VerifyOptions is the verifier used by pollster.Select. | {
"resource": ""
} | ||
c4196 | train | // names returns the list of names of schema in alphabetical order. | {
"resource": ""
} | ||
c4197 | train | // convert converts the given string to a specific value based on the schema
// type that validated it. | {
"resource": ""
} | ||
c4198 | train | // NewUnitAgent creates a new UnitAgent value properly initialized. | {
"resource": ""
} | ||
c4199 | train | // Done signals the unit agent is finished | {
"resource": ""
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.