Skip to content

Commit

Permalink
Merge branch 'master' of github.com:chaoslawful/drizzle-nginx-module
Browse files Browse the repository at this point in the history
  • Loading branch information
agentzh committed Dec 17, 2010
2 parents 3df6542 + f59b991 commit 397ddcb
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/ngx_http_drizzle_handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,9 @@ ngx_http_drizzle_handler(ngx_http_request_t *r)
dlcf->upstream.upstream = ngx_http_upstream_drizzle_add(r, &url);

if (dlcf->upstream.upstream == NULL) {
//dd("upstream \"%.*s\" not found", target.len, target.data);
ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
"drizzle: upstream \"%V\" not found", &target);

return NGX_HTTP_INTERNAL_SERVER_ERROR;
}
}
Expand Down
17 changes: 17 additions & 0 deletions test/t/errors.t
Original file line number Diff line number Diff line change
Expand Up @@ -156,3 +156,20 @@ little-endian systems only
GET /mysql
--- error_code: 500
=== TEST 8: empty pass
little-endian systems only
--- http_config eval: $::http_config
--- config
location /mysql {
set $backend "not-exist";
drizzle_pass $backend;
drizzle_module_header off;
drizzle_query "update cats set name='bob' where name='bob'";
}
--- request
GET /mysql
--- error_code: 500

0 comments on commit 397ddcb

Please sign in to comment.