You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a service when I use golang.org/x/sys/windows/svc to create my api as window service. This works perfect.
I was able to follow this How to use Golang client on Windows #128 and thats work to. I can consume, produce my api work as I want. I can use both librerys and when I run the service in debug mode everything is fine. But when the api is a window service the service dont start I got a 1053 error message. I was running several test and I can say the service dont work when I use the confluent librery. I know that because this librery dont support window something is missing when .exe run as service but I can figure out what it is.
How to reproduce
I make a little program apart from my main project. Justo copy and paste the example from here golang.org/x/sys/windows/svc and add a consumer from confluent.
This what i have in the Excute function
const cmdsAccepted = svc.AcceptStop | svc.AcceptShutdown | svc.AcceptPauseAndContinue
changes <- svc.Status{State: svc.StartPending}
Unlike many projects, the Go project does not use GitHub Issues for general discussion or asking questions. GitHub Issues are used for tracking bugs and proposals only.
I have a service when I use golang.org/x/sys/windows/svc to create my api as window service. This works perfect.
I was able to follow this How to use Golang client on Windows #128 and thats work to. I can consume, produce my api work as I want. I can use both librerys and when I run the service in debug mode everything is fine. But when the api is a window service the service dont start I got a 1053 error message. I was running several test and I can say the service dont work when I use the confluent librery. I know that because this librery dont support window something is missing when .exe run as service but I can figure out what it is.
How to reproduce
I make a little program apart from my main project. Justo copy and paste the example from here golang.org/x/sys/windows/svc and add a consumer from confluent.
This what i have in the Excute function
const cmdsAccepted = svc.AcceptStop | svc.AcceptShutdown | svc.AcceptPauseAndContinue
changes <- svc.Status{State: svc.StartPending}
if _, err := os.Stat(".\LOGSmsPrueba"); os.IsNotExist(err) {
os.MkdirAll(".\LOGSmsPrueba", 0700)
}
filelogs, _ := os.OpenFile(".\LOGSmsPrueba\LOGS.log", os.O_APPEND|os.O_CREATE|os.O_RDWR, 0644)
//writerLog := zerolog.MultiLevelWriter(filelogs)
defer filelogs.Close()
log := zerolog.New(filelogs).With().Logger()
log.Debug().Msg("Before The Thread Of Consumer")
go func() {
}()
changes <- svc.Status{State: svc.Running, Accepts: cmdsAccepted}
loop:
for {
select {
}
changes <- svc.Status{State: svc.StopPending}
return
Checklist
librdkafka Version: 1.7.0
confluent-kafka-go Version:1.7.0
&kafka.ConfigMap{
"bootstrap.servers": "localhost:9092",
golang.org/x/sys v0.0.0-20210615035016
The text was updated successfully, but these errors were encountered: