@dxos/functions 0.8.4-staging.60fe92afc8 → 0.9.1-main.c7dcc2e112

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/functions",
3
- "version": "0.8.4-staging.60fe92afc8",
3
+ "version": "0.9.1-main.c7dcc2e112",
4
4
  "description": "Functions API.",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -30,20 +30,20 @@
30
30
  "@effect/ai-anthropic": "0.26.0",
31
31
  "@effect/platform": "0.96.1",
32
32
  "effect": "3.21.3",
33
- "@dxos/ai": "0.8.4-staging.60fe92afc8",
34
- "@dxos/echo": "0.8.4-staging.60fe92afc8",
35
- "@dxos/context": "0.8.4-staging.60fe92afc8",
36
- "@dxos/compute": "0.8.4-staging.60fe92afc8",
37
- "@dxos/echo-client": "0.8.4-staging.60fe92afc8",
38
- "@dxos/effect": "0.8.4-staging.60fe92afc8",
39
- "@dxos/invariant": "0.8.4-staging.60fe92afc8",
40
- "@dxos/keys": "0.8.4-staging.60fe92afc8",
41
- "@dxos/log": "0.8.4-staging.60fe92afc8",
42
- "@dxos/errors": "0.8.4-staging.60fe92afc8",
43
- "@dxos/protocols": "0.8.4-staging.60fe92afc8",
44
- "@dxos/node-std": "0.8.4-staging.60fe92afc8",
45
- "@dxos/schema": "0.8.4-staging.60fe92afc8",
46
- "@dxos/types": "0.8.4-staging.60fe92afc8"
33
+ "@dxos/ai": "0.9.1-main.c7dcc2e112",
34
+ "@dxos/compute": "0.9.1-main.c7dcc2e112",
35
+ "@dxos/echo": "0.9.1-main.c7dcc2e112",
36
+ "@dxos/echo-client": "0.9.1-main.c7dcc2e112",
37
+ "@dxos/effect": "0.9.1-main.c7dcc2e112",
38
+ "@dxos/errors": "0.9.1-main.c7dcc2e112",
39
+ "@dxos/invariant": "0.9.1-main.c7dcc2e112",
40
+ "@dxos/keys": "0.9.1-main.c7dcc2e112",
41
+ "@dxos/context": "0.9.1-main.c7dcc2e112",
42
+ "@dxos/log": "0.9.1-main.c7dcc2e112",
43
+ "@dxos/node-std": "0.9.1-main.c7dcc2e112",
44
+ "@dxos/protocols": "0.9.1-main.c7dcc2e112",
45
+ "@dxos/schema": "0.9.1-main.c7dcc2e112",
46
+ "@dxos/types": "0.9.1-main.c7dcc2e112"
47
47
  },
48
48
  "publishConfig": {
49
49
  "access": "public"
@@ -20,13 +20,7 @@ import {
20
20
  } from '@dxos/compute';
21
21
  import { LifecycleState, Resource } from '@dxos/context';
22
22
  import { Database, Feed, JsonSchema, Ref, Registry, type Type } from '@dxos/echo';
23
- import {
24
- createFeedServiceLayer,
25
- EchoClient,
26
- type DatabaseImpl,
27
- makeRegistry,
28
- type QueueFactory,
29
- } from '@dxos/echo-client';
23
+ import { createFeedServiceLayer, EchoClient, type DatabaseImpl, makeRegistry } from '@dxos/echo-client';
30
24
  import { refFromEncodedReference } from '@dxos/echo/internal';
31
25
  import { EffectEx } from '@dxos/effect';
32
26
  import { assertState, failedInvariant, invariant } from '@dxos/invariant';
@@ -158,7 +152,6 @@ class FunctionContext extends Resource {
158
152
  readonly context: FunctionProtocol.Context;
159
153
  readonly client: EchoClient | undefined;
160
154
  db: DatabaseImpl | undefined;
161
- queues: QueueFactory | undefined;
162
155
  readonly opts: FunctionWrappingOptions;
163
156
 
164
157
  constructor(context: FunctionProtocol.Context, opts: FunctionWrappingOptions) {
@@ -188,8 +181,6 @@ class FunctionContext extends Resource {
188
181
 
189
182
  await this.db?.setSpaceRoot(this.context.spaceRootUrl ?? failedInvariant('spaceRootUrl missing in context'));
190
183
  await this.db?.open();
191
- this.queues =
192
- this.client && this.context.spaceId ? this.client.constructQueueFactory(this.context.spaceId) : undefined;
193
184
  }
194
185
 
195
186
  override async _close() {
@@ -201,7 +192,7 @@ class FunctionContext extends Resource {
201
192
  assertState(this._lifecycleState === LifecycleState.OPEN, 'FunctionContext is not open');
202
193
 
203
194
  const dbLayer = this.db ? Database.layer(this.db) : Database.notAvailable;
204
- const feedLayer = this.queues ? createFeedServiceLayer(this.queues) : Feed.notAvailable;
195
+ const feedLayer = this.db ? createFeedServiceLayer(this.db) : Feed.notAvailable;
205
196
  const credentials = dbLayer
206
197
  ? credentialsLayerFromDatabase({ caching: true }).pipe(Layer.provide(dbLayer))
207
198
  : configuredCredentialsLayer([]);