Class ProxyControl

    • Field Detail

      • DEFAULT_PORT_S

        public static final String DEFAULT_PORT_S
    • Constructor Detail

      • ProxyControl

        public ProxyControl()
    • Method Detail

      • setPort

        public void setPort​(int port)
      • setPort

        public void setPort​(String port)
      • setSslDomains

        public void setSslDomains​(String domains)
      • getSslDomains

        public String getSslDomains()
      • setCaptureHttpHeaders

        public void setCaptureHttpHeaders​(boolean capture)
      • setGroupingMode

        public void setGroupingMode​(int grouping)
      • setAssertions

        public void setAssertions​(boolean b)
      • setSamplerTypeName

        @Deprecated
        public void setSamplerTypeName​(int samplerTypeName)
        Deprecated.
      • setSamplerTypeName

        public void setSamplerTypeName​(String samplerTypeName)
      • setSamplerRedirectAutomatically

        public void setSamplerRedirectAutomatically​(boolean b)
      • setSamplerFollowRedirects

        public void setSamplerFollowRedirects​(boolean b)
      • setUseKeepAlive

        public void setUseKeepAlive​(boolean b)
        Parameters:
        b - flag whether keep alive should be used
      • setSamplerDownloadImages

        public void setSamplerDownloadImages​(boolean b)
      • setNotifyChildSamplerListenerOfFilteredSamplers

        public void setNotifyChildSamplerListenerOfFilteredSamplers​(boolean b)
      • setRegexMatch

        public void setRegexMatch​(boolean b)
        Parameters:
        b - flag whether regex matching should be used
      • setContentTypeExclude

        public void setContentTypeExclude​(String contentTypeExclude)
      • setContentTypeInclude

        public void setContentTypeInclude​(String contentTypeInclude)
      • getAssertions

        public boolean getAssertions()
      • getGroupingMode

        public int getGroupingMode()
      • getPort

        public int getPort()
      • getPortString

        public String getPortString()
      • getDefaultPort

        public int getDefaultPort()
      • getCaptureHttpHeaders

        public boolean getCaptureHttpHeaders()
      • getSamplerTypeName

        public String getSamplerTypeName()
      • getSamplerRedirectAutomatically

        public boolean getSamplerRedirectAutomatically()
      • getSamplerFollowRedirects

        public boolean getSamplerFollowRedirects()
      • getUseKeepalive

        public boolean getUseKeepalive()
      • getSamplerDownloadImages

        public boolean getSamplerDownloadImages()
      • getNotifyChildSamplerListenerOfFilteredSamplers

        public boolean getNotifyChildSamplerListenerOfFilteredSamplers()
      • getRegexMatch

        public boolean getRegexMatch()
      • getContentTypeExclude

        public String getContentTypeExclude()
      • getContentTypeInclude

        public String getContentTypeInclude()
      • addConfigElement

        public void addConfigElement​(ConfigElement config)
      • addExcludedPattern

        public void addExcludedPattern​(String pattern)
      • addIncludedPattern

        public void addIncludedPattern​(String pattern)
      • clearExcludedPatterns

        public void clearExcludedPatterns()
      • clearIncludedPatterns

        public void clearIncludedPatterns()
      • getTarget

        public JMeterTreeNode getTarget()
        Returns:
        the target controller node
      • setTarget

        public void setTarget​(JMeterTreeNode target)
        Sets the target node where the samples generated by the proxy have to be stored.
        Parameters:
        target - target node to store generated samples
      • deliverSampler

        public void deliverSampler​(HTTPSamplerBase sampler,
                                   TestElement[] subConfigs,
                                   SampleResult result)
        Receives the recorded sampler from the proxy server for placing in the test tree; this is skipped if the sampler is null (e.g. for recording SSL errors) Always sends the result to any registered sample listeners.
        Parameters:
        sampler - the sampler, may be null
        subConfigs - the configuration elements to be added (e.g. header namager)
        result - the sample result, not null TODO param serverResponse to be added to allow saving of the server's response while recording.
      • stopProxy

        public void stopProxy()
      • getCertificateDetails

        public String[] getCertificateDetails()
      • findTargetControllerNode

        public JMeterTreeNode findTargetControllerNode()
        Finds the controller where samplers have to be stored, that is:
        • The controller specified by the target property.
        • If none was specified, the first RecordingController in the tree.
        • If none is found, the first AbstractThreadGroup in the tree.
        • If none is found, the Workspace.
        Returns:
        the tree node for the controller where the proxy must store the generated samplers.
      • canRemove

        public boolean canRemove()
        Description copied from class: AbstractTestElement
        Called by Remove to determine if it is safe to remove the element. The element can either clean itself up, and return true, or the element can return false.
        Specified by:
        canRemove in interface TestElement
        Overrides:
        canRemove in class AbstractTestElement
        Returns:
        true if safe to remove the element
      • isDynamicMode

        public static boolean isDynamicMode()