Class ProfileResult

  • All Implemented Interfaces:
    Writeable, ToXContent, ToXContentObject

    public final class ProfileResult
    extends java.lang.Object
    implements Writeable, ToXContentObject
    This class is the internal representation of a profiled Query, corresponding to a single node in the query tree. It is built after the query has finished executing and is merely a structured representation, rather than the entity that collects the timing profile (see InternalProfiler for that) Each InternalProfileResult has a List of InternalProfileResults, which will contain "children" queries if applicable
    • Constructor Detail

      • ProfileResult

        public ProfileResult​(java.lang.String type,
                             java.lang.String description,
                             java.util.Map<java.lang.String,​java.lang.Long> timings,
                             java.util.List<ProfileResult> children)
      • ProfileResult

        public ProfileResult​(StreamInput in)
        Read from a stream.
    • Method Detail

      • getLuceneDescription

        public java.lang.String getLuceneDescription()
        Retrieve the lucene description of this query (e.g. the "explain" text)
      • getQueryName

        public java.lang.String getQueryName()
        Retrieve the name of the query (e.g. "TermQuery")
      • getTimeBreakdown

        public java.util.Map<java.lang.String,​java.lang.Long> getTimeBreakdown()
        Returns the timing breakdown for this particular query node
      • getTime

        public long getTime()
        Returns the total time (inclusive of children) for this query node.
        elapsed time in nanoseconds
      • getProfiledChildren

        public java.util.List<ProfileResult> getProfiledChildren()
        Returns a list of all profiled children queries
      • fromXContent

        public static ProfileResult fromXContent​(XContentParser parser)