-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bd16234
commit d8b7dbb
Showing
8 changed files
with
206 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package repository | ||
|
||
import "errors" | ||
|
||
|
||
var ( | ||
IndexNameEmptyStringError = errors.New("index name cannot be empty string") | ||
IndexAlreadyExistsError = errors.New("elasticsearch index already exists") | ||
ESInstanceError = errors.New("elasticsearch goes down") | ||
) | ||
|
||
type Search struct { | ||
Id int `json:"id" example:"1"` // UserId | ||
Name string `json:"name" example:"John"` // Name | ||
Age int `json:"age" example:"10"` // Age | ||
} | ||
|
||
|
||
type APIError struct { | ||
ErrorCode int | ||
ErrorMessage string | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.