// ========================================================================== // Squidex Headless CMS // ========================================================================== // Copyright (c) Squidex UG (haftungsbeschraenkt) // All rights reserved. Licensed under the MIT license. // ========================================================================== using System; using System.ComponentModel.DataAnnotations; using Squidex.Domain.Apps.Core.HandleRules; using Squidex.Domain.Apps.Core.Rules; using Squidex.Infrastructure.Validation; namespace Squidex.Extensions.Actions.ElasticSearch { [RuleAction( Title = "Elasticsearch", IconImage = "", IconColor = "#1e5470", Display = "Populate Elasticsearch index", Description = "Populate and synchronize indexes in ElasticSearch for full text search.", ReadMore = "https://www.elastic.co/")] public sealed class ElasticSearchAction : RuleAction { [AbsoluteUrl] [Required] [Display(Name = "Server Url", Description = "The url to the elastic search instance or cluster.")] [DataType(DataType.Url)] public Uri Host { get; set; } [Required] [Display(Name = "Index Name", Description = "The name of the index.")] [DataType(DataType.Text)] [Formattable] public string IndexName { get; set; } [Required] [Display(Name = "Index Type", Description = "The name of the index type.")] [DataType(DataType.Text)] [Formattable] public string IndexType { get; set; } [Display(Name = "Username", Description = "The optional username.")] [DataType(DataType.Text)] public string Username { get; set; } [Display(Name = "Password", Description = "The optional password.")] [DataType(DataType.Text)] public string Password { get; set; } } }