Trouble with native script and script filter


(mic-2) #1

Hi,

I have been trying to create a native script that will work with the script
filter.

So far I have compiled and completed the tutorial here for how to make
customscore native scripts.
http://www.spacevatican.org/2012/5/12/elasticsearch-native-scripts-for-dummies/

My question is how to make a native script work with the script filter.

Here is a gist of what I have tried so far and the error I receive.

Any pointers would be greatly appreciated.

Thank you

Sincerely,
Mic Johnson

--


(mic-2) #2

Oops, forgot the gist: https://gist.github.com/6f2c97754bdd7914f78d

On Tue, Aug 28, 2012 at 5:51 PM, Mic micjohnson@gmail.com wrote:

Hi,

I have been trying to create a native script that will work with the
script filter.

So far I have compiled and completed the tutorial here for how to make
customscore native scripts.

http://www.spacevatican.org/2012/5/12/elasticsearch-native-scripts-for-dummies/

My question is how to make a native script work with the script filter.

Here is a gist of what I have tried so far and the error I receive.

Any pointers would be greatly appreciated.

Thank you

Sincerely,
Mic Johnson

--

--


(Cédric Hourcade) #3

Hello,

You just forgot to specify your script language with the "lang" parameter,
see : https://gist.github.com/3509591

Cédric

Le mercredi 29 août 2012 02:51:59 UTC+2, Mic a écrit :

Hi,

I have been trying to create a native script that will work with the
script filter.

So far I have compiled and completed the tutorial here for how to make
customscore native scripts.

http://www.spacevatican.org/2012/5/12/elasticsearch-native-scripts-for-dummies/

My question is how to make a native script work with the script filter.

Here is a gist of what I have tried so far and the error I receive.

Any pointers would be greatly appreciated.

Thank you

Sincerely,
Mic Johnson

--


(mic-2) #4

Hello,

Cédric, you have no clue how happy this makes me. Thank you.

Sincerely,
Mic Johnson

On Wed, Aug 29, 2012 at 3:03 AM, Cédric Hourcade ced@wal.fr wrote:

Hello,

You just forgot to specify your script language with the "lang" parameter,
see : https://gist.github.com/3509591

Cédric

Le mercredi 29 août 2012 02:51:59 UTC+2, Mic a écrit :

Hi,

I have been trying to create a native script that will work with the
script filter.

So far I have compiled and completed the tutorial here for how to make
customscore native scripts.
http://www.spacevatican.org/2012/5/12/elasticsearch-
native-scripts-for-dummies/http://www.spacevatican.org/2012/5/12/elasticsearch-native-scripts-for-dummies/

My question is how to make a native script work with the script filter.

Here is a gist of what I have tried so far and the error I receive.

Any pointers would be greatly appreciated.

Thank you

Sincerely,
Mic Johnson

--

--


(mic-2) #5

To complete this topic, I had to extend AbstractSearchScript instead of
AbstractExecutableScript. But now I'm rockin'.

On Wed, Aug 29, 2012 at 7:04 PM, Mic Johnson micjohnson@gmail.com wrote:

Hello,

Cédric, you have no clue how happy this makes me. Thank you.

Sincerely,
Mic Johnson

On Wed, Aug 29, 2012 at 3:03 AM, Cédric Hourcade ced@wal.fr wrote:

Hello,

You just forgot to specify your script language with the "lang"
parameter, see : https://gist.github.com/3509591

Cédric

Le mercredi 29 août 2012 02:51:59 UTC+2, Mic a écrit :

Hi,

I have been trying to create a native script that will work with the
script filter.

So far I have compiled and completed the tutorial here for how to make
customscore native scripts.
http://www.spacevatican.org/2012/5/12/elasticsearch-
native-scripts-for-dummies/http://www.spacevatican.org/2012/5/12/elasticsearch-native-scripts-for-dummies/

My question is how to make a native script work with the script filter.

Here is a gist of what I have tried so far and the error I receive.

Any pointers would be greatly appreciated.

Thank you

Sincerely,
Mic Johnson

--

--


(system) #6