add more stream

This commit is contained in:
namhq1989 2022-12-16 10:47:20 +07:00
parent 92b0b45ec7
commit 21a288d927
2 changed files with 16 additions and 20 deletions

View File

@ -1,9 +1,19 @@
package natsio
var Stream = struct {
Selly string
Selly string
User string
HelpCenter string
Order string
Withdrawal string
Jobs string
}{
Selly: "selly",
Selly: "selly",
User: "user",
HelpCenter: "help_center",
Order: "order",
Withdrawal: "withdrawal",
Jobs: "jobs",
}
var SellyServer = struct {
@ -17,17 +27,3 @@ var SellyServer = struct {
SMS: "sms",
Chat: "chat",
}
var SellyService = struct {
User string
HelpCenter string
Order string
Withdrawal string
Jobs string
}{
User: "user",
HelpCenter: "help_center",
Order: "order",
Withdrawal: "withdrawal",
Jobs: "jobs",
}

View File

@ -21,13 +21,13 @@ func combineStreamAndSubjectName(stream, subject string) string {
}
// GenerateJetStreamSubject ...
func GenerateJetStreamSubject(stream, server, service, subject string) string {
return fmt.Sprintf("%s.jetstream.%s.%s.%s", stream, server, service, subject)
func GenerateJetStreamSubject(stream, server, subject string) string {
return fmt.Sprintf("%s.jetstream.%s.%s", stream, server, subject)
}
// GenerateReqrepSubject ...
func GenerateReqrepSubject(stream, server, service, subject string) string {
return fmt.Sprintf("%s.reqrep.%s.%s.%s", stream, server, service, subject)
func GenerateReqrepSubject(stream, server, subject string) string {
return fmt.Sprintf("%s.reqrep.%s.%s", stream, server, subject)
}
// InterfaceToBytes ...