Git Product home page Git Product logo

flexom-lib's Introduction

Flexom lib

This library allows developers to interfact with Flexom smart home APIs.

Status

Flexom (actually Ubiant and Hemis) APIs are documented here: https://developers.ubiant.com/ You can login using the same account you use to control your Flexom smart home.

Currently, the following features are implemented :

  • login
  • list zones
  • get zone settings
  • set zone setting
  • list things

flexom-lib's People

Contributors

renovate[bot] avatar renovate-bot avatar rsauget avatar lgtm-migrator avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar  avatar

Forkers

lgtm-migrator

flexom-lib's Issues

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • Update dependency @types/chai to v4.3.19
  • Update dependency @types/lodash to v4.17.7
  • Update dependency axios to v1.7.7
  • Update dependency @types/node to v20.16.5
  • Update dependency eslint-plugin-import to v2.30.0
  • Update dependency eslint-plugin-prettier to v5.2.1
  • Update dependency mocha to v10.7.3 (mocha, @types/mocha)
  • Update dependency pino to v9.4.0
  • Update dependency typescript to v5.6.2
  • ๐Ÿ” Create all rate-limited PRs at once ๐Ÿ”

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

github-actions
.github/workflows/codeql.yml
  • actions/checkout v4
  • github/codeql-action v3
  • github/codeql-action v3
  • github/codeql-action v3
npm
package.json
  • @stomp/stompjs ^7.0.0
  • async-retry ^1.3.3
  • axios ^1.0.0
  • form-urlencoded ^6.0.5
  • inquirer ^9.0.0
  • jsonwebtoken ^9.0.0
  • lodash ^4.17.21
  • moment ^2.29.1
  • pino ^9.0.0
  • ws ^8.3.0
  • @types/async-retry 1.4.8
  • @types/chai 4.3.16
  • @types/jsonwebtoken 9.0.6
  • @types/lodash 4.17.6
  • @types/mocha 10.0.7
  • @types/node 20.14.10
  • @types/ws 8.5.10
  • @typescript-eslint/eslint-plugin 6.21.0
  • @typescript-eslint/parser 6.21.0
  • chai 5.1.1
  • dotenv 16.4.5
  • eslint 8.57.0
  • eslint-config-airbnb-base 15.0.0
  • eslint-config-airbnb-typescript 17.1.0
  • eslint-config-prettier 9.1.0
  • eslint-plugin-import 2.29.1
  • eslint-plugin-prettier 5.1.3
  • mocha 10.6.0
  • nodemon 3.1.4
  • prettier 3.3.2
  • release-it 17.4.1
  • rimraf 5.0.8
  • ts-node 10.9.2
  • typescript 5.5.3

  • Check this box to trigger a request for Renovate to run again on this repository

Tune STOMP.js WebSocket heartbeat intervals?

Hello there,

Just figured out that homebridge-flexom, which relies on flexom-lib, sends/receives frequent pings/pongs from the Hemis WS endpoint. Currently the interval for both c2s and s2s are set to 5s.

Also, the reconnect delay is set to 100ms, which I'm afraid could trigger a flood of connection attempts if the WS server goes down for a few seconds. Which could lead to the target WS server implementing restrictive rate-limits if there are too many homebridge-flexom clients flooding when it goes back online.

Ref: https://github.com/rsauget/flexom-lib/blob/master/src/hemis/ws.ts#L36

Is that necessary? Could all intervals be made larger?

Here's what I'd suggest, based on working w/ WS servers in different networking environments (eg. w/ restrictive NATs killing long-running TCP connections that do not heartbeat frequently-enough):

    reconnectDelay: 1000,
    heartbeatIncoming: 20000,
    heartbeatOutgoing: 20000,

This changes reconnectDelay from 100ms to 1s, heartbeatOutgoing + heartbeatIncoming from 5s to 20s.

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.