Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into pay-2842-manager-mode…
Browse files Browse the repository at this point in the history
…-pay-and-earn

* origin/main:
  Create Apps Dev Docs link updated (#8492)
  Fix typos (#8620)
  Fix album tile playback (#8637)
  [C-4451] Add feature flag and switch for edit track redesign (#8639)
  Fix copy (#8640)
  Add DPID and party name info to distro docs (#8638)
  [C-4237] Fix create notification when track is published (#8634)
  Fix chromecast support, again (#8636)
  Audius Protocol v0.6.114
  ⚠️ [C-4416, C-4418, C-4419 C-4322] Fast SSR (#8603)
  PROTO-1846: add discovery listens status to healthz (#8631)
  [QA-1226] Add missing tier info (#8635)
  Fix first track in lineup playback issue (#8632)
  [QA-1321] Show spinner for audio balance if rpc call fails (#8630)
  [C-4417] Add a buffering metric (#8619)
  Replace structuredClone with cloneDeep for native compat (#8633)
  [PROTO-1802] Add DDEX entrypoint UI deep link (#8374)
  • Loading branch information
schottra committed May 29, 2024
2 parents f2cca27 + 67191b7 commit 4d204fb
Show file tree
Hide file tree
Showing 151 changed files with 2,417 additions and 3,026 deletions.
2 changes: 1 addition & 1 deletion docs/docs/developers/guides/create-audius-app.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ npm run dev
Applications started from `create-audius-app` leverage the [Harmony][harmony-docs] design system.

Harmony is all about collaboration, reusability, and scalability. It aims to harmonize code and
Figma, provide a shared language for designers and developers, and provide consistent, reusable
Figma, provides a shared language for designers and developers, and provide consistent, reusable
components for use across platforms.

Read more about Harmony and using it across your other projects at
Expand Down
6 changes: 3 additions & 3 deletions docs/docs/developers/guides/hedgehog.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ to lower the barrier of entry to crypto projects for non tech-savvy users.
Allow users to interact with your DApp just like they would any other website, no extensions
required, without centralizing control of keys.

Hedgehog is alternative to Metamask that manages a user's private key and wallet on the browser. It
Hedgehog is an alternative to Metamask that manages a user's private key and wallet on the browser. It
exposes a simple API to allow you to create an authentication scheme to let users sign up and login
to their wallet across multiple browsers and devices.

Expand All @@ -28,10 +28,10 @@ Decentralized apps today require lots of technical knowledge to configure and us
user base and reducing the potential for growth.

Currently available wallets treat every transaction as if it were moving around your life’s savings.
Hedgehog was built for use-cases involving low-to-no financial value.
Hedgehog was built for use cases involving low-to-no financial value.

Current Ethereum wallets treat every transaction as if it were moving your life’s savings. Hedgehog
was built for use-cases involving low-to-no financial value.
was built for use cases involving low-to-no financial value.

---

Expand Down
2 changes: 1 addition & 1 deletion docs/docs/developers/introduction/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ description: Audius Protocol Documentation
## Hedgehog

> Hedgehog is an open-source, client-side Ethereum wallet that aims to lower the barrier of entry to
> crypto projects by uses a username and password.
> crypto projects by using a username and password.
- [Learn More](/developers/guides/hedgehog) - Learn more about the motivation for a lower barrier to
entry wallet in the crypto ecosystem.
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/developers/subgraph/entities.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ Description:
| delegationSentAmount | BigInt! | The total delegation sent |
| hasStakeOrDelegation | Boolean! | Boolean set to true if the user has stake or delegation |
| validBounds | Boolean | If the user's stake is between the min/max stake |
| deployerCut | BigInt | The percentage of the claim from the delegator that the the deployer takes |
| deployerCut | BigInt | The percentage of the claim from the delegator that the deployer takes |
| services | [ServiceNode!] @derivedFrom(field: "owner") | List of services operated by the user |
| minAccountStake | BigInt | Max stake of the user as determined by number of services and service types |
| maxAccountStake | BigInt | Min stake of the user as determined by number of services and service types |
Expand Down
32 changes: 31 additions & 1 deletion docs/docs/distributors/introduction/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ documentation for guidance on how to send and administer content on Audius.
If you're looking to build your own ingestion tooling, get started with the
[Audius SDK](/developers/sdk/overview).

## What is DDEX
## What is DDEX?

Digital Data Exchange (or "DDEX") is an international standards-setting organization that was formed
in 2006 to develop standards that enable companies to communicate information along the digital
Expand Down Expand Up @@ -52,3 +52,33 @@ You may clone and self-operate your own Audius compatible DDEX ingestion server,
web interface to deliver files, manage uploads, and track success. Under the hood, DDEX ingestion
uses the [Audius SDK](/developers/sdk/overview) to process and upload tracks and is available in a
[self-service](/distributors/self-serve/overview) manner.

**Example files**

Example DDEX XML files are available on [GithHub](https://github.com/AudiusProject/audius-protocol/tree/main/packages/ddex/processor/fixtures).
* [Delivery](https://github.com/AudiusProject/audius-protocol/blob/main/packages/ddex/processor/fixtures/01_delivery.xml)
* [Update](https://github.com/AudiusProject/audius-protocol/blob/main/packages/ddex/processor/fixtures/02_update.xml)
* [Delete (Purge Message)](https://github.com/AudiusProject/audius-protocol/blob/main/packages/ddex/processor/fixtures/03_delete.xml)


---

## Partner Onboarding

When delivering content to Audius, there are two options:

1. Run open source DDEX ingestion tooling yourself, starting [here](/distributors/self-serve/overview).
2. Work directly with a partner that will accept standard DDEX XML files via private delivery (S3, SFTP) and upload releases to Audius

#### Tiki Labs, Inc.

Tiki Labs, Inc., one of the development teams behind the Audius protocol, offers a first-party service
to run DDEX ingestion tooling on behalf of partners.

In order to get started with Tiki Labs, Inc. directly, reach out to ddex-support@audius.co and submit an
[intake form](https://forms.gle/jCwLLWRJY7fCQM5ZA).

After on-boarding, you will deliver files directly to a provided S3 or SFTP bucket, which will be pushed to Audius as release criteria are met.

* **DPID**: PA-DPIDA-202401120D-9
* **Party Name**: Tiki Labs, Inc.
2 changes: 1 addition & 1 deletion docs/docs/learn/architecture/content-node.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ includes migrations, models and validations

## Redis

A [Redis client](https://redis.io/) is used for for resource locking, request rate limiting, and
A [Redis client](https://redis.io/) is used for resource locking, request rate limiting, and
limited caching and key storage.

Redis is managed in the codebase through the [ioredis npm package](https://github.com/luin/ioredis)
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/learn/architecture/discovery-node.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ A [Redis client](https://redis.io/) is used for several things in the Discovery

## Elastic Search

Elastic Search is used denormalize data and support certain queries (Feed, Search, Related Artists,
Elastic Search is used to denormalize data and supports certain queries (Feed, Search, Related Artists,
etc.). Elastic Search data is populated and kept up to date by database triggers that live on the
Postgres database.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,6 @@ If your bundler doesn't automatically polyfill node libraries (like when using c
## What's next?
- [Get authorization](https://docs.audius.org/developers/log-in-with-audius) to access your app's users' Audius accounts
- [Get authorization](https://docs.audius.org/developers/guides/log-in-with-audius) to access your app's users' Audius accounts
- [Explore the API docs](https://docs.audius.org/developers/sdk/classes/TracksApi) to see what else you can do with the Audius SDK
- [Explore the API docs](https://docs.audius.org/developers/sdk/tracks) to see what else you can do with the Audius SDK
2 changes: 1 addition & 1 deletion mediorum/.version.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"version": "0.6.113",
"version": "0.6.114",
"service": "content-node"
}
150 changes: 76 additions & 74 deletions mediorum/server/serve_health.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,43 +21,44 @@ type healthCheckResponse struct {
Timestamp time.Time `json:"timestamp"`
}
type healthCheckResponseData struct {
Healthy bool `json:"healthy"`
Version string `json:"version"`
Service string `json:"service"` // used by registerWithDelegate()
IsSeeding bool `json:"isSeeding"`
IsAudiusdManaged bool `json:"isAudiusdManaged"`
BuiltAt string `json:"builtAt"`
StartedAt time.Time `json:"startedAt"`
SPID int `json:"spID"`
SPOwnerWallet string `json:"spOwnerWallet"`
Git string `json:"git"`
AudiusDockerCompose string `json:"audiusDockerCompose"`
MediorumPathUsed uint64 `json:"mediorumPathUsed"` // bytes
MediorumPathSize uint64 `json:"mediorumPathSize"` // bytes
DatabaseSize uint64 `json:"databaseSize"` // bytes
DbSizeErr string `json:"dbSizeErr"`
LastSuccessfulRepair RepairTracker `json:"lastSuccessfulRepair"`
LastSuccessfulCleanup RepairTracker `json:"lastSuccessfulCleanup"`
UploadsCount int64 `json:"uploadsCount"`
UploadsCountErr string `json:"uploadsCountErr"`
AutoUpgradeEnabled bool `json:"autoUpgradeEnabled"`
TrustedNotifier *ethcontracts.NotifierInfo `json:"trustedNotifier"`
Env string `json:"env"`
Self Peer `json:"self"`
WalletIsRegistered bool `json:"wallet_is_registered"`
Signers []Peer `json:"signers"`
ReplicationFactor int `json:"replicationFactor"`
Dir string `json:"dir"`
BlobStorePrefix string `json:"blobStorePrefix"`
MoveFromBlobStorePrefix string `json:"moveFromBlobStorePrefix"`
ListenPort string `json:"listenPort"`
TrustedNotifierID int `json:"trustedNotifierId"`
PeerHealths map[string]*PeerHealth `json:"peerHealths"`
UnreachablePeers []string `json:"unreachablePeers"`
FailsPeerReachability bool `json:"failsPeerReachability"`
StoreAll bool `json:"storeAll"`
IsDbLocalhost bool `json:"isDbLocalhost"`
DiskHasSpace bool `json:"diskHasSpace"`
Healthy bool `json:"healthy"`
Version string `json:"version"`
Service string `json:"service"` // used by registerWithDelegate()
IsSeeding bool `json:"isSeeding"`
IsAudiusdManaged bool `json:"isAudiusdManaged"`
BuiltAt string `json:"builtAt"`
StartedAt time.Time `json:"startedAt"`
SPID int `json:"spID"`
SPOwnerWallet string `json:"spOwnerWallet"`
Git string `json:"git"`
AudiusDockerCompose string `json:"audiusDockerCompose"`
MediorumPathUsed uint64 `json:"mediorumPathUsed"` // bytes
MediorumPathSize uint64 `json:"mediorumPathSize"` // bytes
DatabaseSize uint64 `json:"databaseSize"` // bytes
DbSizeErr string `json:"dbSizeErr"`
LastSuccessfulRepair RepairTracker `json:"lastSuccessfulRepair"`
LastSuccessfulCleanup RepairTracker `json:"lastSuccessfulCleanup"`
UploadsCount int64 `json:"uploadsCount"`
UploadsCountErr string `json:"uploadsCountErr"`
AutoUpgradeEnabled bool `json:"autoUpgradeEnabled"`
TrustedNotifier *ethcontracts.NotifierInfo `json:"trustedNotifier"`
Env string `json:"env"`
Self Peer `json:"self"`
WalletIsRegistered bool `json:"wallet_is_registered"`
Signers []Peer `json:"signers"`
ReplicationFactor int `json:"replicationFactor"`
Dir string `json:"dir"`
BlobStorePrefix string `json:"blobStorePrefix"`
MoveFromBlobStorePrefix string `json:"moveFromBlobStorePrefix"`
ListenPort string `json:"listenPort"`
TrustedNotifierID int `json:"trustedNotifierId"`
PeerHealths map[string]*PeerHealth `json:"peerHealths"`
UnreachablePeers []string `json:"unreachablePeers"`
FailsPeerReachability bool `json:"failsPeerReachability"`
StoreAll bool `json:"storeAll"`
IsDbLocalhost bool `json:"isDbLocalhost"`
DiskHasSpace bool `json:"diskHasSpace"`
IsDiscoveryListensEnabled bool `json:"isDiscoveryListensEnabled"`
}

func (ss *MediorumServer) serveHealthCheck(c echo.Context) error {
Expand All @@ -83,43 +84,44 @@ func (ss *MediorumServer) serveHealthCheck(c echo.Context) error {
defer ss.peerHealthsMutex.RUnlock()

data := healthCheckResponseData{
Healthy: healthy,
Version: ss.Config.VersionJson.Version,
Service: ss.Config.VersionJson.Service,
IsSeeding: ss.isSeeding,
IsAudiusdManaged: ss.isAudiusdManaged,
BuiltAt: vcsBuildTime,
StartedAt: ss.StartedAt,
SPID: ss.Config.SPID,
SPOwnerWallet: ss.Config.SPOwnerWallet,
Git: ss.Config.GitSHA,
AudiusDockerCompose: ss.Config.AudiusDockerCompose,
MediorumPathUsed: ss.mediorumPathUsed,
MediorumPathSize: ss.mediorumPathSize,
DatabaseSize: ss.databaseSize,
DbSizeErr: ss.dbSizeErr,
LastSuccessfulRepair: ss.lastSuccessfulRepair,
LastSuccessfulCleanup: ss.lastSuccessfulCleanup,
UploadsCount: ss.uploadsCount,
UploadsCountErr: ss.uploadsCountErr,
AutoUpgradeEnabled: ss.Config.AutoUpgradeEnabled,
TrustedNotifier: ss.trustedNotifier,
Dir: ss.Config.Dir,
BlobStorePrefix: blobStorePrefix,
MoveFromBlobStorePrefix: blobStoreMoveFromPrefix,
ListenPort: ss.Config.ListenPort,
ReplicationFactor: ss.Config.ReplicationFactor,
Env: ss.Config.Env,
Self: ss.Config.Self,
WalletIsRegistered: ss.Config.WalletIsRegistered,
TrustedNotifierID: ss.Config.TrustedNotifierID,
PeerHealths: ss.peerHealths,
UnreachablePeers: ss.unreachablePeers,
FailsPeerReachability: ss.failsPeerReachability,
Signers: ss.Config.Signers,
StoreAll: ss.Config.StoreAll,
IsDbLocalhost: ss.Config.PostgresDSN == "postgres://postgres:postgres@db:5432/audius_creator_node" || ss.Config.PostgresDSN == "postgresql://postgres:postgres@db:5432/audius_creator_node" || ss.Config.PostgresDSN == "localhost",
DiskHasSpace: ss.diskHasSpace(),
Healthy: healthy,
Version: ss.Config.VersionJson.Version,
Service: ss.Config.VersionJson.Service,
IsSeeding: ss.isSeeding,
IsAudiusdManaged: ss.isAudiusdManaged,
BuiltAt: vcsBuildTime,
StartedAt: ss.StartedAt,
SPID: ss.Config.SPID,
SPOwnerWallet: ss.Config.SPOwnerWallet,
Git: ss.Config.GitSHA,
AudiusDockerCompose: ss.Config.AudiusDockerCompose,
MediorumPathUsed: ss.mediorumPathUsed,
MediorumPathSize: ss.mediorumPathSize,
DatabaseSize: ss.databaseSize,
DbSizeErr: ss.dbSizeErr,
LastSuccessfulRepair: ss.lastSuccessfulRepair,
LastSuccessfulCleanup: ss.lastSuccessfulCleanup,
UploadsCount: ss.uploadsCount,
UploadsCountErr: ss.uploadsCountErr,
AutoUpgradeEnabled: ss.Config.AutoUpgradeEnabled,
TrustedNotifier: ss.trustedNotifier,
Dir: ss.Config.Dir,
BlobStorePrefix: blobStorePrefix,
MoveFromBlobStorePrefix: blobStoreMoveFromPrefix,
ListenPort: ss.Config.ListenPort,
ReplicationFactor: ss.Config.ReplicationFactor,
Env: ss.Config.Env,
Self: ss.Config.Self,
WalletIsRegistered: ss.Config.WalletIsRegistered,
TrustedNotifierID: ss.Config.TrustedNotifierID,
PeerHealths: ss.peerHealths,
UnreachablePeers: ss.unreachablePeers,
FailsPeerReachability: ss.failsPeerReachability,
Signers: ss.Config.Signers,
StoreAll: ss.Config.StoreAll,
IsDbLocalhost: ss.Config.PostgresDSN == "postgres://postgres:postgres@db:5432/audius_creator_node" || ss.Config.PostgresDSN == "postgresql://postgres:postgres@db:5432/audius_creator_node" || ss.Config.PostgresDSN == "localhost",
IsDiscoveryListensEnabled: ss.Config.discoveryListensEnabled(),
DiskHasSpace: ss.diskHasSpace(),
}

dataBytes, err := json.Marshal(data)
Expand Down
6 changes: 6 additions & 0 deletions monitoring/healthz/src/pages/Nodes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export default function Nodes() {
{isContent && <th scope="col" className="px-4 py-2 text-left text-sm font-medium text-gray-700 dark:text-gray-200">Started</th>}
{isContent && <th scope="col" className="px-4 py-2 text-left text-sm font-medium text-gray-700 dark:text-gray-200">Uploads</th>}
{isContent && <th scope="col" className="px-4 py-2 text-left text-sm font-medium text-gray-700 dark:text-gray-200">Healthy Peers {'<'}2m</th>}
{isContent && <th scope="col" className="px-4 py-2 text-left text-sm font-medium text-gray-700 dark:text-gray-200">Discovery Listens Enabled</th>}
</tr >
</thead >
<tbody className="bg-white dark:bg-gray-900 divide-y divide-gray-200 dark:divide-gray-700">
Expand Down Expand Up @@ -341,6 +342,11 @@ function HealthRow({ isContent, sp, isStaging }: { isContent: boolean; sp: SP, i
{unreachablePeers && <div>{`Can't reach: ${unreachablePeers}`}</div>}
</td>
)}
{isContent && (
<td className={"whitespace-nowrap px-3 py-5 text-sm"}>
{JSON.stringify(health?.isDiscoveryListensEnabled === undefined ? false : health?.isDiscoveryListensEnabled)}
</td>
)}
</tr>
)
}
Expand Down
1 change: 1 addition & 0 deletions packages/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"homepage": "https://github.com/AudiusProject/audius-protocol/packages/common#readme",
"license": "",
"exports": {
"./adapters": "./src/adapters/index.ts",
"./api": "./src/api/index.ts",
"./assets": "./src/assets/index.ts",
"./audius-query": "./src/audius-query/index.ts",
Expand Down
15 changes: 15 additions & 0 deletions packages/common/src/adapters/grant.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import { full } from '@audius/sdk'

import { Grant } from '~/models/Grant'
import { decodeHashId } from '~/utils/hashIds'

export const grantFromSDK = (input: full.Grant): Grant => {
return {
grantee_address: input.granteeAddress,
user_id: decodeHashId(input.userId) ?? null,
is_revoked: input.isRevoked,
is_approved: input.isApproved,
created_at: input.createdAt,
updated_at: input.updatedAt
}
}
Loading

0 comments on commit 4d204fb

Please sign in to comment.