Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
We Distribute
  1. Home
  2. Technical Discussion
  3. I have deeply mixed feelings about #ActivityPub's adoption of JSON-LD, as someone who's spent way too long dealing with it while building #Fedify.

I have deeply mixed feelings about #ActivityPub's adoption of JSON-LD, as someone who's spent way too long dealing with it while building #Fedify.

Scheduled Pinned Locked Moved Technical Discussion
fedifyjsonldfedidevactivitypub
168 Posts 35 Posters 266 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • kopper@not-brain.d.on-t.workK kopper@not-brain.d.on-t.work
    @evan @gugurumbe it's infeasible to preload all contexts, pretty much every pleroma instance hosts their own context on their own instance for example. then there is the obvious interop problems of how to handle contexts for new extensions your software is not aware of (though pretending like they're empty might work i guess?)
    gugurumbe@mastouille.frG This user is from outside of this forum
    gugurumbe@mastouille.frG This user is from outside of this forum
    gugurumbe@mastouille.fr
    wrote last edited by
    #112

    @kopper It does not; if a malicious context redefines the security properties then the JSON-LD processor will understand the data differently than the unaware processor.

    1 Reply Last reply
    0
    • patmikemid@sfba.socialP patmikemid@sfba.social

      @evan @cwebber @kopper @hongminhee I think that is a better algorithm than a brain dead exponential back off. Perhaps put the two together.

      evan@cosocial.caE This user is from outside of this forum
      evan@cosocial.caE This user is from outside of this forum
      evan@cosocial.ca
      wrote last edited by
      #113

      @patmikemid I call it trust, then verify. Usually caching the data with a ttl of a short number of minutes is enough.

      @cwebber @kopper @hongminhee

      cwebber@social.coopC 1 Reply Last reply
      0
      • kopper@not-brain.d.on-t.workK kopper@not-brain.d.on-t.work
        @evan @gugurumbe it's infeasible to preload all contexts, pretty much every pleroma instance hosts their own context on their own instance for example. then there is the obvious interop problems of how to handle contexts for new extensions your software is not aware of (though pretending like they're empty might work i guess?)
        evan@cosocial.caE This user is from outside of this forum
        evan@cosocial.caE This user is from outside of this forum
        evan@cosocial.ca
        wrote last edited by
        #114

        @kopper @gugurumbe

        https://en.wikipedia.org/wiki/Cache_%28computing%29

        kopper@not-brain.d.on-t.workK natty@astolfo.socialN mia@void.rehabM 3 Replies Last reply
        0
        • evan@cosocial.caE evan@cosocial.ca

          @kopper @gugurumbe

          https://en.wikipedia.org/wiki/Cache_%28computing%29

          kopper@not-brain.d.on-t.workK This user is from outside of this forum
          kopper@not-brain.d.on-t.workK This user is from outside of this forum
          kopper@not-brain.d.on-t.work
          wrote last edited by
          #115
          @evan @gugurumbe i know what caching is, thanks. in fact, my current project is building one that's tailor made for solving the activitypub thundering herd problem (codeberg.org/KittyShopper/middleap)

          i've been trying to keep civil through this thread largely because i started the conversation mentioning software i (temporarily) help maintain and therefore represent it even implicitly, but leaving that aside and letting my own personal thoughts enter the picture:

          i think this passive aggressive reply is the last straw. thinking that i somehow know enough to write code for this protocol without knowing what a cache is? plugging your book in a network largely developed by poor minorities (i myself have the rough equivalent of less than 40 USD in my bank account total)? this inability to consider change? ("as2 requires compaction",
          because you're the one defining the spec saying it does), the inability to consider the people and software producing and building upon the data, as opposed to the data itself? the inability to consider the consequences of your specifications and how they're being used in the real world?

          i honestly do not know if this line of thought is truly capable of leading this protocol out the slump it's currently in. if you're insistent on shooting yourself in the foot, so be it, but please take the time to consider how this behavior affects other people.

          i've largely been burnt out of interacting in socialhub and other official protocol communities due to exactly this behavior, whether from you or others with influence on the final specs, and the only reason i keep trying is because of what's probably a self-destructive autistic hyperfixation on this niche network and trying to make it actually work for me and my friends, as opposed to
          receiving funding from the well-known genocide enablers at meta and trying to shove failing standards where they don't belong.

          please be a better example. if the protocol was actually desirable then sure, you may have earnt it, after all, atproto is teeming with silicon valley e/acc death cult weirdos and yet people seem to prefer it. have you wondered why?
          or do you prefer to dismiss anything not coming from you without thinking about it
          esm@wetdry.worldE evan@cosocial.caE 2 Replies Last reply
          0
          • evan@cosocial.caE evan@cosocial.ca

            @cwebber @kopper @hongminhee I talk about this in my book. Unless the receiving user is online at the time the server receives the Announce, it's ridiculous to fetch the content immediately. Receiving servers should pause a random number of minutes and then fetch the content. It avoids the thundering herd problem.

            julia@eepy.moeJ This user is from outside of this forum
            julia@eepy.moeJ This user is from outside of this forum
            julia@eepy.moe
            wrote last edited by
            #116

            @evan@cosocial.ca @cwebber@social.coop @kopper@not-brain.d.on-t.work @hongminhee@hollo.social shared inboxes are a thing, Evan

            The protocol isn't
            just how it was initially defined. Protocols evolve and change from their ideals to fit the needs of their operation, and getting rid of individual inboxes is one of those changes.

            Social media platforms are real-time- you can't just defer stuff like that.

            evan@cosocial.caE 1 Reply Last reply
            0
            • julia@eepy.moeJ julia@eepy.moe

              @evan@cosocial.ca @cwebber@social.coop @kopper@not-brain.d.on-t.work @hongminhee@hollo.social shared inboxes are a thing, Evan

              The protocol isn't
              just how it was initially defined. Protocols evolve and change from their ideals to fit the needs of their operation, and getting rid of individual inboxes is one of those changes.

              Social media platforms are real-time- you can't just defer stuff like that.

              evan@cosocial.caE This user is from outside of this forum
              evan@cosocial.caE This user is from outside of this forum
              evan@cosocial.ca
              wrote last edited by
              #117

              @julia @cwebber @hongminhee @kopper

              Hi! 👋🏼 Nice to meet you. I'm well aware of `sharedInbox` and helped design it.

              Realtime is an illusion. You can make it pretty convincing.

              Your users are mostly not online. Remote users are mostly not online. Tracking the last time remote and local users were seen can help you prioritize local and remote delivery.

              It's a lot better to deliver to the tiny percent of users currently online first rather than delivering to the user named `aaaaaaaaamng` first.

              julia@eepy.moeJ panos@ibe.socialP 2 Replies Last reply
              0
              • evan@cosocial.caE evan@cosocial.ca

                @julia @cwebber @hongminhee @kopper

                Hi! 👋🏼 Nice to meet you. I'm well aware of `sharedInbox` and helped design it.

                Realtime is an illusion. You can make it pretty convincing.

                Your users are mostly not online. Remote users are mostly not online. Tracking the last time remote and local users were seen can help you prioritize local and remote delivery.

                It's a lot better to deliver to the tiny percent of users currently online first rather than delivering to the user named `aaaaaaaaamng` first.

                julia@eepy.moeJ This user is from outside of this forum
                julia@eepy.moeJ This user is from outside of this forum
                julia@eepy.moe
                wrote last edited by
                #118

                @evan@cosocial.ca @cwebber@social.coop @hongminhee@hollo.social @kopper@not-brain.d.on-t.work I feel like deferring activity resolution and publishing based on online status would only serve to create more reasons for your average person to feel that the fediverse is unstable- explaining the logistics of the herd problem to someone who doesn't know what a distributed system is is kinda difficult.

                evan@cosocial.caE 1 Reply Last reply
                0
                • evan@cosocial.caE evan@cosocial.ca

                  @kopper @gugurumbe

                  https://en.wikipedia.org/wiki/Cache_%28computing%29

                  natty@astolfo.socialN This user is from outside of this forum
                  natty@astolfo.socialN This user is from outside of this forum
                  natty@astolfo.social
                  wrote last edited by
                  #119

                  @evan@cosocial.ca @kopper@not-brain.d.on-t.work @gugurumbe@mastouille.fr Evan, to put it bluntly, the status quo only creates a further divide between the "big certified implementations" and the small implementation independent developers can make without worrying about making the implementation vulnerable-by-default

                  There could totally be a body that at least
                  attempts to standardize well-known LD prefixes while retaining compatibility with JSON-LD (like IANA and protocol schemes), but there isn't

                  There could be a
                  subset of JSON-LD that prohibits common pitfalls, but there is not one. In fact, there are very few high-quality openly available libraries that can process ActivityPub objects. There is no way to declare the actual shapes of objects without heavy fuzzing.

                  There is no safe amount of JSON-LD in a distributed network where context URIs may fade in and out of existence. I'm saying distributed because that's essentially what happens in practice over sufficient time.

                  Can we for the love of all that's serializable shrink the state space of this mess? It's possible and it's actionable, without anyone left out. We don't need a Rube-Goldberg machine to share a JPEG online

                  1 Reply Last reply
                  0
                  • kopper@not-brain.d.on-t.workK kopper@not-brain.d.on-t.work
                    @evan @gugurumbe i know what caching is, thanks. in fact, my current project is building one that's tailor made for solving the activitypub thundering herd problem (codeberg.org/KittyShopper/middleap)

                    i've been trying to keep civil through this thread largely because i started the conversation mentioning software i (temporarily) help maintain and therefore represent it even implicitly, but leaving that aside and letting my own personal thoughts enter the picture:

                    i think this passive aggressive reply is the last straw. thinking that i somehow know enough to write code for this protocol without knowing what a cache is? plugging your book in a network largely developed by poor minorities (i myself have the rough equivalent of less than 40 USD in my bank account total)? this inability to consider change? ("as2 requires compaction",
                    because you're the one defining the spec saying it does), the inability to consider the people and software producing and building upon the data, as opposed to the data itself? the inability to consider the consequences of your specifications and how they're being used in the real world?

                    i honestly do not know if this line of thought is truly capable of leading this protocol out the slump it's currently in. if you're insistent on shooting yourself in the foot, so be it, but please take the time to consider how this behavior affects other people.

                    i've largely been burnt out of interacting in socialhub and other official protocol communities due to exactly this behavior, whether from you or others with influence on the final specs, and the only reason i keep trying is because of what's probably a self-destructive autistic hyperfixation on this niche network and trying to make it actually work for me and my friends, as opposed to
                    receiving funding from the well-known genocide enablers at meta and trying to shove failing standards where they don't belong.

                    please be a better example. if the protocol was actually desirable then sure, you may have earnt it, after all, atproto is teeming with silicon valley e/acc death cult weirdos and yet people seem to prefer it. have you wondered why?
                    or do you prefer to dismiss anything not coming from you without thinking about it
                    esm@wetdry.worldE This user is from outside of this forum
                    esm@wetdry.worldE This user is from outside of this forum
                    esm@wetdry.world
                    wrote last edited by
                    #120

                    @kopper @evan @gugurumbe thank you for saying this; the relatively poor DX is one thing, but i could get around that if it weren't for the insistence by the authors and major developers here on minimizing much of the very real problems of this protocol/network and then complaining about those who look elsewhere without considering why they would want to do that

                    i continue to maintain existing stuff for this network, but i'm incredibly hesitant to make anything new mostly due to the reasons stated above - especially when we have other options now

                    1 Reply Last reply
                    0
                    • evan@cosocial.caE evan@cosocial.ca

                      @kopper @gugurumbe

                      https://en.wikipedia.org/wiki/Cache_%28computing%29

                      mia@void.rehabM This user is from outside of this forum
                      mia@void.rehabM This user is from outside of this forum
                      mia@void.rehab
                      wrote last edited by
                      #121

                      @evan @kopper @gugurumbe what, you got a book on caching you want to plug too?

                      1 Reply Last reply
                      0
                      • kopper@not-brain.d.on-t.workK kopper@not-brain.d.on-t.work
                        @evan @gugurumbe i know what caching is, thanks. in fact, my current project is building one that's tailor made for solving the activitypub thundering herd problem (codeberg.org/KittyShopper/middleap)

                        i've been trying to keep civil through this thread largely because i started the conversation mentioning software i (temporarily) help maintain and therefore represent it even implicitly, but leaving that aside and letting my own personal thoughts enter the picture:

                        i think this passive aggressive reply is the last straw. thinking that i somehow know enough to write code for this protocol without knowing what a cache is? plugging your book in a network largely developed by poor minorities (i myself have the rough equivalent of less than 40 USD in my bank account total)? this inability to consider change? ("as2 requires compaction",
                        because you're the one defining the spec saying it does), the inability to consider the people and software producing and building upon the data, as opposed to the data itself? the inability to consider the consequences of your specifications and how they're being used in the real world?

                        i honestly do not know if this line of thought is truly capable of leading this protocol out the slump it's currently in. if you're insistent on shooting yourself in the foot, so be it, but please take the time to consider how this behavior affects other people.

                        i've largely been burnt out of interacting in socialhub and other official protocol communities due to exactly this behavior, whether from you or others with influence on the final specs, and the only reason i keep trying is because of what's probably a self-destructive autistic hyperfixation on this niche network and trying to make it actually work for me and my friends, as opposed to
                        receiving funding from the well-known genocide enablers at meta and trying to shove failing standards where they don't belong.

                        please be a better example. if the protocol was actually desirable then sure, you may have earnt it, after all, atproto is teeming with silicon valley e/acc death cult weirdos and yet people seem to prefer it. have you wondered why?
                        or do you prefer to dismiss anything not coming from you without thinking about it
                        evan@cosocial.caE This user is from outside of this forum
                        evan@cosocial.caE This user is from outside of this forum
                        evan@cosocial.ca
                        wrote last edited by
                        #122

                        @kopper @gugurumbe sorry, friend, for the curt response. I'm flying today for a death in the family, and I'm having a hard time keeping a lot of conversations going. You should have heard me trying to chair a meeting as I went through airport security!

                        evan@cosocial.caE 1 Reply Last reply
                        0
                        • evan@cosocial.caE evan@cosocial.ca

                          @kopper @gugurumbe sorry, friend, for the curt response. I'm flying today for a death in the family, and I'm having a hard time keeping a lot of conversations going. You should have heard me trying to chair a meeting as I went through airport security!

                          evan@cosocial.caE This user is from outside of this forum
                          evan@cosocial.caE This user is from outside of this forum
                          evan@cosocial.ca
                          wrote last edited by
                          #123

                          @kopper @gugurumbe

                          Anyway, to me, a backwards-incompatible change is absolutely the worst possible choice we could make for the Fediverse. It splits the network, possibly permanently. We have about 100 implementations of ActivityPub, and they can't all upgrade at the same time.

                          evan@cosocial.caE kopper@not-brain.d.on-t.workK smallcircles@social.coopS 3 Replies Last reply
                          0
                          • evan@cosocial.caE evan@cosocial.ca

                            @kopper @gugurumbe

                            Anyway, to me, a backwards-incompatible change is absolutely the worst possible choice we could make for the Fediverse. It splits the network, possibly permanently. We have about 100 implementations of ActivityPub, and they can't all upgrade at the same time.

                            evan@cosocial.caE This user is from outside of this forum
                            evan@cosocial.caE This user is from outside of this forum
                            evan@cosocial.ca
                            wrote last edited by
                            #124

                            @kopper @gugurumbe I just don't think the downside of having to cache the results of context URL fetches outweighs that.

                            1 Reply Last reply
                            0
                            • evan@cosocial.caE evan@cosocial.ca

                              @kopper @gugurumbe

                              Anyway, to me, a backwards-incompatible change is absolutely the worst possible choice we could make for the Fediverse. It splits the network, possibly permanently. We have about 100 implementations of ActivityPub, and they can't all upgrade at the same time.

                              kopper@not-brain.d.on-t.workK This user is from outside of this forum
                              kopper@not-brain.d.on-t.workK This user is from outside of this forum
                              kopper@not-brain.d.on-t.work
                              wrote last edited by
                              #125
                              @evan @gugurumbe

                              here is a backwards incompatible change in a fep you authored:
                              codeberg.org/fediverse/fep/src/branch/main/fep/b2b8/fep-b2b8.md#attributedto (specifically, the Link-and-name bit. mobile Firefox does not let me send highlights apparently)

                              the http signature draft->rfc change is backwards incompatible.

                              mastodon api to c2s is backwards incompatible for client developers (and,
                              if done correctly, would require long and unwieldy migrations on servers. ask firefish.social users how those kinds of migrations end up)

                              whatever the replacement for as:summary as content warnings would be backwards incompatible. replacing as:name with as:description for media alt text is backwards incompatible (gotosocial did it, and we adapted)

                              making webfinger optional is backwards incompatible

                              backwards compatibility is not here yet. now is the second best time to get rid of legacy cruft
                              esm@wetdry.worldE evan@cosocial.caE 2 Replies Last reply
                              0
                              • evan@cosocial.caE evan@cosocial.ca

                                @cwebber @kopper @hongminhee I talk about this in my book. Unless the receiving user is online at the time the server receives the Announce, it's ridiculous to fetch the content immediately. Receiving servers should pause a random number of minutes and then fetch the content. It avoids the thundering herd problem.

                                cwebber@social.coopC This user is from outside of this forum
                                cwebber@social.coopC This user is from outside of this forum
                                cwebber@social.coop
                                wrote last edited by
                                #126

                                @evan @kopper @hongminhee But that means either:

                                - Users don't get to see content that has been federated to them for *minutes*
                                - Unless we show unverified messages, allowing for windows of impersonation attacks, in which substantial reputational damage can be done!

                                And also:

                                - Whenever I boost several of @vv's posts, her server can be down *for a while*. Random delays can help reduce load but not as substantially as signature verification
                                - This has to be done for both the activity *and* the object
                                - And there's no reason to include either the activity or the object if you care about not risking impersonation attacks, because you might as well just send {"@id": "https://example.org/post/12345/"}

                                1 Reply Last reply
                                0
                                • evan@cosocial.caE evan@cosocial.ca

                                  @patmikemid I call it trust, then verify. Usually caching the data with a ttl of a short number of minutes is enough.

                                  @cwebber @kopper @hongminhee

                                  cwebber@social.coopC This user is from outside of this forum
                                  cwebber@social.coopC This user is from outside of this forum
                                  cwebber@social.coop
                                  wrote last edited by
                                  #127

                                  @evan @patmikemid @kopper @hongminhee Trust *then* verify?! That means accepting windows of impersonation attacks necessarily then, right...?!

                                  evan@cosocial.caE 1 Reply Last reply
                                  0
                                  • evan@cosocial.caE evan@cosocial.ca

                                    @gugurumbe @cwebber @kopper @hongminhee AS2 requires compacted JSON-LD.

                                    trwnh@mastodon.socialT This user is from outside of this forum
                                    trwnh@mastodon.socialT This user is from outside of this forum
                                    trwnh@mastodon.social
                                    wrote last edited by
                                    #128

                                    @evan @gugurumbe @cwebber @kopper @hongminhee only for terms defined in AS2, though?

                                    if the activitystreams context is missing in an application/activity+json document, then you MUST assume/inject it. this means you can't redefine "actor" to mean "actor in a movie".

                                    otherwise, you don't have to augment the context with anything else. "https://w3id.org/security#publicKey" is a valid property name. the proposal is to not augment the normative context where possible. no parsing context if there is no context

                                    evan@cosocial.caE 1 Reply Last reply
                                    0
                                    • julia@eepy.moeJ julia@eepy.moe

                                      @evan@cosocial.ca @cwebber@social.coop @hongminhee@hollo.social @kopper@not-brain.d.on-t.work I feel like deferring activity resolution and publishing based on online status would only serve to create more reasons for your average person to feel that the fediverse is unstable- explaining the logistics of the herd problem to someone who doesn't know what a distributed system is is kinda difficult.

                                      evan@cosocial.caE This user is from outside of this forum
                                      evan@cosocial.caE This user is from outside of this forum
                                      evan@cosocial.ca
                                      wrote last edited by
                                      #129

                                      @julia you don't have to publish as soon as you receive it; you just have to publish before the user loads it.

                                      If the pattern doesn't work for you right now, no problem. As Sharkey scales, I hope you remember it!

                                      1 Reply Last reply
                                      0
                                      • trwnh@mastodon.socialT trwnh@mastodon.social

                                        @evan @gugurumbe @cwebber @kopper @hongminhee only for terms defined in AS2, though?

                                        if the activitystreams context is missing in an application/activity+json document, then you MUST assume/inject it. this means you can't redefine "actor" to mean "actor in a movie".

                                        otherwise, you don't have to augment the context with anything else. "https://w3id.org/security#publicKey" is a valid property name. the proposal is to not augment the normative context where possible. no parsing context if there is no context

                                        evan@cosocial.caE This user is from outside of this forum
                                        evan@cosocial.caE This user is from outside of this forum
                                        evan@cosocial.ca
                                        wrote last edited by
                                        #130

                                        @trwnh i was replying to a post that wanted all expanded terms.

                                        @gugurumbe @cwebber @kopper @hongminhee

                                        gugurumbe@mastouille.frG 1 Reply Last reply
                                        0
                                        • kopper@not-brain.d.on-t.workK kopper@not-brain.d.on-t.work
                                          @evan @gugurumbe it's infeasible to preload all contexts, pretty much every pleroma instance hosts their own context on their own instance for example. then there is the obvious interop problems of how to handle contexts for new extensions your software is not aware of (though pretending like they're empty might work i guess?)
                                          trwnh@mastodon.socialT This user is from outside of this forum
                                          trwnh@mastodon.socialT This user is from outside of this forum
                                          trwnh@mastodon.social
                                          wrote last edited by
                                          #131

                                          @kopper @evan @gugurumbe i think you can treat context identifiers as aliases. if you are already in a situation where you generally have to inject corrected contexts, then this should be doable.

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          Powered by NodeBB Contributors
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups