Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jmari/solar
an Apache Solr client API for Smalltalk
https://github.com/jmari/solar
pharo pharo-smalltalk smalltalk solr text-mining
Last synced: 3 months ago
JSON representation
an Apache Solr client API for Smalltalk
- Host: GitHub
- URL: https://github.com/jmari/solar
- Owner: jmari
- License: gpl-3.0
- Created: 2017-09-16T20:48:17.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2021-06-25T09:22:26.000Z (over 3 years ago)
- Last Synced: 2024-10-09T13:22:24.094Z (3 months ago)
- Topics: pharo, pharo-smalltalk, smalltalk, solr, text-mining
- Language: Smalltalk
- Homepage:
- Size: 168 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Solar
an Apache Solr client API for Smalltalk. This work is in progress but you can perform queries, faceting, highlighting and spellchecking queries, admin cores and collections.### install Solar
```Smalltalk
Metacello new
baseline: 'Solar';
repository: 'github://jmari/Solar';
load:'all'
```Some examples:
### Solar query example
```Smalltalk
|solr|
solr := ASolarClient host: '172.16.208.136' port:8983 username:'admin' password:'admin'.
solr
core:'techproducts';
edismaxQuery:[:query|
query
q: {
{ #complexphrase.
#inOrder->true}.
#name -> '"(john jon jonathan~) peters*"'.
} ];
callback:[:r| r inspect].
```
### Solar faceting query
```Smalltalk
|solr|
solr := ASolarClient host: '172.16.208.136' port:8983 username:'admin' password:'admin'.
solr
core:'techproducts';
dismaxQuery:[:query|
query
q:'*';
facet:[:f|
f field:'manu';
query: #price->('*' TO:100);
query: #price->(100 TO:200);
query: #price->(200 TO:300);
query: #price->(300 TO:400);
query: #price->(400 TO:500);
query: #price->(500 TO:'*')]];
callback:[:r| r inspect].
```
More examples in the test package