ably-pubsub-server 0.0.1.pre → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +4 -1
- data/lib/ably/pubsub/server/version.rb +1 -1
- data/lib/ably/pubsub/server.rb +9 -8
- metadata +4 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 6e3fa81f26756e074238bdf824745846f0573e1dfba3baec097f63a51d68128f
|
|
4
|
+
data.tar.gz: 1c19771e02b4a261e3ccd631cdabda8a3dc96cb04b201338dc03a9f7309b25d7
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: fcfe71f310b430264d3e69c7626723b2ab1ffca3a2f5eb0d5f8e7de6f27a1e5a68ed21a6a70a9800eea954019fb459937fd4d0e1e47f44dbbd8ffd95647af18f
|
|
7
|
+
data.tar.gz: 72fa578bc1ac78b35fe0d7455b3aedb8b6d007168fbb4bd31ba5e8475c46660eb25025fa0c3e039708e44b46ef4a257538404ce513f9ddc66add70ec5d6a18df
|
data/README.md
CHANGED
|
@@ -13,7 +13,10 @@ gem 'ably-pubsub-server'
|
|
|
13
13
|
|
|
14
14
|
## Usage
|
|
15
15
|
|
|
16
|
-
The factory functions are the only
|
|
16
|
+
The factory functions are the only entry points. The client classes refuse direct
|
|
17
|
+
construction — `Ably::PubSub::Http::Client.new` and `Ably::PubSub::Realtime::Client.new` raise
|
|
18
|
+
`Ably::Exceptions::DirectConstructionNotSupported` — because the package a client is
|
|
19
|
+
created from is what declares its side, and a directly constructed client declares none.
|
|
17
20
|
|
|
18
21
|
```ruby
|
|
19
22
|
require 'ably/pubsub/server'
|
data/lib/ably/pubsub/server.rb
CHANGED
|
@@ -3,8 +3,9 @@ require 'ably/pubsub/server/version'
|
|
|
3
3
|
|
|
4
4
|
module Ably
|
|
5
5
|
module PubSub
|
|
6
|
-
# The Ably Pub/Sub SDK for servers. The factory functions here are the only
|
|
7
|
-
#
|
|
6
|
+
# The Ably Pub/Sub SDK for servers. The factory functions here are the only entry
|
|
7
|
+
# points of the +ably-pubsub-server+ gem: the client classes refuse direct construction
|
|
8
|
+
# (see {Ably::Internal}), so a client always carries the side its package declares.
|
|
8
9
|
module Server
|
|
9
10
|
# The agent identifier declaring the server side.
|
|
10
11
|
#
|
|
@@ -24,22 +25,22 @@ module Ably
|
|
|
24
25
|
class << self
|
|
25
26
|
# Creates a stateless HTTP (REST) client declaring the server side.
|
|
26
27
|
#
|
|
27
|
-
# Accepts everything {Ably::
|
|
28
|
+
# Accepts everything {Ably::PubSub::Http::Client#initialize} accepts: an options Hash,
|
|
28
29
|
# an API key String, or a token String.
|
|
29
30
|
#
|
|
30
|
-
# @return [Ably::
|
|
31
|
+
# @return [Ably::PubSub::Http::Client]
|
|
31
32
|
def create_http_client(options)
|
|
32
|
-
Ably::
|
|
33
|
+
Ably::Internal.create_http_client(options_with_side_agent(options))
|
|
33
34
|
end
|
|
34
35
|
|
|
35
36
|
# Creates a stateful realtime client declaring the server side.
|
|
36
37
|
#
|
|
37
|
-
# Accepts everything {Ably::Realtime::Client#initialize} accepts: an options Hash,
|
|
38
|
+
# Accepts everything {Ably::PubSub::Realtime::Client#initialize} accepts: an options Hash,
|
|
38
39
|
# an API key String, or a token String.
|
|
39
40
|
#
|
|
40
|
-
# @return [Ably::Realtime::Client]
|
|
41
|
+
# @return [Ably::PubSub::Realtime::Client]
|
|
41
42
|
def create_realtime_client(options)
|
|
42
|
-
Ably::
|
|
43
|
+
Ably::Internal.create_realtime_client(options_with_side_agent(options))
|
|
43
44
|
end
|
|
44
45
|
|
|
45
46
|
private
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ably-pubsub-server
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0
|
|
4
|
+
version: 2.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ably
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-10-28 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: ably-pubsub-core
|
|
@@ -16,14 +16,14 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - '='
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: 0.0
|
|
19
|
+
version: 2.0.0
|
|
20
20
|
type: :runtime
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
24
24
|
- - '='
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: 0.0
|
|
26
|
+
version: 2.0.0
|
|
27
27
|
description: 'Ably Pub/Sub client for servers: backend services and other trusted
|
|
28
28
|
runtimes. Construct clients with Ably::PubSub::Server.create_http_client or Ably::PubSub::Server.create_realtime_client.'
|
|
29
29
|
email:
|