Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions alertmanager/alerts.go
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,7 @@ func taskFailureCheck(al *alerts) {
for name, count := range tmap {
if contains(sealingTasks, name) {
al.alertMap[Name].alertString += fmt.Sprintf("Task: %s, Failures: %d. ", name, count)
}
if count > 5 {
} else if count > 5 {
al.alertMap[Name].alertString += fmt.Sprintf("Task: %s, Failures: %d. ", name, count)
}
}
Expand Down
232 changes: 116 additions & 116 deletions cmd/curio/internal/translations/catalog.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions cmd/curio/internal/translations/locales/en/out.gotext.json
Original file line number Diff line number Diff line change
Expand Up @@ -339,9 +339,9 @@
"fuzzy": true
},
{
"id": "Command separated list of hostnames for yugabyte cluster",
"message": "Command separated list of hostnames for yugabyte cluster",
"translation": "Command separated list of hostnames for yugabyte cluster",
"id": "Comma-separated list of hostnames for yugabyte cluster",
"message": "Comma-separated list of hostnames for yugabyte cluster",
"translation": "Comma-separated list of hostnames for yugabyte cluster",
"translatorComment": "Copied from source.",
"fuzzy": true
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1469,9 +1469,9 @@
"placeholder": null
},
{
"id": "Command separated list of hostnames for yugabyte cluster",
"id": "Comma-separated list of hostnames for yugabyte cluster",
"translation": "유가바이트 클러스터의 호스트 이름을 쉼표로 구분한 목록",
"message": "Command separated list of hostnames for yugabyte cluster",
"message": "Comma-separated list of hostnames for yugabyte cluster",
"placeholder": null
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1439,9 +1439,9 @@
"placeholder": null
},
{
"id": "Command separated list of hostnames for yugabyte cluster",
"id": "Comma-separated list of hostnames for yugabyte cluster",
"translation": "Yugabyte 集群的主机名命令分隔列表",
"message": "Command separated list of hostnames for yugabyte cluster",
"message": "Comma-separated list of hostnames for yugabyte cluster",
"placeholder": null
},
{
Expand Down
4 changes: 2 additions & 2 deletions cmd/curio/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,13 +128,13 @@ func main() {
&cli.StringFlag{
Name: "db-host",
EnvVars: []string{"CURIO_DB_HOST", "CURIO_HARMONYDB_HOSTS"},
Usage: translations.T("Command separated list of hostnames for yugabyte cluster"),
Usage: translations.T("Comma-separated list of hostnames for yugabyte cluster"),
Value: "127.0.0.1",
},
&cli.StringFlag{
Name: "db-host-cql",
EnvVars: []string{"CURIO_DB_HOST_CQL"},
Usage: translations.T("Command separated list of hostnames for yugabyte cluster"),
Usage: translations.T("Comma-separated list of hostnames for yugabyte cluster"),
Value: "",
DefaultText: "<--db-host>",
},
Expand Down
4 changes: 2 additions & 2 deletions documentation/en/curio-cli/curio.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ COMMANDS:

GLOBAL OPTIONS:
--color use color in display output (default: depends on output being a TTY)
--db-host value Command separated list of hostnames for yugabyte cluster (default: "127.0.0.1") [$CURIO_DB_HOST, $CURIO_HARMONYDB_HOSTS]
--db-host-cql value Command separated list of hostnames for yugabyte cluster (default: <--db-host>) [$CURIO_DB_HOST_CQL]
--db-host value Comma-separated list of hostnames for yugabyte cluster (default: "127.0.0.1") [$CURIO_DB_HOST, $CURIO_HARMONYDB_HOSTS]
--db-host-cql value Comma-separated list of hostnames for yugabyte cluster (default: <--db-host>) [$CURIO_DB_HOST_CQL]
--db-name value Name of the Postgres database in Yugabyte cluster (default: "yugabyte") [$CURIO_DB_NAME, $CURIO_HARMONYDB_NAME]
--db-user value Username for connecting to the Postgres database in Yugabyte cluster (default: "yugabyte") [$CURIO_DB_USER, $CURIO_HARMONYDB_USERNAME]
--db-password value Password for connecting to the Postgres database in Yugabyte cluster (default: "yugabyte") [$CURIO_DB_PASSWORD, $CURIO_HARMONYDB_PASSWORD]
Expand Down
2 changes: 1 addition & 1 deletion tasks/indexing/task_ipni.go
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,7 @@ func (I *IPNITask) schedule(ctx context.Context, taskFunc harmonytask.AddTaskFun

n, err := tx.Exec(`INSERT INTO ipni_peerid (sp_id, priv_key, peer_id) VALUES ($1, $2, $3) ON CONFLICT(sp_id) DO NOTHING `, p.SpID, privKey, pid.String())
if err != nil {
return false, xerrors.Errorf("failed to to insert the key into DB: %w", err)
return false, xerrors.Errorf("failed to insert the key into DB: %w", err)
}

if n == 0 {
Expand Down
2 changes: 1 addition & 1 deletion tasks/indexing/task_pdp_ipni.go
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ func (P *PDPIPNITask) schedule(ctx context.Context, taskFunc harmonytask.AddTask

n, err := tx.Exec(`INSERT INTO ipni_peerid (sp_id, priv_key, peer_id) VALUES ($1, $2, $3) ON CONFLICT(sp_id) DO NOTHING `, -1, privKey, pid.String())
if err != nil {
return false, xerrors.Errorf("failed to to insert the key into DB: %w", err)
return false, xerrors.Errorf("failed to insert the key into DB: %w", err)
}

if n == 0 {
Expand Down
2 changes: 2 additions & 0 deletions web/api/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,12 +157,14 @@ func getSch(w http.ResponseWriter, r *http.Request) {
}
allOpt(sch)

w.Header().Set("Content-Type", "application/json")
apihelper.OrHTTPFail(w, json.NewEncoder(w).Encode(sch))
}

func (c *cfg) getLayers(w http.ResponseWriter, r *http.Request) {
var layers []string
apihelper.OrHTTPFail(w, c.DB.Select(context.Background(), &layers, `SELECT title FROM harmony_config ORDER BY title`))
w.Header().Set("Content-Type", "application/json")
apihelper.OrHTTPFail(w, json.NewEncoder(w).Encode(layers))
}

Expand Down
Loading
Loading