elastirad

package module
v0.4.16 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 24, 2023 License: MIT Imports: 5 Imported by: 0

README

Elastirad: A Go Client Wrapper for Elasticsearch

Build Status Go Report Card Docs License

Simple client to query Elasticsearch API using HTTP API documentation. This is inspired by the Elastirad Ruby gem.

Usage

See the sample code in the docs folder.

So far the following example code has been created:

  1. Create Index: Go code, ES docs
  2. Index Docs: Go code, ES docs
  3. Bool Query: Go code, ES docs
  4. Terms Aggregation: Go code, ES docs

Documentation

Index

Constants

View Source
const (
	// ElasticsearchAPIDefaultScheme is the HTTP scheme for the default server.
	ElasticsearchAPIDefaultScheme string = "https"
	// ElasticsearchAPIDefaultHost is the HTTP host for the default server.
	ElasticsearchAPIDefaultHost string = "127.0.0.1:9200"
	// ElasticsearchAPIDefaultHost is the HTTP host for the default server.
	ElasticsearchAPIDefaultURL string = "https://127.0.0.1:9200"
	// CreateSlug is the URL path part for creates.
	CreateSlug string = "_create"
	// UpdateSlug is the URL path part for updates.
	UpdateSlug string = "_update"
	// SearchSlug is the URL path part for search.
	SearchSlug string = "_search"
)

Variables

This section is empty.

Functions

func NewSimpleClient added in v0.4.0

func NewSimpleClient(serverURL, username, password string, allowInsecure bool) (httpsimple.Client, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL