Coder Social home page Coder Social logo

RevProxy Problems about yaws HOT 9 CLOSED

erlyaws avatar erlyaws commented on May 10, 2024
RevProxy Problems

from yaws.

Comments (9)

vinoski avatar vinoski commented on May 10, 2024

Thanks, I'll take a look.

from yaws.

Ummon avatar Ummon commented on May 10, 2024

Same problem here but without using the embedded mode. It works with 1.88 but crashes with 1.90.

from yaws.

vinoski avatar vinoski commented on May 10, 2024

I built and ran the Yaws_test submitted as explained in the first comment above and got the following results:

6> yt_test:test_embedded().
test [1]: {ok,"404"}
test [2]: {ok,"404"}
test [3]: {ok,"404"}
test [4]: {ok,"404"}
test [5]: {ok,"404"}
test [6]: {ok,"404"}
test [7]: {ok,"404"}
test [8]: {ok,"404"}
test [9]: {ok,"404"}
test [10]: {ok,"404"}
[{ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"},
 {ok,"404"}]

I assume this is what you expected to see?

I see you're using rebar for your build. Unfortunately rebar currently has some problems when yaws is used as a dependency — I'm working with the rebar guys to try to resolve these. Any chance you could build your code using make, or at least the yaws part of it, and try again?

from yaws.

mdaguete avatar mdaguete commented on May 10, 2024

The results you obtained are the expected, as the revproxy is configured in yt.erl with
{revproxy,[
{"/revtest",
#url{scheme="http",
host="127.0.0.1",
port=80}}
]}
and ibrowse tries to access "http://localhost:8000/revtest/index.html.

I've compiled yaws with make and the problem appears again.

from yaws.

vinoski avatar vinoski commented on May 10, 2024

I guess this will make debugging more difficult. :-(

from yaws.

mdaguete avatar mdaguete commented on May 10, 2024

Steve, do you have a web server listening on 127.0.0.1:80 ?

When I was trying to debug the error my apache was stopped and all seemed to work.

After change revproxy config in yt.erl to

                 {revproxy,[
                            {"/revtest",
                             #url{scheme="http",
                                  host="209.85.229.99", %% Google address
                                  port=80}}
                           ]}
                ],

the bug appears again.

3> yt_test:test_embedded().
test [1]: {ok,"200"}
test [2]: {ok,"200"}
test [3]: {error,req_timedout}
test [4]: {error,req_timedout}
test [5]: {error,req_timedout}
test [6]: {error,req_timedout}
test [7]: {error,req_timedout}
test [8]: {error,req_timedout}

I've pushed a patch to github.

Sorry for my mistake.

Regards.

from yaws.

vinoski avatar vinoski commented on May 10, 2024

OK, duplicated the problem. Will start figuring it out now.

from yaws.

vinoski avatar vinoski commented on May 10, 2024

I've pushed a fix for this, please give it a try.

from yaws.

mdaguete avatar mdaguete commented on May 10, 2024

I've tested the fixes on my yaws_test project and seems to work ok.

Thank you.

from yaws.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.