define communication, warehouse func #5

Merged
luuvansinh merged 9 commits from define-communication-func into master 2022-08-24 02:42:24 +00:00
1 changed files with 2 additions and 1 deletions
Showing only changes of commit fcc9099533 - Show all commits

View File

@ -4,6 +4,7 @@ import (
"encoding/json" "encoding/json"
"github.com/Selly-Modules/natsio" "github.com/Selly-Modules/natsio"
"github.com/Selly-Modules/natsio/model"
"github.com/Selly-Modules/natsio/subject" "github.com/Selly-Modules/natsio/subject"
) )
@ -16,7 +17,7 @@ func GetCommunication() Communication {
} }
// RequestHttp ... // RequestHttp ...
func (c Communication) RequestHttp(p communication.CommunicationRequestHttp) (r *communication.CommunicationHttpResponse, err error) { func (c Communication) RequestHttp(p model.CommunicationRequestHttp) (r *model.CommunicationHttpResponse, err error) {
msg, err := natsio.GetServer().Request(subject.CommunicationRequestHTTP, toBytes(p)) msg, err := natsio.GetServer().Request(subject.CommunicationRequestHTTP, toBytes(p))
if err != nil { if err != nil {
return nil, err return nil, err