Class GrpcSearchService
- All Implemented Interfaces:
io.grpc.BindableService,org.saidone.unrest.api.SearchServiceGrpc.AsyncService
Queries target the workspace store and support AFTS and CMIS SQL. AFTS accepts an ordered list of property
or relevance sort fields; CMIS sorting belongs in the query's ORDER BY clause. Search results reflect
the index and may lag repository writes. Nodes deleted since indexing are omitted from the returned entries.
Queries run in a read-only transaction as the authenticated caller. The backing result set is always closed, including when node mapping fails.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGrpcSearchService(org.alfresco.service.ServiceRegistry services) Creates the adapter and its repository helpers without starting repository work. -
Method Summary
Modifier and TypeMethodDescriptionvoidquery(org.saidone.unrest.api.SearchRequest request, io.grpc.stub.StreamObserver<org.saidone.unrest.api.SearchResponse> observer) Runs a permission-filtered query against the workspace store.Methods inherited from class org.saidone.unrest.api.SearchServiceGrpc.SearchServiceImplBase
bindService
-
Constructor Details
-
GrpcSearchService
public GrpcSearchService(org.alfresco.service.ServiceRegistry services) Creates the adapter and its repository helpers without starting repository work.- Parameters:
services- Alfresco service registry; repository work uses its secured services
-
-
Method Details
-
query
public void query(org.saidone.unrest.api.SearchRequest request, io.grpc.stub.StreamObserver<org.saidone.unrest.api.SearchResponse> observer) Runs a permission-filtered query against the workspace store. Language defaults toafts;cmisis also accepted. The query must contain 1..4096 characters and a page must contain 1..1000 entries (zero selects 100).AFTS accepts up to ten ordered property/relevance sort fields. CMIS queries must use
ORDER BYinstead. Invalid queries or sort fields yieldINVALID_ARGUMENT. Indexed nodes that no longer exist are omitted without recomputing the search engine's total count. An absent fields mask selects name, type and properties; a single * returns complete nodes. An empty mask selects references only. Selection skips omitted metadata reads without changing the secured query or result ordering.- Parameters:
request- query text, language, pagination, optional ordered AFTS sort fields and Node field maskobserver- receives one result page with matching node snapshots, total count and continuation flag, or a gRPC error
-