jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: Embedded resources in WML pages
Date Sun, 04 Jun 2006 18:53:10 GMT
On 30/05/06, Bennett McElwee <Bennett.McElwee@telecom.co.nz> wrote:
> The HTML samplers can automatically retrieve embedded images from web
> pages, but it doesn't work for all XHTML pages or WML pages. I thought
> I'd warn users about this, and bounce my solution off you good people.
>
> JMeter determines whether a file is HTML by checking that its media type
> is text/html. If it's something else, for example application/xhtml+xml,
> application/xml, text/xml or text/vnd.wap.wml, then it won't try to
> parse the file to retrieve embedded resources. So if you're trying to
> test a WAP or XHTML application, JMeter may not be able to do what you
> want.
>
> As far as I can tell, this could be fixed most simply by changing
> org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase as follows:
>
> 1. In downloadPageResources(), "text/html" is hardcoded. Either read a
> list of allowed media types from properties, or hardcode a list of media
> types. Maybe just allow any media type that contains "html" or "wml".

Sounds like a good idea.
Perhaps you could create a Bugzilla enhancement for this?

> 2. If parsing a WML page, ignore the configured parser and use
> RegexpHTMLParser. (I guess the other parsers won't handle WML.)

Not sure about parsing WML pages - they seem to be rather different
from (X)HTML.

But it should not be too difficult to specify a different parser for
certain types of content - we could just add a  wmlParser.classname
property alongside the htmlParser.classname.

Perhaps we could also add:

htmlParser.mimetypes
wmlParser.mimetypes

to specify the MIME media types that JMeter can handle, as well as
which is HTML and which is WML?

> Could some knowledgeable person confirm that this should work? If so, I
> will hunt down a JDK and try to make it happen. If I can find time I
> will try to submit a patch, but don't hold your breath...

A Bugzilla enhancement would be useful...

S.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-user-help@jakarta.apache.org


Mime
View raw message