Since version 11.3, Wedia relies on ElasticSearch for full text and structured search. All SQL or SQL + Full text queries go through ElasticSearch. The RDBMS is only used to retrieve instances identified by the ElasticSearch search.
Full-text syntax
...
Note
The content of this article is only valid from version 11.6 onwards.
A "full text" search does not require any special syntax elements. Just list the words you want to search for a result, e.g.: green boat
...
Finally, if you are looking for a boat whose reference is vaguely known, it is possible to do a search starting with suffixing the reference by '*':
+boat +REF25*
...
Note
Prefix searching is not implemented for performance reasons. A search on F25 will not have the desired effect.
To summarize:
Prefix with '+' to force the presence of a term.
Prefix '-' to exclude the presence of a term.
Surround with '"' to search for an exact phrase.
It is possible to force or exclude a sentence: +"green boat" -"red boat"
...
There is also a shortcut to search directly for an instance whose id is known by typing: #id.
zSyslucene object
...
Note
This section applies for developers migrating from a Lucene based to a ElasticSearch based version.
The use of ElasticSearch entails some changes to be taken into account when developing new applications or migrating existing ones.
First of all, the zSyslucene object is no longer supported. Its use does not generate errors but will not give any correct results. This choice was made to avoid leakage of the internal structure of the ElasticSearch index and thus facilitate the evolutions on the latter. Result: any use of zSyslucene will have to be migrated on a normal SQL + Full text object by object search. This research is very successful and there is no longer any reason to do otherwise. The next version of Wedia should provide a "global" search API on all indexed objects to facilitate development.
bypassing ElasticSearch and using rDBMS directly
Then, it is important to keep in mind that all SQL or SQL + Full text queries go through ElasticSearch. The DBMS is only used to retrieve instances identified by the ElasticSearch search. An effort has been made to make this operation as "real time" as possible. This means that normally: any addition or modification of instance is made directly available to the search. However, in order to avoid any problems caused by a possible mismatch between modifications and searches during modification batches on objects, a new API has been created to completely bypass the search layer ElasticSearch and to use DBMS efficiently. This class is wsnoheto.engine.BatchObjectsIterable.
Faceted searchs
The use of ElasticSearch makes it easy to perform faceted searches allowing you to return the results count for different values of the searched object: by wage type, brand, workflow status, etc. This research has been done until now thanks to an intensive use of wsnoheto.engine.Loader. There is now a specialized class for this purpose: wsnoheto.engine.FacetsBuilder. This class uses natively ElasticSearch to get these results which is more powerful and much easier to use. This class also automatically works as a fallback on the Loader if Elastic is not configured or available. It is therefore highly recommended to go through this class to implement faceted research on front office.
Limit the fields used in the full text search to specific languages.
The content of this article is only valid from version 11.6 onwards.
...