Comments (17)
@hashin commit https://github.com/mainflux/mainflux-mqtt/commit/070043878ec905095b34701ea1677c087711e45a should fix the issue. Problem was in the message encoding format in the payload byte array - Go JSON decoder encodes/decodes byte arrays in Base64 format (as you can see here: https://golang.org/src/encoding/json/encode.go), while Aedes uses UTF-8 buffers by default.
from magistrala.
@hashin Thank you for reporting this one, we will check it ASAP. @darkodraskovic maybe related with nodejs version https://github.com/mainflux/mainflux-mqtt/blob/5a1818ad938c516d293f18255e74382662c46ca0/mainflux-mqtt.js#L60 http://stackoverflow.com/questions/36899888/getting-typeerror-this-is-not-a-typed-array-using-buffer-from-in-mocha
In docker-compose version 4.x is defined , 6.9.4 is now LTS
from magistrala.
@hashin can you please confirm you have adequate NodeJS version before we continue investigation.
from magistrala.
@hashin can we close this one?
from magistrala.
@drasko I am sorry I couldn't reply on time. I will test this out again and will comeback soon. Please bear with me. And thanks!
from magistrala.
@hashin np. @nmarcetic can you please just spin a test on a fresh clone, tell us if everything is OK at your side?
from magistrala.
@drasko @nmarcetic My nodejs version is 6.9.4. I just tested this out and the error haven't gone away. The error is exactly the same. Will it be the case that the docker setup is using another version instead of my system nodejs installation?
from magistrala.
Yep, might be that MQTT Docker needs some love...
from magistrala.
Argh: https://github.com/mainflux/mainflux-mqtt/blob/master/Dockerfile#L6
This must be bumped up!
from magistrala.
@hashin we'll push the changes in a couple of hours and new MQTT server docker image will be ready on DockerHub with correct Node version. I'll give you a sign once it is there.
from magistrala.
@hashin new version of NodeJS is used now: https://github.com/mainflux/mainflux-mqtt/blob/master/Dockerfile#L6
Can you please replace the docker image (I am not sure if pull will work, maybe docker rmi
is needed) and tell us if it works now.
from magistrala.
@drasko @nmarcetic I was a bit confused with docker, so I ended up removing all the images (with docker rmi mainflux/mqtt
etc) and containers and then did docker-compose rm
followed by a docker-compose up
. But still the problem persists.
Is it that I am doing it wrong? Or is it something to do with docker?
from magistrala.
To be sure, I did a docker rmi mainflux/mainflux-mqtt
and then removed the container with docker rm container-id
. Then I did a docker pull mainflux/mainflux-mqtt
in which I got an output of Status: Downloaded newer image for mainflux/mainflux-mqtt:latest
.
Then I did a docker-compose rm
followed by a docker-compose up
. And the error persists. Is there any other way of going about the issue?
Thanks for your help. :)
from magistrala.
@hashin I confirm the bug - you are sending the correct command, but something is wrong with the buffer. I am investigating it right now.
from magistrala.
Hello @hashin - is this working for you now? Can it be closed?
from magistrala.
@drasco Sorry for my late reply. I tested it today and it is working fine. Thanks for the bug fix! I will close the issue.
Also, I have seen some small errors in the documentation and website. (Grammatical, link fixes etc) Can I send a pull request correcting them? :-)
from magistrala.
@hashin thanks lot for the bug report and the test!
All the PRs are more than welcome!
from magistrala.
Related Issues (20)
- Feature: Relationship might not be required for unassigning User for Entity
- Feature: Rename Viewer relation to better word and having relation which can do only view not creation of entitles
- Feature: Add support for a custom handler on slog/ logger HOT 1
- Bug: Unable to retrieve secure bootstrap configuration HOT 2
- Feature: Policy for Domain member to restrict on creation new entities such as things, channels and groups in domain
- Feature: Generic field in the token
- Check if NginX Lua script is still necessary for mTLS HOT 1
- Feature: Make JWT tokens stateful even for Users / Apps - add this as a selectable option HOT 1
- Feature: Remove unused Fields in the Token object
- Bug: Have a fixed unix timeformat precision in SenML
- Feature: Remove repository error in API response HOT 2
- Feature: Enhance OPC-UA adapter to be more customizable and to perform additional functions HOT 2
- Bug: Unable to enable thing using bootstrap HOT 2
- Feature: Update Magistrala messaging with mProxy with TLS
- Generate mocks with mockery for Bootstrap service HOT 2
- Feature: Generate mocks with mockery for Certs service
- NOISSUE - Rename Mainflux to Magistrala in HELM charts
- Feature: Consume Things connect event in bootstrap HOT 1
- Feature: Generate mocks with mockery for Invitations service
- Feature: Generate mocks with mockery for Lora service
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from magistrala.