Class PluginInfo

org.elasticsearch.plugins.PluginInfo
All Implemented Interfaces:
Writeable, org.elasticsearch.common.xcontent.ToXContent, org.elasticsearch.common.xcontent.ToXContentObject

public class PluginInfo extends implements Writeable, org.elasticsearch.common.xcontent.ToXContentObject
An in-memory representation of the plugin descriptor.
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent

    org.elasticsearch.common.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.common.xcontent.ToXContent.MapParams, org.elasticsearch.common.xcontent.ToXContent.Params

    Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable

    Writeable.Reader<V>, Writeable.Writer<V>
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static
     
    static
     

    Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent

    EMPTY_PARAMS
  • Constructor Summary

    Constructors
    Constructor
    Description
     name,  description,  version, Version elasticsearchVersion,  javaVersion,  classname, <> extendedPlugins, boolean hasNativeController, PluginType type,  javaOpts, boolean isLicensed)
    Construct plugin info.
    Construct plugin info from a stream.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     o)
     
    The entry point to the plugin.
    The description of the plugin.
    The version of Elasticsearch the plugin was built for.
    <>
    Other plugins this plugin extends through SPI.
    Returns any additional JVM command-line options that this plugin adds.
    The version of Java the plugin was built with.
    The name of the plugin.
    Returns the type of this plugin.
    The version of the plugin
    int
     
    boolean
    Whether or not the plugin has a native controller.
    boolean
    Whether this plugin is subject to the Elastic License.
    static PluginInfo
     path)
    Reads the plugin descriptor file.
     
     prefix)
     
    org.elasticsearch.common.xcontent.XContentBuilder
    toXContent​(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)
     
    void
    Write this into the StreamOutput.

    Methods inherited from class java.lang.

    , , , , , , ,

    Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject

    isFragment
  • Field Details

  • Constructor Details

    • PluginInfo

      public PluginInfo( name,  description,  version, Version elasticsearchVersion,  javaVersion,  classname, <> extendedPlugins, boolean hasNativeController, PluginType type,  javaOpts, boolean isLicensed)
      Construct plugin info.
      Parameters:
      name - the name of the plugin
      description - a description of the plugin
      version - an opaque version identifier for the plugin
      elasticsearchVersion - the version of Elasticsearch the plugin was built for
      javaVersion - the version of Java the plugin was built with
      classname - the entry point to the plugin
      extendedPlugins - other plugins this plugin extends through SPI
      hasNativeController - whether or not the plugin has a native controller
      type - the type of the plugin. Expects "bootstrap" or "isolated".
      javaOpts - any additional JVM CLI parameters added by this plugin
      isLicensed - whether is this a licensed plugin
    • PluginInfo

      public PluginInfo(StreamInput in) throws
      Construct plugin info from a stream.
      Parameters:
      in - the stream
      Throws:
      - if an I/O exception occurred reading the plugin info from the stream
  • Method Details

    • writeTo

      public void writeTo(StreamOutput out) throws
      Description copied from interface: Writeable
      Write this into the StreamOutput.
      Specified by:
      writeTo in interface Writeable
      Throws:
    • readFromProperties

      public static  path) throws
      Reads the plugin descriptor file.
      Parameters:
      path - the path to the root directory for the plugin
      Returns:
      the plugin info
      Throws:
      - if an I/O exception occurred reading the plugin descriptor
    • getName

      public  getName()
      The name of the plugin.
      Returns:
      the plugin name
    • getDescription

      public  getDescription()
      The description of the plugin.
      Returns:
      the plugin description
    • getClassname

      public  getClassname()
      The entry point to the plugin.
      Returns:
      the entry point to the plugin
    • getExtendedPlugins

      public <> getExtendedPlugins()
      Other plugins this plugin extends through SPI.
      Returns:
      the names of the plugins extended
    • getVersion

      public  getVersion()
      The version of the plugin
      Returns:
      the version
    • getElasticsearchVersion

      public Version getElasticsearchVersion()
      The version of Elasticsearch the plugin was built for.
      Returns:
      an Elasticsearch version
    • getJavaVersion

      public  getJavaVersion()
      The version of Java the plugin was built with.
      Returns:
      a java version string
    • hasNativeController

      public boolean hasNativeController()
      Whether or not the plugin has a native controller.
      Returns:
      true if the plugin has a native controller
    • getType

      public PluginType getType()
      Returns the type of this plugin. Can be "isolated" for regular sandboxed plugins, or "bootstrap" for plugins that affect how Elasticsearch's JVM runs.
      Returns:
      the type of the plugin
    • getJavaOpts

      public  getJavaOpts()
      Returns any additional JVM command-line options that this plugin adds. Only applies to plugins whose type is "bootstrap".
      Returns:
      any additional JVM options.
    • isLicensed

      public boolean isLicensed()
      Whether this plugin is subject to the Elastic License.
    • toXContent

      public org.elasticsearch.common.xcontent.XContentBuilder toXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws
      Specified by:
      toXContent in interface org.elasticsearch.common.xcontent.ToXContent
      Throws:
    • equals

      public boolean equals( o)
      Overrides:
       in class 
    • hashCode

      public int hashCode()
      Overrides:
       in class 
    • toString

      public  toString()
      Overrides:
       in class 
    • toString

      public  toString( prefix)