Code Monkey home page Code Monkey logo

ngsi-source-operator's People

Contributors

aarranz avatar cblanco avatar dependabot[bot] avatar fisuda avatar jason-fox avatar mjimenezganan avatar mognom avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

ngsi-source-operator's Issues

Add support for using the credentials of the workspace owner instead of using the credentials of the logged user

Anonymous users don't have valid credentials for accessing the context broker. Allowing widgets and operators use the credentials of the owner instead of using the credentials of the logged user will be a good starting point for improving the usefulness of shared workspaces requiring access to the context broker.

This will become a great feature once WireCloud improves the shareability options.

Use paginated queries for retrieving the initial entities

Currently, the NGSI Source operator relies on the initial notification from the context broker with the initial values for retrieving the initial entities. This is a problem as the orion context broker only sends 20 entities as much (the default page size) in the initial notification. Moreover, we have to take into account that the initial notification may be removed in a near future (see telefonicaid/fiware-orion#591 and telefonicaid/fiware-orion#920).

The NGSI Source operator should use the query API for retrieving the initial values using a bigger page size and probably making more than one request.

See Wirecloud/wirecloud#126 for more info

install problem

On a fresh Wirecloud install, i follow your tutorial but as i get errors, i run these instead:

sudo apt-get install acct
sudo apt-get install curl
sudo apt-get install nodejs=0.6.12~dfsg1-1ubuntu1
sudo apt-get install nodejs-dev 
sudo apt-get install npm
curl -sL https://deb.nodesource.com/setup | sudo bash -

I noticed that we require not tu use the lastest version of nodejs, is this correct ? (otherwise i get errors)
But at the moment, the npm command does not seem to work.

Here is the log, you can see the npm error at the bottom
http://pastebin.com/DKcswxtR

npm install is failing on npm 3.10.10

I'm getting this error back:

npm ERR! Windows_NT 10.0.14393
npm ERR! argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "install"
npm ERR! node v6.9.4
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE

npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the libxmljs package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs libxmljs
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls libxmljs
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! c:\projects\iot\health-iot\FIWARE\ngsi-source-operator\npm-debug.log

ReferenceError: moment is not defined

I encountered the following error.

ReferenceError: moment is not defined
    at NGSISource.doInitialSubscription (http://172.16.1.11/showcase/media/CoNWeT/ngsi-source/4.0.0/js/main.js:157:32)
    at NGSISource.handlerPreferences (http://172.16.1.11/showcase/media/CoNWeT/ngsi-source/4.0.0/js/main.js:262:35)
    at OperatorPreferencesWindowMenu.operatorCallback (http://172.16.1.11/static/cache/js/ed09ef02247e.js:1335:25)
    at OperatorPreferencesWindowMenu._savePrefs (http://172.16.1.11/static/cache/js/ed09ef02247e.js:1334:341)

This reason is that the moment-with-locales.min.js file isn't found.

Failed to load resource: the server responded with a status of 404 (Not Found) http://172.16.1.11/showcase/media/CoNWet/ngsi-source/4.0.0/lib/js/moment-with-locales.min.js

I checked a message when making a wgt file.

root@4ca5539184a0:/work# grunt bower:install
Running "bower:install" (bower) task
(node:45) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
>> Installed bower packages

Done.

A .js file is not copied while running bower:install.
The ">> Copied packages to /work/build/lib/lib" message is not found.

It seems that a file is copied when using grunt-bower-task:0.4.0 but not copied when using 0.5.0.

Add support for NGSI polling mode to receive updates

In some cases, for example when the WireCloud server is running on a different server/domain than the Orion CB, a callback subscription mode is not always possible. In those cases a polling mode may be applied. At the rate of a user-specified interval the ngsi-source-operator will query the OCB. Possibly with some restrictions like a single type and a minimum interval time. Polling mode (boolean) and interval may be specified via the config.xml.

In the longer term a "long polling mode" may be considered, as described here: https://www.pubnub.com/blog/2014-12-01-http-long-polling or even full COMET (https://en.wikipedia.org/wiki/Comet_(programming)).

Alternatively a new Operator like ngsi-polling-operator may be defined for this mode.

Exception if the NGSI proxy URL is empty

NGSI operator raises a TypeError: is not a valid URL. if the ngsiproxy setting is empty. This setting should be required only if the operator is configure to monitor one or more attributes (through the Monitored NGSI Attributes setting). If the operator is not configured to do so, the NGSI proxy URL setting can be empty.

As WireCloud currently does not support to conditionally require a setting. The NGSI proxy URL setting should be configure as optional, and the operator should manage such cases to provide a decent error message.

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.