# |
Jul 10th 2018, 16:09 |
james.phillips |
any idea why I get Unknown method "getRepository" when doing $query->toArray() on ES? |
# |
Jul 10th 2018, 15:43 |
james.phillips |
so I did a little hack hoping that when I upgrade the url would be the way to do it ;) |
# |
Jul 10th 2018, 15:43 |
james.phillips |
and got The DSN string 'host-7djrft.api.swiftype.com/api/as/v1/engines/riptestengine/documents/' could not be parsed. |
# |
Jul 10th 2018, 15:42 |
james.phillips |
so i took out https:// |
# |
Jul 10th 2018, 15:42 |
james.phillips |
eariler and got Database driver https could not be found. |
# |
Jul 10th 2018, 15:42 |
james.phillips |
I tried that.... |
# |
Jul 10th 2018, 15:12 |
josbeir |
but you should indeed upgrade, elastica has also gotten some love :slightly_smiling_face: |
# |
Jul 10th 2018, 15:10 |
josbeir |
remember, all settings configured in de datasource are passed to the Elastica client |
# |
Jul 10th 2018, 15:10 |
josbeir |
'url' => 'https://host-7djrft.api.swiftype.com:9200' or something |
# |
Jul 10th 2018, 15:09 |
josbeir |
no need to hack stuff |
# |
Jul 10th 2018, 15:09 |
josbeir |
so in your cake datasource options you can just use that to override the url :P |
# |
Jul 10th 2018, 15:09 |
josbeir |
there's a value called 'url' in there :P |
# |
Jul 10th 2018, 15:09 |
josbeir |
$_config |
# |
Jul 10th 2018, 15:09 |
josbeir |
see the options array ? |
# |
Jul 10th 2018, 15:09 |
josbeir |
check Elastica\Client.php |
# |
Jul 10th 2018, 15:08 |
josbeir |
@james.phillips |
# |
Jul 10th 2018, 15:06 |
romanovich095 |
With few diferrent requests |
# |
Jul 10th 2018, 15:06 |
romanovich095 |
Try to log the $url before the condition |
# |
Jul 10th 2018, 15:05 |
james.phillips |
but I cant seem to set url so it always does the else |
# |
Jul 10th 2018, 15:04 |
james.phillips |
if (!empty($url)) { $baseUri = $url; } else { $baseUri = $this->_scheme.'://'.$connection->getHost().':'.$connection->getPort().'/'.$connection->getPath(); } |
# |
Jul 10th 2018, 15:04 |
james.phillips |
so in ruflin elastic theres |
# |
Jul 10th 2018, 15:03 |
james.phillips |
been using this https://book.cakephp.org/3.0/en/elasticsearch.html# |
# |
Jul 10th 2018, 15:03 |
romanovich095 |
Can You send me the plugin You use for es? |
# |
Jul 10th 2018, 15:02 |
james.phillips |
tried setting port to null and but that errors |
# |
Jul 10th 2018, 15:01 |
james.phillips |
im hoping once I update versions of cake and the ES plugin it will be a happy bunny |
# |
Jul 10th 2018, 15:01 |
james.phillips |
if I hit the urls in my browser the one without the port pops up a login screen whilst the other goes to sleep |
# |
Jul 10th 2018, 15:00 |
james.phillips |
works as https://host-7djrft.api.swiftype.com/api/as/v1/engines/xxxxxx/documents |
# |
Jul 10th 2018, 15:00 |
james.phillips |
ES search doesn;t seem to like the port being in the url |
# |
Jul 10th 2018, 14:59 |
james.phillips |
meant https://host-7djrft.api.swiftype.com:9200/api/as/v1/engines/xxxxxx/documents |
# |
Jul 10th 2018, 14:59 |
romanovich095 |
What does the dd() say? |
# |
Jul 10th 2018, 14:58 |
romanovich095 |
Check the url before sending |
# |
Jul 10th 2018, 14:58 |
james.phillips |
works if I hard code http://host-7djrft.api.swiftype.com/api/as/v1/engines/rcccccccc/documents/ |
# |
Jul 10th 2018, 14:58 |
james.phillips |
which ES cloud doesnt seem to like |
# |
Jul 10th 2018, 14:58 |
james.phillips |
but it stick port into the middle http://host-7djrft.api.swiftype.com/:9200/api/as/v1/engines/rcccccccc/documents/ |
# |
Jul 10th 2018, 14:57 |
james.phillips |
i have host and path set |
# |
Jul 10th 2018, 14:56 |
james.phillips |
it was putting _all into the url for some reason... and then on the datasource i have: |
# |
Jul 10th 2018, 14:54 |
james.phillips |
naa prob my set up is wrong |
# |
Jul 10th 2018, 14:52 |
josbeir |
elastica bug? |
# |
Jul 10th 2018, 14:52 |
josbeir |
weird |
# |
Jul 10th 2018, 14:51 |
james.phillips |
had to hack something thou as it was sticking the port in the middle of the url |
# |
Jul 10th 2018, 14:51 |
josbeir |
thats good :slightly_smiling_face: |