Package org.dashbuilder.dataset.def
Class ElasticSearchDataSetDef
- java.lang.Object
-
- org.dashbuilder.dataset.def.DataSetDef
-
- org.dashbuilder.dataset.def.ElasticSearchDataSetDef
-
public class ElasticSearchDataSetDef extends DataSetDef
DataSet definition class for ElasticSearch provider.
This dataset provides these configuration parameters:
-
serverURL- The URL for the ElasticSearch server instance (MANDATORY) -
clusterName- The name of the cluster in the ElasticSearch server. -
index- The name of the index. It can be a concrete index name, a collection of index names, comma separated, or the keyword_allfor working with all available indexes in the ElasticSearch server (OPTIONAL - Defaults to_all) -
type- The type name. Only applicable ifindexparameter is set. It can be a concrete type name, a collection of type names, comma separated, or the keyword_allfor working with all available type in the ElasticSearch server (OPTIONAL - Defaults to_all) -
query- You can perform your custom ElasticSearch DSL query for this data provider. If this parameter exist, the parametersindex,typeandfieldare skipped. (OPTIONAL) -
relevance- The relevance value for search results (OPTIONAL) -
columns- If not specified, the column definitions for the ElasticSearch dataset are automatically given by querying the index mappings. Otherwise, you can bind a column to another datatype in dashbuilder application using this parameters (OPTIONAL)
- Since:
- 0.3.0
-
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classElasticSearchDataSetDef.ElasticSearchKeywords
-
Field Summary
Fields Modifier and Type Field Description protected StringclusterNameprotected ColumnSortcolumnSortprotected @NotNull(groups=ElasticSearchDataSetDefValidation.class) @Size(min=1,groups=ElasticSearchDataSetDefValidation.class) StringindexIndex/es to query.protected Stringqueryprotected Stringrelevanceprotected @NotNull(groups=ElasticSearchDataSetDefValidation.class) @Size(min=1,groups=ElasticSearchDataSetDefValidation.class) StringserverURLprotected StringtypeType/es to query.-
Fields inherited from class org.dashbuilder.dataset.def.DataSetDef
allColumnsEnabled, cacheEnabled, cacheMaxRows, columns, dataSetFilter, isPublic, name, patternMap, propertyMap, provider, pushEnabled, pushMaxSize, refreshAlways, refreshTime, UUID
-
-
Constructor Summary
Constructors Constructor Description ElasticSearchDataSetDef()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataSetDefclone()booleanequals(Object obj)IntegergetCacheMaxRows()StringgetClusterName()ColumnSortgetColumnSort()StringgetIndex()StringgetQuery()StringgetRelevance()StringgetServerURL()StringgetType()inthashCode()booleanisCacheEnabled()voidsetCacheEnabled(boolean cacheEnabled)voidsetCacheMaxRows(Integer cacheMaxRows)voidsetClusterName(String clusterName)voidsetColumnSort(ColumnSort columnSort)voidsetIndex(String index)voidsetQuery(String query)voidsetRelevance(String relevance)voidsetServerURL(String serverURL)voidsetType(String type)StringtoString()-
Methods inherited from class org.dashbuilder.dataset.def.DataSetDef
addColumn, clone, getColumnById, getColumns, getDataSetFilter, getName, getPattern, getProperty, getPropertyNames, getProvider, getPushMaxSize, getRefreshTime, getRefreshTimeAmount, getUUID, isAllColumnsEnabled, isPublic, isPushEnabled, isRefreshAlways, setAllColumnsEnabled, setColumns, setDataSetFilter, setName, setPattern, setProperty, setProvider, setPublic, setPushEnabled, setPushMaxSize, setRefreshAlways, setRefreshTime, setUUID
-
-
-
-
Field Detail
-
serverURL
@NotNull(groups=ElasticSearchDataSetDefValidation.class) @Size(min=1, groups=ElasticSearchDataSetDefValidation.class) protected @NotNull(groups=ElasticSearchDataSetDefValidation.class) @Size(min=1,groups=ElasticSearchDataSetDefValidation.class) String serverURL
-
clusterName
protected String clusterName
-
index
@NotNull(groups=ElasticSearchDataSetDefValidation.class) @Size(min=1, groups=ElasticSearchDataSetDefValidation.class) protected @NotNull(groups=ElasticSearchDataSetDefValidation.class) @Size(min=1,groups=ElasticSearchDataSetDefValidation.class) String index
Index/es to query. Can handle multiple values, comma separated.
-
type
protected String type
Type/es to query. Can handle multiple values, comma separated. Not mandatory.
-
query
protected String query
-
relevance
protected String relevance
-
columnSort
protected ColumnSort columnSort
-
-
Method Detail
-
getServerURL
public String getServerURL()
-
setServerURL
public void setServerURL(String serverURL)
-
getClusterName
public String getClusterName()
-
setClusterName
public void setClusterName(String clusterName)
-
getIndex
public String getIndex()
-
setIndex
public void setIndex(String index)
-
getType
public String getType()
-
setType
public void setType(String type)
-
getQuery
public String getQuery()
-
setQuery
public void setQuery(String query)
-
getRelevance
public String getRelevance()
-
setRelevance
public void setRelevance(String relevance)
-
isCacheEnabled
public boolean isCacheEnabled()
- Overrides:
isCacheEnabledin classDataSetDef
-
setCacheEnabled
public void setCacheEnabled(boolean cacheEnabled)
- Overrides:
setCacheEnabledin classDataSetDef
-
getCacheMaxRows
public Integer getCacheMaxRows()
- Overrides:
getCacheMaxRowsin classDataSetDef
-
setCacheMaxRows
public void setCacheMaxRows(Integer cacheMaxRows)
- Overrides:
setCacheMaxRowsin classDataSetDef
-
getColumnSort
public ColumnSort getColumnSort()
-
setColumnSort
public void setColumnSort(ColumnSort columnSort)
-
equals
public boolean equals(Object obj)
- Overrides:
equalsin classDataSetDef
-
hashCode
public int hashCode()
- Overrides:
hashCodein classDataSetDef
-
clone
public DataSetDef clone()
- Overrides:
clonein classDataSetDef
-
-