top of page
riddripostvidi

Plugins: The Future of Web Development and Design



Data source plugins communicate with external sources of data and return the data in a format that Grafana understands. By adding a data source plugin, you can immediately use the data in any of your existing dashboards.


Oh My Zsh comes bundled with plugins, which allow you to take advantage of functionality of many sorts to your shell just by enabling them. They areeach documented in the README file in their respective plugins/ folder.




plugins



Most syntax is transformable by Babel. In rarer cases (if the transform isn't implemented yet, or there isn't a default way to do so), you can use plugins such as @babel/plugin-syntax-bigint to only allow Babel to parse specific types of syntax. Or you want to preserve the source code because you only want Babel to do code analysis or codemods.


RabbitMQ supports plugins. Plugins extend core broker functionality in a variety of ways: with supportfor more protocols, system state monitoring, additional AMQP 0-9-1 exchange types,node federation, and more. A number of features are implemented as pluginsthat ship in the core distribution.


This guide covers the plugin mechanism and plugins that ship in the latest release of the RabbitMQ distribution.3rd party plugins can be installed separately. A set of curated plugins is also available.


The rabbitmq-plugins command enables ordisables plugins by contacting the running node to tell it tostart or stop plugins as needed. It is possible to contact an arbitrarynode -n option to specify a different node.


Having a node running before the plugins are enabled is not always practicalor operator-friendly. For those cases rabbitmq-pluginsprovides an alternative way. If the --offline flag is specified,the tool will not contact any nodes and instead will modify the file containingthe list of enabled plugins (appropriately named enabled_plugins) directly.This option is often optimal for node provisioning automation.


The enabled_plugins file is usually located in the nodedata directory or under /etc, together with configuration files. The file containsa list of plugin names ending with a dot. For example, when rabbitmq_management andrabbitmq_shovel plugins are enabled,the file contents will look like this:


Note that dependencies of plugins are not listed. Plugins with correct dependency metadatawill specify their dependencies there and they will be enabled first at the time ofplugin activation. Unlike rabbitmq-plugins disable calls against a running node,changes to the file require a node restart.


RabbitMQ loads plugins from the local filesystem. Plugins are distributed asarchives (.ez files) with compiled code modules and metadata.Since some plugins ship with RabbitMQ, everynode has at least one default plugin directory. The path varies betweenpackage types and can be overridden using theRABBITMQ_PLUGINS_DIR environment variable.Please see File and Directory Locations guide to learn about the defaultvalue on various platforms.


The built-in plugin directory is by definition version-independent: its contents will changefrom release to release. So will its exact path (by default) which contains version number,e.g. /usr/lib/rabbitmq/lib/rabbitmq_server-3.11.6/plugins. Because of thisautomated installation of 3rd party plugins into this directory is harder and more error-prone,and therefore not recommended. To solve this problem, the plugin directory can be a listof paths separated by a colon (on Linux, MacOS, BSD):


3rd party plugin directories will differ from platform to platform and installation methodto installation method. For example, /usr/lib/rabbitmq/plugins is a 3rd party plugin directorypath used by RabbitMQ Debian packages.


The first directory in the example above is the 3rd party plugin directory.The second one contains plugins that ship with RabbitMQ and will change asinstalled RabbitMQ version changes between upgrades.


The list of currently enabled plugins on a node is stored in a file.The file is commonly known as the enabled plugins file. Depending on the package typeit is usually located under the etc directory or under the node'sdata directory. Its path can be overridden using the RABBITMQ_ENABLED_PLUGINS_FILEenvironment variable. As a user you don't usually have to think about that file as it ismanaged by the node and rabbitmq-plugins (when used in --offline mode).


Deployment automation tools must make sure that the file is readable and writeable by the local RabbitMQ node.In environments that need to preconfigure plugins the file can be machine-generated at deployment time.The plugin names on the list are exactly the same as listed by rabbitmq-plugins list.


