Skip to content

Commit

Permalink
fix: Remove x-alternatives that don't exist (#278)
Browse files Browse the repository at this point in the history
* fix: Remove x-alternatives that don't exist
* fix: Cut ProviderPolicy from App Pass-through
  • Loading branch information
jlacivita authored Jun 13, 2024
1 parent fe8a895 commit e38ad5a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -216,32 +216,18 @@ If the value was composed into the platform method result under a matching prope
Finally the platform **MUST** dispatch the notification to the app that registered for the event via the original platform method, using all but the last parameter as context.

## 5. Provider Candidates
The Firebolt Device Manifist **MUST** have a list of `ProviderPolicy` configurations that map capabilities to policies for determining candidate providers:

```json
{
"providerPolicies": [
{
"inFocus": true,
"capabilities": [
"xrn:firebolt:capability:foo:bar"
]
}
]
}
```
The policy **MUST** have a list of capabilities that it is applied to.

A capability **MUST NOT** be included in more than one policy.

The policy **MAY** have an `inFocus` boolean.

If the policy has `inFocus` set to `true` then any app without RCU input focus when the capability is invoked **MUST NOT** be considered a candidate.
When a platform method with an `x-provided-by` extension is called, then
all loaded apps that have permission to provide the capability **MUST** be
considered as candidates to fulfill the method.

## 6. Best Candidate
If there is only one candidate then it **MUST** be the best candidate.
Any provider candidates that have not registered to provide the method in
question **MUST NOT** be considered the best candidate and removed from
consideration.

If there is only one candidate left then it **MUST** be the best candidate.

If there is more than one candidate, then the candidate app that most recently had RCU input focus **MUST** be the best candidate.
If there is more than one candidate left, then the candidate app that most recently had RCU input focus **MUST** be the best candidate.

If none of the candidates have had focus yet, then the candidate app that was most recently launched **MUST** be the best candidate.

Expand Down
6 changes: 2 additions & 4 deletions src/openrpc/discovery.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,7 @@
"x-provides": "xrn:firebolt:capability:discovery:entity-info"
},
{
"name": "deprecated",
"x-alternative": "Discovery.details"
"name": "deprecated"
}
],
"summary": "Provide information about a program entity and its available watchable assets, such as entitlement status and price, via either a push or pull call flow.",
Expand Down Expand Up @@ -430,8 +429,7 @@
"x-provides": "xrn:firebolt:capability:discovery:purchased-content"
},
{
"name": "deprecated",
"x-alternative": "Discovery.purchases"
"name": "deprecated"
}
],
"summary": "Provide a list of purchased content for the authenticated account, such as rentals and electronic sell through purchases.",
Expand Down

0 comments on commit e38ad5a

Please sign in to comment.