WebSite and webapp

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

WebSite and webapp

Nicolas Malin-2

Hello,

For a customer site, I improved the code of RequestHandler.makeLink to manage a web site with an apache httpd at reverse proxy that force all request to use a specific webapp

Example :

myEcommerce.mydomaine.com redirect all to ofbiz.privatedomaine/ecommerce

Natively, all works fine with some parameters on web.xml and controller.xml but each link return are setted like that myEcommerce.mydomaine.com/ecommerce, called by apache httpd to ofbiz by ofbiz.privatedomaine/ecommerce/ecommerce and traducted by ofbiz by ERROR ecommerce request-map not found ;)

To solve the situation, I extended WebSite entity with attribute webappPath, init to / for websiteId ecommerce ofbiz instance and /ecommerce for other websiteId liked to other ofbiz instance (dev, back) without apache httpd with limited reverse-proxy.

It's work this 2 months without issues and I will interest to sharing it because I'm sure it exist an other way to solve and it's pleasure to compare each, and if not, I can contribute it on trunk :)

Nicolas

--

Nicolas Malin
The apache way : Openness Technical decisions are made publicly
[hidden email]

8 rue des Déportés 37000 TOURS, 02 47 50 30 54
Apache OFBiz|The Apache Way|ofbiz-fr|réseau LE
Reply | Threaded
Open this post in threaded view
|

Re: WebSite and webapp

Michael Brohl-3
Hi Nicolas,

thanks for sharing!

We never had to extend the WebSite entity to implement Apache
Webserer/OFBiz Tomcat connections, but I'm not sure if I fully
understand your setting and the problem you have solved.

Are the webserver myEcommerce.mydomaine.com and OFBiz
ofbiz.privatedomaine/ecommerce on the same server?

Regards,

Michael


Am 23.09.16 um 16:15 schrieb Nicolas Malin:

>
> Hello,
>
> For a customer site, I improved the code of RequestHandler.makeLink to
> manage a web site with an apache httpd at reverse proxy that force all
> request to use a specific webapp
>
> Example :
>
> myEcommerce.mydomaine.com redirect all to ofbiz.privatedomaine/ecommerce
>
> Natively, all works fine with some parameters on web.xml and
> controller.xml but each link return are setted like that
> myEcommerce.mydomaine.com/ecommerce, called by apache httpd to ofbiz
> by ofbiz.privatedomaine/ecommerce/ecommerce and traducted by ofbiz by
> ERROR ecommerce request-map not found ;)
>
> To solve the situation, I extended WebSite entity with attribute
> webappPath, init to / for websiteId ecommerce ofbiz instance and
> /ecommerce for other websiteId liked to other ofbiz instance (dev,
> back) without apache httpd with limited reverse-proxy.
>
> It's work this 2 months without issues and I will interest to sharing
> it because I'm sure it exist an other way to solve and it's pleasure
> to compare each, and if not, I can contribute it on trunk :)
>
> Nicolas
>
> --
> logoNrd <https://nereide.fr/>
> Nicolas Malin
> The apache way <http://theapacheway.com/> : *Openness* Technical
> decisions are made publicly
> [hidden email]
> 8 rue des Déportés 37000 TOURS, 02 47 50 30 54
>
> Apache OFBiz <http://ofbiz.apache.org/>|The Apache Way
> <http://theapacheway.com/>|ofbiz-fr <http://www.ofbiz-fr.org/>|réseau
> LE <http://www.libre-entreprise.org/>


