Skip to content

Commit

Permalink
chore(gcp): add deprecation info
Browse files Browse the repository at this point in the history
  • Loading branch information
flowerinthenight committed Mar 29, 2024
1 parent 33638ee commit f759ddd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions gcppubsub/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ func GetSubscription(project, id string, topic *gpubsub.Topic, ackdeadline ...ti
}

// GetPublisher is a simple wrapper to create a PubSub publisher using gizmo's Publisher interface.
//
// Deprecated: The gizmo package used in this function is now unmaintained.
func GetPublisher(project, id string) (zpubsub.MultiPublisher, *gpubsub.Topic, error) {
ctx := context.Background()
// Ensure that it exists.
Expand Down Expand Up @@ -114,6 +116,7 @@ func (p *PubsubPublisher) Publish(key string, data interface{}) error {

func (p *PubsubPublisher) RawTopic() *gpubsub.Topic { return p.rt }

// Deprecated: The gizmo package used in this function is now unmaintained.
func NewPubsubPublisher(projectId string, topicname string) (*PubsubPublisher, error) {
// Make sure the publisher is created if it doesn't exist.
cp, t, err := GetPublisher(projectId, topicname)
Expand Down

0 comments on commit f759ddd

Please sign in to comment.