Package org.elasticsearch.action

Examples of org.elasticsearch.action.ActionRequestValidationException


            return fieldMapping;
        }

        @Override
        public ActionRequestValidationException validate() {
            ActionRequestValidationException validationException = null;
            if (searchRequest == null) {
                validationException = addValidationError("No delegate search request", validationException);
            }
           
            if (queryHint == null) {
                validationException = addValidationError("query hint may be empty but must not be null.", validationException);
            }
           
            if (fieldMapping.isEmpty()) {
                validationException = addValidationError("At least one field should be mapped to a logical document field.", validationException);
            }

            ActionRequestValidationException ex = searchRequest.validate();
            if (ex != null) {
                if (validationException == null) {
                    validationException = new ActionRequestValidationException();
                }
                validationException.addValidationErrors(ex.validationErrors());
            }
           
            return validationException;
        }
View Full Code Here

TOP

Related Classes of org.elasticsearch.action.ActionRequestValidationException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.