smime.p7s (5K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: WebSite and webapp

Nicolas Malin-2
Hi Michael,


Le 23/09/2016 à 22:00, Michael Brohl a écrit :
> Hi Nicolas,
>
> thanks for sharing!
>
> We never had to extend the WebSite entity to implement Apache
> Webserer/OFBiz Tomcat connections, but I'm not sure if I fully
> understand your setting and the problem you have solved.
I understand, it's complex to explain without picture support
>
> Are the webserver myEcommerce.mydomaine.com and OFBiz
> ofbiz.privatedomaine/ecommerce on the same server?
No each service are manage by a dedicate server

Nicolas

>
> Regards,
>
> Michael
>
>
> Am 23.09.16 um 16:15 schrieb Nicolas Malin:
>>
>> Hello,
>>
>> For a customer site, I improved the code of RequestHandler.makeLink
>> to manage a web site with an apache httpd at reverse proxy that force
>> all request to use a specific webapp
>>
>> Example :
>>
>> myEcommerce.mydomaine.com redirect all to ofbiz.privatedomaine/ecommerce
>>
>> Natively, all works fine with some parameters on web.xml and
>> controller.xml but each link return are setted like that
>> myEcommerce.mydomaine.com/ecommerce, called by apache httpd to ofbiz
>> by ofbiz.privatedomaine/ecommerce/ecommerce and traducted by ofbiz by
>> ERROR ecommerce request-map not found ;)
>>
>> To solve the situation, I extended WebSite entity with attribute
>> webappPath, init to / for websiteId ecommerce ofbiz instance and
>> /ecommerce for other websiteId liked to other ofbiz instance (dev,
>> back) without apache httpd with limited reverse-proxy.
>>
>> It's work this 2 months without issues and I will interest to sharing
>> it because I'm sure it exist an other way to solve and it's pleasure
>> to compare each, and if not, I can contribute it on trunk :)
>>
>> Nicolas
>>
>> --
>> logoNrd <https://nereide.fr/>
>>     Nicolas Malin
>> The apache way <http://theapacheway.com/> : *Openness* Technical
>> decisions are made publicly
>> [hidden email]
>> 8 rue des Déportés 37000 TOURS, 02 47 50 30 54
>>
>> Apache OFBiz <http://ofbiz.apache.org/>|The Apache Way
>> <http://theapacheway.com/>|ofbiz-fr <http://www.ofbiz-fr.org/>|réseau
>> LE <http://www.libre-entreprise.org/>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: WebSite and webapp

Nicolas Malin-2
Hello, I forgot this issue on my old git branch :)

It's already good so I commited it on trunk at rev 1818494, I created an
issue OFBIZ-10088 for the report ;)

Nicolas


Le 24/09/2016 à 07:42, Nicolas Malin a écrit :

> Hi Michael,
>
>
> Le 23/09/2016 à 22:00, Michael Brohl a écrit :
>> Hi Nicolas,
>>
>> thanks for sharing!
>>
>> We never had to extend the WebSite entity to implement Apache
>> Webserer/OFBiz Tomcat connections, but I'm not sure if I fully
>> understand your setting and the problem you have solved.
> I understand, it's complex to explain without picture support
>>
>> Are the webserver myEcommerce.mydomaine.com and OFBiz
>> ofbiz.privatedomaine/ecommerce on the same server?
> No each service are manage by a dedicate server
>
> Nicolas
>>
>> Regards,
>>
>> Michael
>>
>>
>> Am 23.09.16 um 16:15 schrieb Nicolas Malin:
>>>
>>> Hello,
>>>
>>> For a customer site, I improved the code of RequestHandler.makeLink
>>> to manage a web site with an apache httpd at reverse proxy that
>>> force all request to use a specific webapp
>>>
>>> Example :
>>>
>>> myEcommerce.mydomaine.com redirect all to
>>> ofbiz.privatedomaine/ecommerce
>>>
>>> Natively, all works fine with some parameters on web.xml and
>>> controller.xml but each link return are setted like that
>>> myEcommerce.mydomaine.com/ecommerce, called by apache httpd to ofbiz
>>> by ofbiz.privatedomaine/ecommerce/ecommerce and traducted by ofbiz
>>> by ERROR ecommerce request-map not found ;)
>>>
>>> To solve the situation, I extended WebSite entity with attribute
>>> webappPath, init to / for websiteId ecommerce ofbiz instance and
>>> /ecommerce for other websiteId liked to other ofbiz instance (dev,
>>> back) without apache httpd with limited reverse-proxy.
>>>
>>> It's work this 2 months without issues and I will interest to
>>> sharing it because I'm sure it exist an other way to solve and it's
>>> pleasure to compare each, and if not, I can contribute it on trunk :)
>>>
>>> Nicolas
>>>
>>> --
>>> logoNrd <https://nereide.fr/>
>>>     Nicolas Malin
>>> The apache way <http://theapacheway.com/> : *Openness* Technical
>>> decisions are made publicly
>>> [hidden email]
>>> 8 rue des Déportés 37000 TOURS, 02 47 50 30 54
>>>
>>> Apache OFBiz <http://ofbiz.apache.org/>|The Apache Way
>>> <http://theapacheway.com/>|ofbiz-fr
>>> <http://www.ofbiz-fr.org/>|réseau LE <http://www.libre-entreprise.org/>
>>
>>
>
>