Giter VIP home page Giter VIP logo

Comments (5)

cjus avatar cjus commented on May 19, 2024 1

@tylerhutcherson is there any chance that your exception is occurring before the logging plugin is bound?
Happy to help debug this via zoom. You have my contact info.

from hydra-express.

tylerhutcherson avatar tylerhutcherson commented on May 19, 2024

@cjus Our app in question is already using the following package.json:

{
  "name": "shopify-webhooks-v1-svcs",
  "version": "0.1.3",
  "description": "Shopify Webhooks",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "dependencies": {
    "redis": "2.8.0",
    "hydra-express": "1.8.3",
    "hydra-express-plugin-jwt-simple-auth": "0.1.0",
    "hydra-plugin-hls": "0.2.6",
    "node-fetch": "2.6.1"
  },
  "devDependencies": {
    "eslint": "7.15.0",
    "eslint-config-google": "0.14.0"
  }
}

from hydra-express.

tylerhutcherson avatar tylerhutcherson commented on May 19, 2024

Looks like our app has the dependency, but the hydra-plugin-hls is not getting loaded/configured for us with hydraExpress. Our app has the following imports:

 const hydraExpress = require('hydra-express');
 const express = hydraExpress.getExpress();
 const hydra = hydraExpress.getHydra();
 const ServerResponse = hydra.getServerResponseHelper();
 const serverResponse = new ServerResponse;

 const api = new express.Router();

Am I correct that the proper import for hls plugin would be:

 const hydraExpress = require('hydra-express');
 const HydraLogPlugin = require('hydra-plugin-hls/hydra-express');
 hydraExpress.use(new HydraLogPlugin);

 const express = hydraExpress.getExpress();
 const hydra = hydraExpress.getHydra();
 const ServerResponse = hydra.getServerResponseHelper();
 const serverResponse = new ServerResponse;

 const api = new express.Router();

from hydra-express.

tylerhutcherson avatar tylerhutcherson commented on May 19, 2024

I tested this update on our app, yet I still get the same error thrown by the hydra-express lib above.

from hydra-express.

tylerhutcherson avatar tylerhutcherson commented on May 19, 2024

@tylerhutcherson is there any chance that your exception is occurring before the logging plugin is bound? Happy to help debug this via zoom. You have my contact info.

It appears the true exception under the hood was an express PayloadTooLargeError described here. This was being covered up by the error posted above. When I removed the hydra logging plugin entirely, the exception passed through, enabling us to debug the real issue.

However - the error above seems to happen when there is a fatal log-level error inside the middleware.

This is currently non-blocking for us at the moment, however, I can leave this open if you want, or we can take the discussion offline and report back.

from hydra-express.

Related Issues (13)

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.