users@glassfish.java.net

Re: Glassfish behind an https reverse proxy

From: Cédric Marcone <cedric.marcone_at_valraiso.fr>
Date: Mon, 3 Jan 2011 17:41:10 +0100

OK, thanks Alexey.

I created the issue : http://java.net/jira/browse/GLASSFISH-15409

I'll change my config back to use a JK listener, but I originally moved away from it because I had other issues under high load.
I had to modify the "http-thread-pool" configuration to set a max-thread-pool-size="50".

But sometimes, when grizzly starts I have thousands of IOExceptions (Too many open files), even raising the system limits (per user, per process, etc... really high).

I chose not to investigate and take the easy route by "reverse proxying", I feel left with no choice ;)

Thank you,
--
Cédric
Le 3 janv. 2011 à 15:18, Oleksiy Stashok a écrit :
> Hi Cedric,
> 
> sorry, I misread your question.
> Currently there is no possibility in Glassfish v3 to overwrite the request scheme :(
> Can you pls. file an issue? We will add the feature asap, but unfortunately it's too late to integrate it into Glassfish 3.1, so it will go to 3.2.
> 
> WBR,
> Alexey.
> 
> 
> On Jan 3, 2011, at 14:20 , Cédric Marcone wrote:
> 
>> Hi Alexey,
>> 
>> Thanks for your answer but I'm not using mod_jk, I'm using mod_proxy.
>> And, by the way, we cannot modify the webapp, so we cannot wrap the request in the code to enforce the https scheme.
>> 
>> Regs,
>> --
>> Cédric
>> 
>> Le 3 janv. 2011 à 11:21, Oleksiy Stashok a écrit :
>> 
>>> Hi,
>>> 
>>> let's try following...
>>> Here is a blog from Amy, which you might have read [1].
>>> Please try to specify property "scheme=https" in the glassfish-jk.properties file.
>>> 
>>> WBR,
>>> Alexey.
>>> 
>>> [1] http://weblogs.java.net/blog/2009/06/24/running-glassfish-v3-apache-httpd
>>> 
>>> On Dec 30, 2010, at 18:49 , Cédric Marcone wrote:
>>> 
>>>> Hi all,
>>>> 
>>>> I'm sorry if it's obvious but I can't find anything to help me.
>>>> 
>>>> I have a webapp deployed in a glassfish domain listening on the 8080 port for http requests.
>>>> I have an apache web server configured with mod_proxy that relays the incoming https request to my GF http listener.
>>>> 
>>>> The config is done and it works except for one thing :
>>>> -> On redirections, the request scheme is http instead of https.
>>>> 
>>>> On tomcat, we can override the scheme given by the HttpServletRequest.getScheme() using the scheme attribute on the connector element in the server.xml.
>>>> 
>>>> I can't find any similar configuration property for GF.
>>>> 
>>>> If someone knows the solution, I would be very grateful.
>>>> 
>>>> Regards,
>>>> --
>>>> Cédric Marcone
>>>> Valraiso
>> 
>