Skip to content

Releases: meilisearch/meilisearch-go

v0.26.3 🐹

06 May 14:16
407897c
Compare
Choose a tag to compare

🚀 Enhancements

🐛 Bug Fixes

⚙️ Maintenance/misc

Thanks again to @LGXerxes, @Tommy-42, @brunoocasali, @curquiza, @jackielii, @thisisdev-patrick! 🎉

v0.26.2 🐹

19 Feb 09:53
0188a2d
Compare
Choose a tag to compare

🚀 Enhancements

  • Enable to use DeleteDocumentsByFilter through IndexInterface (#511) @yuku

Thanks again to and @yuku! 🎉

v0.26.1 🐹

17 Jan 11:18
a893ec8
Compare
Choose a tag to compare

🚀 Enhancements

⚙️ Maintenance/misc

  • Update tests related to the next Meilisearch release (v1.6.0) (#503)

Thanks again to @brunoocasali, @curquiza, @fitimvata, ! 🎉

v0.26.0 🐹

02 Nov 16:29
d0a4910
Compare
Choose a tag to compare

⚠️ Breaking changes: Enhanced Enumeration for Task Types & Statuses

The Meilisearch Go client has undergone a significant enhancement in how it handles task types and statuses. In prior versions, developers interfaced with tasks using generic strings. This methodology, while functional, lacked clarity and posed maintenance challenges.

TaskType and TaskStatus have transitioned from generic strings to definitive constants. This change augments code clarity, minimizes potential errors, and paves the way for smoother future updates.

Quick Exemple

// Before:
taskType := "documentDeletion"
...

// After:
taskType := meilisearch.TaskTypeDocumentDeletion

Real world example

// Before:
func Before() {
	resp, _ := meilisearchClient.GetTasks(&meilisearch.TasksQuery{
		Statuses: []string("enqueued", "processing"),
		Types: []string("documentDeletion", "documentAdditionOrUpdate"),
	})

	for _, task := range resp.Results {
		if task.Status == "processing" {
			// ...
		}

		if task.Type == "documentDeletion" {
			// ...
		}
	}
}

// After:
func After() {
	resp, _ := meilisearchClient.GetTasks(&meilisearch.TasksQuery{
		Statuses: []meilisearch.TaskStatus{
			meilisearch.TaskStatusEnqueued,
			meilisearch.TaskStatusProcessing,
		},
		Types: []meilisearch.TaskType{
			meilisearch.TaskTypeDocumentDeletion,
			meilisearch.TaskTypeDocumentAdditionOrUpdate,
		},
	})

	for _, task := range resp.Results {
		if task.Status == meilisearch.TaskStatusProcessing {
			// ...
		}

		if task.Type == meilisearch.TaskTypeDocumentDeletion {
			// ...
		}
	}
}

🚀 Enhancements

  • Make client.WaitForTask use select and channels for polling (#495) @tadejsv

Thanks again to @42atomys, @curquiza, @datbeohbbh, and @tadejsv! 🎉

v0.25.1 🐹

13 Sep 17:49
252c1fb
Compare
Choose a tag to compare

🚀 Enhancements

🐛 Bug Fixes

Thanks again to @Azanul, @Esmeralda-lad, @alallema, @aooohan, @barribarrier, @brunoocasali, @curquiza, @luigibarbato, @manujz, and @tonyghouse! 🎉

v0.25.0 🐹

05 Jun 11:57
e6ebf2f
Compare
Choose a tag to compare

Release CHANGELOG:

This version introduces features released on Meilisearch v1.2.0 🎉
Check out the changelog of Meilisearch v1.2.0 for more information on the changes.
⚠️ If you want to adopt new features of this release, update the Meilisearch server to the according version.

🚀 Enhancements

  • Addition of the method DeleteDocumentsByFilter, this method takes an interface{} which allows you to send different types of filters (string, []string, []interface{}{[]string{}}, ...). The filter field works precisely like the filter field used on the search method. See the docs on how to use filters. #440 @alallema

    ⚠️ You must configure the attributes you want to filter using the Index.UpdateFilterableAttributes().
    ⚠️ Remember to update your Meilisearch server to v1.2.0 or newer before adopting it.

  • Add the ability to add Filter in the DocumentsQuery. When a query with a filter is sent to getDocuments, it will filter the documents like the search method. See the docs on how to use filters. #439 @alallema

    ⚠️ You must configure the attributes you want to filter using the Index.UpdateFilterableAttributes().
    ⚠️ Remember to update your Meilisearch server to v1.2.0 or newer before adopting it.

Thanks again to @alallema, @curquiza ! 🎉

v0.24.0 🐹

03 Apr 10:00
9576ecf
Compare
Choose a tag to compare

This version introduces features released on Meilisearch v1.1.0 🎉
Check out the changelog of Meilisearch v1.1.0 for more information on the changes.

🐛 Bug Fixes

⚠️ Breaking changes

  • Add the ability to provide a specific csv-delimiter when adding and updating documents in CSV format (#424) @alallema
    • New type CsvDocumentsQuery{}
    • Changed AddDocumentsCsv() which takes CsvDocumentsQuery as a parameter instead of a ...string
    • Changed AddDocumentsCsvInBatches() which takes CsvDocumentsQuery as a parameter instead of a ...string
    • Changed UpdateDocumentsCsv() which takes CsvDocumentsQuery as a parameter instead of a ...string
    • Changed UpdateDocumentsCsvInBatches() which takes CsvDocumentsQuery as a parameter instead of a ...string

🚀 Enhancements

  • Add FacetStats field in SearchResponse (#423) @alallema
  • New method client.MultiSearch() provides the possibility to make multiple requests at once (#422) @alallema

Example:

  client.MultiSearch(&MultiSearchRequest{
    Queries: []SearchRequest{
      {
        IndexUID: "movies",
        Query:    "pooh",
        Limit:    5,
      },
      {
        IndexUID: "movies",
        Query:    "nemo",
        Limit:    5,
      },
      {
        IndexUID: "movie_ratings",
        Query:    "us",
      },
    },
  })

Thanks again to @alallema, @candiduslynx ! 🎉

v0.23.1 🐹

16 Mar 12:22
18e9a55
Compare
Choose a tag to compare

🚀 Enhancements

  • Implement UpdateDocument methods for CSV & NdJson (#408) @Azanul
    • UpdateDocumentsCsv
    • UpdateDocumentsCsvInBatches
    • UpdateDocumentsNdjson
    • UpdateDocumentsNdjsonInBatches

🐛 Bug Fixes

  • Avoid panic when sending (...[]string{}) in AddDocument() (#417) @bestgopher

Thanks again to @Azanul, @alallema, @bestgopher, @brunoocasali! 🎉

v0.23.0 🐹

06 Feb 12:07
44d5e4f
Compare
Choose a tag to compare

This version makes this package compatible with Meilisearch v1.0.0 🎉
Check out the changelog of Meilisearch vv1.0.0 for more information on the changes(#405).

⚠️ Breaking changes

  • KeyParsed struct has been changed; this structure is used to manage the time format when creating a key, however, all the Key fields were available in the structure, while only those used to create a key should be available in it.
    • createdAt has been removed
    • updatedAt has been removed

Thanks again to @Thearas, @alallema, @bidoubiwa! 🎉

v0.22.0 🐹

15 Dec 12:44
3811df6
Compare
Choose a tag to compare

This version makes this package compatible with Meilisearch v0.30.0 🎉
Check out the changelog of Meilisearch v0.30.0 for more information on the changes(#382).

⚠️ Breaking change

  • Parameters on GetTasks name changes: #390
    • Status -> Statuses
    • IndexUID -> IndexUIDS
    • Type -> Types

🚀 Enhancements

  • New pagination strategy with the search parameters Page and HitsPerPage #392
  • New filters on GetTasks: UID, BeforeEnqueuedAt, AfterEnqueuedAt, ... see #390
  • New client.CancelTasks method that lets you cancel enqueued and processing tasks #395
  • New client.DeleteTasks method that lets you delete tasks #396
  • New client.SwapIndexes method that lets you swap two indexes #397
  • New fields on Task.Details #395

Thanks again to @alallema! 🎉