git.cweiske.de
/
phorkie.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
show url and HTTP method in exception
[phorkie.git]
/
src
/
phorkie
/
Database
/
Adapter
/
Elasticsearch
/
HTTPRequest.php
diff --git
a/src/phorkie/Database/Adapter/Elasticsearch/HTTPRequest.php
b/src/phorkie/Database/Adapter/Elasticsearch/HTTPRequest.php
index 4cc02d6fe6581746e1a62124fd038d46f17af09e..24487bcd554d21035154e383f4d369a68987e67b 100644
(file)
--- a/
src/phorkie/Database/Adapter/Elasticsearch/HTTPRequest.php
+++ b/
src/phorkie/Database/Adapter/Elasticsearch/HTTPRequest.php
@@
-22,9
+22,11
@@
class Database_Adapter_Elasticsearch_HTTPRequest extends \HTTP_Request2
} else {
$error = $res->getBody();
}
} else {
$error = $res->getBody();
}
+
throw new Exception(
throw new Exception(
- 'Error in elasticsearch communication'
- . '(status code ' . $res->getStatus() . '): '
+ 'Error in elasticsearch communication at '
+ . $this->getMethod() . ' ' . (string) $this->getUrl()
+ . ' (status code ' . $res->getStatus() . '): '
. $error
);
}
. $error
);
}