Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Timeouts when request made shortly after design document changes #78

Open
james-w opened this Issue Sep 20, 2010 · 2 comments

Comments

Projects
None yet
3 participants

james-w commented Sep 20, 2010

Hi,

As discussed on IRC I am getting timeouts from _fti due to an ajax request hanging.

Creating a new couchapp and removing "evently/items/_changes/query.json" and
putting in a "evently/items/_changes/async.js" that contains:

function (callback) {
    console.log("Something changed!");
    var app = $$(this).app;
    $.ajax({type: "GET", url: app.db.uri + "_fti/_design/test/by_content?q=baa", dataType: "json",
            success: function(data, textStatus, req) {
                console.log("%o", data);
            }
        });
}

should demonstrate the issue.

If you do this then push to your couchdb, open the page as it says, and then push again, now
if you try and hit an _fti URL it will hang until you get an os process timeout.

If you change the code to move the $.ajax call in to a timeout for 1s or more later, then everything
works as it should.

I can reproduce this on 0.10.0 and 1.0.1, and with tips of 0.5.x and master.

Let me know if I can provide you with any more inforamtion.

Thanks,

James

Owner

rnewson commented Sep 21, 2010

Thanks for the details. I tried this and cannot reproduce the issue, hopefully you'll be on IRC later.

In the meantime, if you can induce the condition again I'd appreciate a thread dump from Java. You can induce this will 'kill -QUIT <pid>'. The output should go to the screen where you are running bin/run from, please paste the whole output to a paste service somewhere, it should highlight exactly where the Java code is locked.

Contributor

anandology commented Dec 8, 2010

I'm also noticing the timeouts. Even with stale=ok

I have a couchdb database 25M docs with a couchdb-lucene index and I'm in the process of massively updating that database.

I noticed that all _fti queries are giving 500 internal errors. Tried to restart couchdb-lucene and that didn't help. I paused my script that was updating the the database, waited till c-l catchup with the backlog and it started working again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment