New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ApplyViewToElementsFunction does not apply Schema validation #3059
Comments
Having the this tap into an existing instance of AccumuloStore for the temporary map is the way forward. |
Technically the Function is called "ApplyView" to elements. which is does do. But I think it should be better and apply the Schema Validation. |
…ation into view POST Aggregation to work after a groupBy aggregation change.
…wtoelements-schema-validation' into gh-3059-federated-store-applyviewtoelements-schema-validation # Conflicts: # store-implementation/federated-store/src/main/java/uk/gov/gchq/gaffer/federatedstore/util/ApplyViewToElementsFunction.java
…ation should only be done for the TemporaryStore of type MapStore
It seems the the Schema can be searched for any Group's Validation function and these can be used in a View post aggregate filter. The View is made if it doesn't exist or it merges if it does. PostAggregate because this happens after the GroupBy aggregation. |
…dation' into gh-3059-other-temp-merge-graphs # Conflicts: # store-implementation/federated-store/src/main/java/uk/gov/gchq/gaffer/federatedstore/util/FederatedElementFunction.java
…dation' into gh-3059-other-temp-merge-graphs # Conflicts: # store-implementation/federated-store/src/main/java/uk/gov/gchq/gaffer/federatedstore/util/FederatedStoreUtil.java
…dation' into gh-3059-other-temp-merge-graphs
…store-applyviewtoelements-schema-validation # Conflicts: # store-implementation/federated-store/src/test/java/uk/gov/gchq/gaffer/federatedstore/FederatedStoreSchemaTest.java
…store-applyviewtoelements-schema-validation # Conflicts: # store-implementation/federated-store/src/test/java/uk/gov/gchq/gaffer/federatedstore/operation/handler/impl/FederatedOperationChainHandlerTest.java
Describe the bug
ApplyViewToElementsFunction will apply the View of an operation to the results from multiple subgraphs. This is meant to ensure that the results are correctly aggregated and validated after a query to a FederatedStore.
However, despite the View validation being applied, the Schema validation is not applied. This could be intended, but I suspect it is not, as the intention of this merge function is to ensure all aggregation and validation happens as if the results came from one graph. If this is indeed unintended, I would suggest the merge function should be renamed to something like ValidateAndAggregateElements.
Additional context
The reason this happens is that the results are currently merged inside a MapStore and the MapStore does not currently support schema validation: #2613.
Some potential fixes are:
The text was updated successfully, but these errors were encountered: