Skip to content

ericbrisrubio/queuepublisher

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Package to publish jobs to queues that are being used by any kind of worker. Available implementations at the moment:

Installation

got get github.com/ericbrisrubio/queuepublisher

Example

package main

import (
    publisher "github.com/ericbrisrubio/queuepublisher"
    _ "github.com/kavu/go-resque/go-redis" // Redis client from godis package
)


func main() {
    enqueuer := publisher.FactoryEnqueuer("resque", "<dbhost>", "<dbport>", "<dbname>", "<dbpass>", <use ssl connection>)
    enqueuer.PublishToQueue("<queueName>", "<className>", <data>)

}

Developer notes:

  • In case a new implementation needs to be added just implement IQueuePublisher interface
  • Add a new case to the switch in factoryEnqueuer.go file

MIT LICENSE

About

Workers Queue Jobs Publisher

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages