Title: RE: problems with scanpage.getHostNames
I changed the web.xml so that it also contains the new servlet, but where should I change the mapping? How can I make mmbase use the new images servlet instead of the old servdb servlet? (probably a stupid question but I need to know).
 
 
Karen.
-----Oorspronkelijk bericht-----
Van: Pierre van Rooden [mailto:[EMAIL PROTECTED]
Verzonden: woensdag 16 juli 2003 11:27
Aan: 'Ploeg, Karen van der (Fin) '; ''[EMAIL PROTECTED]' '
Onderwerp: RE: problems with scanpage.getHostNames

<< All ideas on how to get the sucker back to work are welcome!  I am not a
developer but I feel that this is the place to post my question >>

The bug is probably caused by the use of a proxy.
There is a bug in the MMBase code that makes it go haywire if it can't find the 'remotehost' of the connecting user. The remotehost is used to determine whether someone connects froma a certain domain (and thus should be assigned a certain proxy server). If the remotehost is 'null' (probably because of a proxy) it makes amok.

I will fix this bug in the code, but that won't help you much unless you can edit/compile the code yourself, or are willing to switch to a 1.6.4 pre-release version.

A better alternative to fix this now is to switch using a different image servlet.
Instead of using the servdb servlet (set in web.xml), try using the ImageServlet.
The ImageServlet does not test for proxies and thus should not give you problems.
The tags you need to place in web.xml look like this:


  <!-- The MMBase image serving servlet. -->
  <servlet>
    <servlet-name>images</servlet-name>
    <description>To extract images from MMBase</description>
    <servlet-class>org.mmbase.servlet.ImageServlet</servlet-class>
    <init-param>
      <!-- Expire time of original images. Cached images never expire. -->
      <param-name>expire</param-name>
      <!-- 10 minutes (default is one hour)-->
      <param-value>600</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
  </servlet>

and change the srevletmapping to:

  <!-- mapping for image-requests -->
  <servlet-mapping>
    <servlet-name>images</servlet-name>
    <url-pattern>/img.db</url-pattern>
  </servlet-mapping>


If you have further questions on how to get past this bug, I suggest to visit the irc channel (#mmbase on SlashNet).

Pierre

Reply via email to