[ https://jira.fiware.org/browse/HELP-19782?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fernando Lopez reassigned HELP-19782:
-------------------------------------
Assignee: Fermín Galán
> [fiware-stackoverflow] Send NGSIv2 data to Orion Context Broker
> ---------------------------------------------------------------
>
> Key: HELP-19782
> URL: https://jira.fiware.org/browse/HELP-19782
> Project: Help-Desk
> Issue Type: Monitor
> Components: FIWARE-TECH-HELP
> Reporter: Backlog Manager
> Assignee: Fermín Galán
> Labels: coap, fiware, fiware-orion, iot, lwm2m
>
> Created question in FIWARE Q/A platform on 02-07-2022 at 11:07
> {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/72838531/send-ngsiv2-data-to-orion-context-broker
> +Question:+
> Send NGSIv2 data to Orion Context Broker
> +Description:+
> I explain the problem. I need to register a client to an Orion context broker. The client (OMALWM2M) is connected to the IoT Agent which acts as a bridge with NGSI. My problem is that when I connect to localhost: 1026 / v2 / entities there is no client that I connected. I ask you to look at my conifgurations of the IoT Agent and the Context broker to see where I am wrong. Thank you.
> Orion context Broker:
> docker-compose.yml
> version: "3"
> services:
> orion:
> image: fiware/orion
> ports:
> - "1026:1026"
> depends_on:
> - mongo
> command: -dbhost mongo
> mongo:
> image: mongo:4.4
> command: --nojournal
> Fiware IoT Agent
> config.js
> /*
> * Copyright 2014 Telefonica Investigación y Desarrollo, S.A.U
> *
> * This file is part of fiware-iotagent-lib
> *
> * fiware-iotagent-lib is free software: you can redistribute it and/or
> * modify it under the terms of the GNU Affero General Public License as
> * published by the Free Software Foundation, either version 3 of the License,
> * or (at your option) any later version.
> *
> * fiware-iotagent-lib is distributed in the hope that it will be useful,
> * but WITHOUT ANY WARRANTY; without even the implied warranty of
> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
> * See the GNU Affero General Public License for more details.
> *
> * You should have received a copy of the GNU Affero General Public
> * License along with fiware-iotagent-lib.
> * If not, seehttp://www.gnu.org/licenses/.
> *
> * For those usages not covered by the GNU Affero General Public License
> * please contact with::[contacto at tid.es]
> */
> var config = {};
> config.lwm2m = {
> logLevel: 'DEBUG',
> port: 5683,
> defaultType: 'Device',
> ipProtocol: 'udp4',
> serverProtocol: 'udp4',
> /**
> * When a LWM2M client has active attributes, the IoT Agent sends an observe instruction for each one, just after the
> * client registers. This may cause cause an error when the client takes too long to start listening, as the
> * observe requests may not reach its destiny. This timeout (ms) is used to give the client the opportunity to
> * create the listener before the server sends the requests.
> */
> delayedObservationTimeout: 50,
> formats: [
> {
> name: 'application-vnd-oma-lwm2m/text',
> value: 1541
> },
> {
> name: 'application-vnd-oma-lwm2m/tlv',
> value: 1542
> },
> {
> name: 'application-vnd-oma-lwm2m/json',
> value: 1543
> },
> {
> name: 'application-vnd-oma-lwm2m/opaque',
> value: 1544
> }
> ],
> writeFormat: 'application-vnd-oma-lwm2m/text',
> types: []
> };
> config.ngsi = {
> logLevel: 'DEBUG',
> timestamp: true,
> contextBroker:{
> host: 'localhost',
> port: '1026',
> ngsiVersion: 'v2'
> },
> server: {
> port: 59441
> },
> deviceRegistry: {
> //type: 'memory'
> type: 'mongodb'
> },
> mongodb: {
> host: 'localhost',
> port: '27017',
> db: 'iotagentlm2m'
> //replicaSet: ''
> },
> types: {},
> service: 'smartGondor',
> subservice: '/gardens',
> providerUrl: 'http://localhost:4041',
> deviceRegistrationDuration: 'P1Y',
> defaultType: 'Thing'
> };
> /**
> * Configuration for secured access to instances of the Context Broker secured with a PEP Proxy.
> * For the authentication mechanism to work, the authentication attribute in the configuration has to be fully
> * configured, and the authentication.enabled subattribute should have the value `true`.
> *
> * The Username and password should be considered as sensitive data and should not be stored in plaintext.
> * Either encrypt the config and decrypt when initializing the instance or use environment variables secured by
> * docker secrets.
> */
> // config.authentication: {
> //enabled: false,
> /**
> * Type of the Identity Manager which is used when authenticating the IoT Agent.
> * Either 'oauth2' or 'keystone'
> */
> //type: 'keystone',
> /**
> * Name of the additional header passed to retrieve the identity of the IoT Agent
> */
> //header: 'Authorization',
> /**
> * Hostname of the Identity Manager.
> */
> //host: 'localhost',
> /**
> * Port of the Identity Manager.
> */
> //port: '5000',
> /**
> * URL of the Identity Manager - a combination of the above
> */
> //url: 'localhost:5000',
> /**
> * KEYSTONE ONLY: Username for the IoT Agent
> * - Note this should not be stored in plaintext.
> */
> //user: 'IOTA_AUTH_USER',
> /**
> * KEYSTONE ONLY: Password for the IoT Agent
> * - Note this should not be stored in plaintext.
> */
> //password: 'IOTA_AUTH_PASSWORD',
> /**
> * OAUTH2 ONLY: URL path for retrieving the token
> */
> //tokenPath: '/oauth2/token',
> /**
> * OAUTH2 ONLY: Flag to indicate whether or not the token needs to be periodically refreshed.
> */
> //permanentToken: true,
> /**
> * OAUTH2 ONLY: ClientId for the IoT Agent
> * - Note this should not be stored in plaintext.
> */
> //clientId: 'IOTA_AUTH_CLIENT_ID',
> /**
> * OAUTH2 ONLY: ClientSecret for the IoT Agent
> * - Note this should not be stored in plaintext.
> */
> //clientSecret: 'IOTA_AUTH_CLIENT_SECRET'
> //};
> /**
> * flag indicating whether the node server will be executed in multi-core option (true) or it will be a
> * single-thread one (false).
> */
> // config.multiCore= true;
> module.exports = config;
--
This message was sent by Atlassian JIRA
(v6.4.1#64016)
You can get more information about our cookies and privacy policies clicking on the following links: Privacy policy Cookies policy