Code Monkey home page Code Monkey logo

Comments (3)

tystuyfzand avatar tystuyfzand commented on September 26, 2024
  1. See AddHandler and events.go - you can add funcs which take these as the only argument and they'll be passed when something happens, meaning you can log anything you'd like. There's also the Validator which can verify it's a topic you handle.
  2. Yes, see the store package. This is made specifically to allow something like MySQL, SQLite, etc to store records. Note that these aren't implemented by default as sqlite, at least, would require cgo to build and complicating the package more. Third party packages would be greatly appreciated for implementations of these.
  3. Yep! They must validate with the hub.challenge, See this code which handles verification of challenges against the endpoint. The subscriptions are not stored until verified.
  4. The publishing spec is weird in general, but requires hub.topic to specify which topic it's updating. The ContentProvider type provides a way for the hub to retrieve content if you had something custom, or simply pass through data if you'd like it to. The default is to send an HTTP GET request to the topic url.
  5. I'll look into this, seems to be a bug with the lease time. I added an override to the DecodeHook for strings, seems like I didn't add one for integers.

from websub-server.

tystuyfzand avatar tystuyfzand commented on September 26, 2024

@pierrocknroll

I've created a basic, albeit untested sql store. I'll likely test it this weekend, but figured I'd push it up into the feature/mysql branch for now!

Edit: Tested (basic) sql store added to the main branch under store/database!

from websub-server.

pierrocknroll avatar pierrocknroll commented on September 26, 2024

Thanks a lot, it's clear for me now :) 👍

from websub-server.

Related Issues (2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.