Not every plugin can be loaded from an archive .ez file.For this reason RabbitMQ will extract plugin archives on boot into a separatedirectory that is then added to its code path. This directory is knownas the expanded plugins directory. It is usually managed entirely by RabbitMQbut if node directories are changed to non-standard ones, that directory will likelyneed to be overridden, too. It can be done using the RABBITMQ_PLUGINS_EXPAND_DIRenvironment variable. The directorymust be readable and writable by the effective operating system user of the RabbitMQ node.


In some environments, in particular development ones, rabbitmq-pluginscomes from a different installation than the running server node. This can be the casewhen a node is installed using a binary build packagebut CLI tools come from the local package manager such as apt or Homebrew.


Other common reasons that prevent plugins from being enabled can include plugin archiveand/or plugin expansiondirectories permissions not having sufficient privileges for the effective user of the server node. In other words,the node cannot use those directories to complete plugin activation and loading.


When performing command discovery, CLI tools will consult the Enabled Plugins File to determinewhat plugins to scan for commands. If a plugin is not included into that file, e.g. because it was enabled implicitly asa dependency, it won't be listed in the enabled plugins file and thus its CLI commands will not be discovered.


Plugins that ship with the RabbitMQ distributions are often referredto as tier 1 plugins. Provided that a standard distribution package isused they do not need to be installed but do need to beenabled before they can be used.


In addition to the plugins bundled with the server, team RabbitMQoffers binary downloads of curated plugins which have beencontributed by authors in the community. See the community plugins page formore details.


If you're looking for an existing esbuild plugin, you should check out the list of existing esbuild plugins. Plugins on this list have been deliberately added by the author and are intended to be used by others in the esbuild community.


The callback can return without providing a path to pass on responsibility for path resolution to the next callback. For a given import path, all onResolve callbacks from all plugins will be run in the order they were registered until one takes responsibility for path resolution. If no callback returns a path, esbuild will run its default path resolution logic.


This is the verbatim unresolved path from the underlying module's source code. It can take any form. While esbuild's default behavior is to interpret import paths as either a relative path or a package name, plugins can be used to introduce new path forms. For example, the sample HTTP plugin below gives special meaning to paths starting with


These properties let you return additional file system paths for esbuild's watch mode to scan. By default esbuild will only scan the path provided to onLoad plugins, and only if the namespace is file. If your plugin needs to react to additional changes in the file system, it needs to use one of these properties.


This property lets you replace this plugin's name with another name for this path resolution operation. It's useful for proxying another plugin through this plugin. For example, it lets you have a single plugin that forwards to a child process containing multiple plugins. You probably won't need to use this.


This property will be passed to the next plugin that runs in the plugin chain. If you return it from an onLoad plugin, it will be passed to the onResolve plugins for any imports in that file, and if you return it from an onResolve plugin, an arbitrary one will be passed to the onLoad plugin when it loads the file (it's arbitrary since the relationship is many-to-one). This is useful to pass data between different plugins without them having to coordinate directly.


The callback can return without providing the contents of the module. In that case the responsibility for loading the module is passed to the next registered callback. For a given module, all onLoad callbacks from all plugins will be run in the order they were registered until one takes responsibility for loading the module. If no callback returns contents for the module, esbuild will run its default module loading logic.


This is the URL query and/or hash at the end of the file path, if there is one. It's either filled in by esbuild's native path resolution behavior or returned by the on-resolve callback that resolved this file. This is stored separately from the path so that most plugins can just deal with the path and ignore the suffix. The on-load behavior that's built into esbuild just ignores the suffix and loads the file from its path alone.


This property lets you replace this plugin's name with another name for this module load operation. It's useful for proxying another plugin through this plugin. For example, it lets you have a single plugin that forwards to a child process containing multiple plugins. You probably won't need to use this. 2ff7e9595c


0 views0 comments

Recent Posts

See All

Comments


bottom of page