Bug 530519 - Support generic local search backend when adding "search" evaluation backend to pattern definition
Summary: Support generic local search backend when adding "search" evaluation backend ...
Status: RESOLVED FIXED
Alias: None
Product: Viatra
Classification: Modeling
Component: Query (show other bugs)
Version: 2.0.0   Edit
Hardware: PC Windows 10
: P3 normal
Target Milestone: 2.0.0M4   Edit
Assignee: Zoltan Ujhelyi CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-30 11:27 EST by Abel Hegedus CLA
Modified: 2018-05-15 17:53 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Abel Hegedus CLA 2018-01-30 11:27:15 EST
If the query definition contains evaluation backend hints (see https://www.eclipse.org/viatra/documentation/query-language.html#_pattern_structure ) to select Local Search backend (with "search"), it always uses the EMF-specific LS backend, even if the Generic LS backend is selected with engine level hints.

Example:

  search pattern className(c : EClass, clName : java ^java.lang.String) {
    EClass.name(c, clName);
  }

  queryOptions = LocalSearchHints.getDefaultGeneric()
    .setUseBase(true).build();
  queryEngineOptions = ViatraQueryEngineOptions
    .defineOptions().withDefaultHint(queryOptions)
    .withDefaultBackend(queryOptions.getQueryBackendFactory()).build();
  engine = AdvancedViatraQueryEngine.createUnmanagedEngine(scope, queryEngineOptions);

Creating the matcher will NOT use Generic LS backend.
Comment 1 Eclipse Genie CLA 2018-05-12 06:28:29 EDT
New Gerrit change created: https://git.eclipse.org/r/122509
Comment 2 Eclipse Genie CLA 2018-05-15 08:22:34 EDT
New Gerrit change created: https://git.eclipse.org/r/122668
Comment 5 Zoltan Ujhelyi CLA 2018-05-15 17:53:19 EDT
Fixed in master.