Sha256: aeccabf6055ec299f814f550f2423601b77243a19f373da344498121e65871ab

Contents?: true

Size: 1.03 KB

Versions: 2

Compression:

Stored size: 1.03 KB

Contents

# pheme [![CircleCI](https://circleci.com/gh/wealthsimple/pheme.svg?style=svg&circle-token=76942be0b1712ac066627be264886ee18039ad11)](https://circleci.com/gh/wealthsimple/pheme)

Ruby SNS publisher + SQS poller & message handler

## Installation

Add this line to your application's `Gemfile`:

```ruby
gem 'pheme'
```

And then execute:
```bash
$ bundle
```

## Configuration

```ruby
# Initializer
aws_config = {
  credentials: Aws::Credentials.new('YOUR_ACCESS_KEY_ID', 'YOUR_SECRET_ACCESS_KEY'),
  region: 'us-east-1', # Enter your AWS region here
}
Aws.config.update(aws_config)
AWS_SNS_CLIENT = Aws::SNS::Client.new(aws_config)
AWS_SQS_CLIENT = Aws::SQS::Client.new(aws_config)

Pheme.configure do |config|
  config.sqs_client = AWS_SQS_CLIENT
  config.sns_client = AWS_SNS_CLIENT
  config.logger = Logger.new(STDOUT) # Optionally replace with your app logger, e.g. `Rails.logger`
end
```

# usage

See https://github.com/wealthsimple/pheme/tree/master/spec/support for example implementations of each class.

TODO: write better usage instructions.

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
pheme-3.0.1 README.md
pheme-3.0.0 README.md