open-nomad/jobspec
Danielle Lancashire 426c26d7c0 CSI Plugin Registration (#6555)
This changeset implements the initial registration and fingerprinting
of CSI Plugins as part of #5378. At a high level, it introduces the
following:

* A `csi_plugin` stanza as part of a Nomad task configuration, to
  allow a task to expose that it is a plugin.

* A new task runner hook: `csi_plugin_supervisor`. This hook does two
  things. When the `csi_plugin` stanza is detected, it will
  automatically configure the plugin task to receive bidirectional
  mounts to the CSI intermediary directory. At runtime, it will then
  perform an initial heartbeat of the plugin and handle submitting it to
  the new `dynamicplugins.Registry` for further use by the client, and
  then run a lightweight heartbeat loop that will emit task events
  when health changes.

* The `dynamicplugins.Registry` for handling plugins that run
  as Nomad tasks, in contrast to the existing catalog that requires
  `go-plugin` type plugins and to know the plugin configuration in
  advance.

* The `csimanager` which fingerprints CSI plugins, in a similar way to
  `drivermanager` and `devicemanager`. It currently only fingerprints
  the NodeID from the plugin, and assumes that all plugins are
  monolithic.

Missing features

* We do not use the live updates of the `dynamicplugin` registry in
  the `csimanager` yet.

* We do not deregister the plugins from the client when they shutdown
  yet, they just become indefinitely marked as unhealthy. This is
  deliberate until we figure out how we should manage deploying new
  versions of plugins/transitioning them.
2020-03-23 13:58:28 -04:00
..
test-fixtures CSI Plugin Registration (#6555) 2020-03-23 13:58:28 -04:00
parse.go core: add semver constraint 2019-11-19 08:40:19 -08:00
parse_group.go shutdown delay for task groups 2019-12-16 11:38:16 -05:00
parse_job.go command, docs: create and document consul token configuration for connect acls (gh-6716) 2020-01-31 19:02:53 -06:00
parse_network.go quota: parse network stanza in quotas (#6511) 2019-10-24 10:41:54 -04:00
parse_service.go client: enable configuring enable_tag_override for services 2020-02-10 08:00:55 -06:00
parse_task.go CSI Plugin Registration (#6555) 2020-03-23 13:58:28 -04:00
parse_test.go CSI Plugin Registration (#6555) 2020-03-23 13:58:28 -04:00
utils.go consul: add Connect structs 2019-08-06 08:15:07 -07:00
utils_test.go consul: add Connect structs 2019-08-06 08:15:07 -07:00