Skip to:
Content
Pages
Categories
Search
Top
Bottom

bbpress returning 404s from wp_remote_get() in wpmu

  • Howdy. I’ve got a buddypress, mu and bbpress site. buddypress is trying to access some forums in bbpress thru xmlrpc. Essentially sambauer’s bbpress_live widget is being used. My problem is that the connection between buddypress and bbpress is failing for some reason unknown to me.

    Here’s the sequence of things going on.

    buddypress wants to do some stuff in the bbpress forums so a bbpress_Live_Fetch obj is instantiated and the constructor is called. The constructor, since it’s purpose is to fetch something, tries to setup a connection between buddypress and bbpress through one of it’s member functions set_endpoint().

    With me so far? We haven’t gotten to the problem yet.

    set_endpoint() makes a call to a function in /wp-content/comment.php called discover_pingback_server_uri(). That function’s purpose is to do exotic stuff finding a ‘pingback server uri’ for the passed uri.

    I don’t know what that is and don’t really care. I do care that the workhorse part of that function is actually a call to a new 2.7 function that goes out and GETs what is located at the url in question. When it GETs the goop back from that url, it parses it and returns a ping back server uri.

    However, the function that it uses to GET goop from the passed url always returns 404 when looking for my bbpress url. It does exist.

    The function wp_remote_get() when passed a valid url for bbpress such as ‘http://myfavsite.org/bbpress/’ returns 404.

    Here’s the maddening part. It works on a windows development server but not on the live linux server. Same code, same .htaccess files, essentially the same httpd.conf file.

    Why would wp_remote_get() return 404 for a valid url? wp_remote_get() and it’s brethren seem to be new in mu 2.7.

    wpmu 2.7 r1574 is what I got runnin’

Viewing 3 replies - 1 through 3 (of 3 total)
  • The above is a re-post here of a cry for help on the mu forums.

    Here’s an update. I’ve debugged this down to the ‘transport’ mechanism in mu. I don’t think that the problem is with the bbpress_live widget. I don’t think that it’s an apache problem. Visit this buddypress forum topic for a complete list of the debugging efforts.

    https://buddypress.org/forums/topic.php?id=376

    I’ve gone down to bare metal on the mu side of this and it’s just getting 404 in certain installations and I can’t figure out why. Any help would be appreciated.

    Do you know what transport is being used on the broken installations?

    wp_remote_get() now uses the HTTP API library, which is supposed to try different ways of retrieving a remote HTTP resource. It is possible that the method the problem server is selecting to use looks like it is valid to WPMU but in fact isn’t for some configuration reason.

    Beyond that I really can’t help without more specifics about your setup, mainly what transport method the HTTP API is using.

    This is to clear up this issue. Frankly I had forgotten about this post after solving the problem. Whoops. Sorry.

    I was trying to fire up xmlrpc access from wpmu to bbpress. Your bbpress_live plugin wasn’t working. buddypress’s group forums weren’t working. Surprise, it uses the bbpress_live classes.

    Turns out the wp http api lib uses the curl lib as the default transport mechanism. It goes out and gets the requested url using curl by default if it’s installed. It’s installed everywhere and on everything except my kitchen toaster. So, curl resolves ip addresses by first looking at your /etc/hosts file. Then it goes to dns for resolution.

    The /etc/hosts file and linux are happy with hosts defaulting to 127.0.0.1 for mysite.org. I live in apache all day long and don’t care what’s in my hosts file. I should have. :)

    Changed /etc/hosts to have the actual ip address to my domain and xmlrpc, bbpress_live, buddypress and the rest of the universe are happy.

    Thanks for the quick response Sam!

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Skip to toolbar