app.go 718 B

12345678910111213141516171819202122232425
  1. package server
  2. import (
  3. "github.com/langgenius/dify-plugin-daemon/internal/cluster"
  4. "github.com/langgenius/dify-plugin-daemon/internal/core/persistence"
  5. "github.com/langgenius/dify-plugin-daemon/internal/core/plugin_daemon/backwards_invocation/transaction"
  6. )
  7. type App struct {
  8. // cluster instance of this node
  9. // schedule all the tasks related to the cluster, like request direct
  10. cluster *cluster.Cluster
  11. // endpoint handler
  12. // customize behavior of endpoint
  13. endpoint_handler EndpointHandler
  14. // aws transaction handler
  15. // accept aws transaction request and forward to the plugin daemon
  16. aws_transaction_handler *transaction.AWSTransactionHandler
  17. // persistence
  18. persistence *persistence.Persistence
  19. }