This gave me a solid ground of what Microservices are, heard a lot of explanations and demonstrations but never seen a simple tutorial like this. Thank you!
Excellent tutorial ! Just a minor comment - you may avoid using port numbers at the frontend, as they may be changed in different deployment scenarios. :). A tool such as nginx may be very handy.
i must be doing something wrong here but cant figure out what, when i di the initial post request i get an error back in postman "422Unprocessable Entity" like it cant access the fields....
Great tutorial by this guy. I've been following him quite a while, he is awesome. One question though When you send the order to Redis Stream, you suppose that the other microservice is up and running. In case this process is not running right now and it starts after few seconds, Redis Stream will send whatever in the Stream (the old and new) to this microservice and the microservice will go through all of them again and you will end up having duplicates in your HASH table. You should remove whatever was consumed from the Stream so in case of subscribing to it you don't get the whole stream again. on the other hand, you can have multiple instances of the "Consume" process in case you have a lot of orders, each instance takes care of one order after another.
I feel like leaving this step out kind of messes with the logic of the entire tutorial. Learned a lot nevertheless, but would have been nice to have the protect use multiple redis dbs.
Excellent tutorial guys. I was trying to keep it up on it but unfortunately I've got stock in the first consumer that comes from inventory. Whenever I sent the redis-stream it serves well the data but for some reason the Product.get() method does not work and tends to dispatch me that the product not exists while is already there. How could I solve that issue?
Just to give an update to anybody could be following this video and make their own project structure. I was practicing with the concept of having all the code inside app directory. Therefore: > inventory ------> app/ |---------> main.py |---------> consumer.py For some reason, it seems that redis_om don't handle properly this type of structure due to the Product import not returning the Product object that I already referring to. I'm not really sure why is but if anybody has already work like this and already made all this tutorial with ease, please, let me know because I would like to understand what are the boundaries to not have the microservice work like that. The workaround that I have to make this work was basically get rid of the subdirectory app and have all the main.py, consumer.py in both microservices at root directory.
@@Tigersoulification I'm facing the same problem but do not understand your solution. Could you please explain it. I have both consumer and main within my inventory sub-directory.
Hi, I want to do this project but somehow I stuck at the Front-End part because I've used only Python. Anyone have link for study specific to create the front end part? Thanks
I had the same issue. You have to install same versions of libs from 4:31. In this case error will not appear. you can run this command to do it: pip install --no-cache-dir --upgrade -r requirements.txt
Great tutorial. However when I try to replicate the tutorial on my windows machine, I got the error message "Error loading ASGI app. Could not import module "main"". Pls who can I resolve the error?
Thanks for the effort but I think this is a multiservices app rather than a microservices one. In microservices each service has its own server and its own database, and the biggest challenge in microservices architecture is how to deseign a database when it’s distributed
Good morning, I'm new - I wanted to ask you if it is appropriate to use Redis in case the relational data constantly changes due to the intervention of external users. That is, the tables are in use in real time so I don't know if it is valid to use Redis in this case and I don't know if it is possible to update a Redis register per sub key. Could you help me with a clarification? thanks
Honestly, what is the point of this video? The way you tackle microservices here is not applicable in production, not in the slightest. And during this video author introduces many antipatterns, both python in general, fastapi and architectural. I understand that this video is not designed to be a manual on how to use microservices in production, but even considering that it does more harm than good imo.
finally a relatable comment - also the teacher doesn't explain the async architecture in detail - it's more like a gulp it down rather than develop your intuition.
Hello @Team, I get this error ``` raise ConnectionError(self._error_message(e)) redis.exceptions.ConnectionError: Error 111 connecting to localhost:6379. Connection refused. ``` Caused while trying to save to redis, when you comment out the order.save(), there is no error
Unfortunately, Redis is not supported on Windows. So if you're on a Windows system, you'll need to have a WSL setup and follow setting up a Redis server through the Linux distro. redis.io/docs/getting-started/installation/install-redis-on-windows/
I have followed your procedure, but I keep getting this error requests.exceptions.SSLError: HTTPSConnectionPool(host='localhost', port=8000): Max retries exceeded with url: /products/01G9D4114WV4BSPGG5HV2MGKV0 (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1129)')))
hi thanks for this beautiful video, i have tried multiple times to connect both microservices but i keep getting this error i am going to post below... requests.exceptions.SSLError: HTTPSConnectionPool(host='localhost', port=8000): Max retries exceeded with url: /products/01G9D4114WV4BSPGG5HV2MGKV0 (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1129)')))
Great tutorial. If anyone is having troubles getting the redis account, note that you can also run a local instance using docker.
This gave me a solid ground of what Microservices are, heard a lot of explanations and demonstrations but never seen a simple tutorial like this. Thank you!
Thank you..the timing of this course is great-just finished FastApi course and then this...watching from Nairobi Kenya
I dream of visiting Kenya soon
me too man...jambo
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
@@taxi_orenburg_ufa_bot karibu kenya
Perfect tutorial.
The guy who is speaking is 100% Albanian
Shoutout to you for not giving the same hello world tutorial that every other creator just copied and pasted off of the documentation
Thanks guys for this great tutorial, adding authentication service won’t hard I guess.
Greetings from Tanzania 🇹🇿
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
Thanks
Hey, thank you for your donation, Abhinav. It means a lot to us. I hope you have a relaxing weekend.
Excellent tutorial ! Just a minor comment - you may avoid using port numbers at the frontend, as they may be changed in different deployment scenarios. :). A tool such as nginx may be very handy.
good thought @Pankesh Patel
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
normally ports should be picked up by some env.port environment variable
Great high level introduction!
i must be doing something wrong here but cant figure out what, when i di the initial post request i get an error back in postman "422Unprocessable Entity" like it cant access the fields....
1 year later, I was facing the same problem and changed the redis-om version to the one he's using for the tutorial - 0.0.20, and now it works!
Great explanation 🙌🙌🙌
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
I really need this! thank you 😆
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
Thankyou 😍 and you earned a new subscriber 👥
Great tutorial by this guy. I've been following him quite a while, he is awesome.
One question though
When you send the order to Redis Stream, you suppose that the other microservice is up and running. In case this process is not running right now and it starts after few seconds, Redis Stream will send whatever in the Stream (the old and new) to this microservice and the microservice will go through all of them again and you will end up having duplicates in your HASH table.
You should remove whatever was consumed from the Stream so in case of subscribing to it you don't get the whole stream again.
on the other hand, you can have multiple instances of the "Consume" process in case you have a lot of orders, each instance takes care of one order after another.
I like you're forward thinking ability 👏👍
@@hakadmedia thanks 🙏🏼🙏🏼
Microservice with nodejs Pleaseeeee
You Rocks Sir 🤟🔥🔥🤟
great content😍
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
Thanks so much great explanation
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
Thank you very much for the video it was very informative
awesome sir
Thanks for this
Thanks you very much ❤
Redis group is working here because both services share same DB.
Which approach should we take with two Redis database for microservice?
I feel like leaving this step out kind of messes with the logic of the entire tutorial. Learned a lot nevertheless, but would have been nice to have the protect use multiple redis dbs.
@@lbb2rfarangkiinok yes, it's a well explained course and good vision of microservices
i tried this with 3 redis instance, or you can use mysql for the inventory and the payment and redis for the group
Thank you
Excellent tutorial guys. I was trying to keep it up on it but unfortunately I've got stock in the first consumer that comes from inventory. Whenever I sent the redis-stream it serves well the data but for some reason the Product.get() method does not work and tends to dispatch me that the product not exists while is already there. How could I solve that issue?
Just to give an update to anybody could be following this video and make their own project structure. I was practicing with the concept of having all the code inside app directory. Therefore:
> inventory
------> app/
|---------> main.py
|---------> consumer.py
For some reason, it seems that redis_om don't handle properly this type of structure due to the Product import not returning the Product object that I already referring to. I'm not really sure why is but if anybody has already work like this and already made all this tutorial with ease, please, let me know because I would like to understand what are the boundaries to not have the microservice work like that. The workaround that I have to make this work was basically get rid of the subdirectory app and have all the main.py, consumer.py in both microservices at root directory.
@@Tigersoulification I'm facing the same problem but do not understand your solution. Could you please explain it. I have both consumer and main within my inventory sub-directory.
I love this so much
Hi, I want to do this project but somehow I stuck at the Front-End part because I've used only Python. Anyone have link for study specific to create the front end part? Thanks
You can look up javascript and Reactjs tutorials on the "Traversy Media" RUclips channel.
@@md-ayaz Thanks!
Really it's nice video
ruclips.net/channel/UCpobn02bRhvDbiGqlsxts0A
I well done
I can't figure out why I get this FastAPIError: Invalid args for response field! Hint: check that is a valid Pydantic field type. Has anyone an idea?
Create your own pydantic model and from it pass args to the Product model.
I had the same issue. You have to install same versions of libs from 4:31. In this case error will not appear.
you can run this command to do it: pip install --no-cache-dir --upgrade -r requirements.txt
downgrade the version of pydantic by running pip install pydantic==1.10.13 this worked for me!
Good day
Thank you for your fabulous work.
Running in background does not work. I'm behind to make it work.
Just wow
Great tutorial. However when I try to replicate the tutorial on my windows machine, I got the error message "Error loading ASGI app. Could not import module "main"". Pls who can I resolve the error?
I thought websockets where used to retrieve information about the pending and completed status and change the frontend instantly
Thanks for the effort but I think this is a multiservices app rather than a microservices one. In microservices each service has its own server and its own database, and the biggest challenge in microservices architecture is how to deseign a database when it’s distributed
Ow dont know that...
in that case, this video is wasted time.
Beginning at 20:14 (the payment microservice), he explains why he isn't using another database.
what is the python3 version you are using ? i am on python 3.8.10 and could not install redis-om on my venv
can anyone help me ?
@@acardosolima1991 thank you for the info, I resolved the conflict by running the service on docker
thanks very much
Good
It would be great to see the jBPM tutorial o your channel :)
DAY 5:PLS DO TENSORFLOW FOR C/C++
Wait for it man ❤️
Good demand is very helpful
Thanks a lot bro you are awesome I wish to work as a sector with you can I ??
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
hey guys ...could you please make a video on Geoinformatics using python.
Don't watch it ruclips.net/video/3mwWIH33h5s/видео.html
Excuse me but i didn't see where redis is needed.
😍😍
Good morning, I'm new - I wanted to ask you if it is appropriate to use Redis in case the relational data constantly changes due to the intervention of external users. That is, the tables are in use in real time so I don't know if it is valid to use Redis in this case and I don't know if it is possible to update a Redis register per sub key. Could you help me with a clarification? thanks
Hello Sir, could you please suggest which programming language should i learn in this year? Thanks
go or rust
My name is Antonio Papa but everybody calls me Antonio
Internal request is a bad practice
How to use it with RabbitMQ?
Why do you always have tutors with accent?
Honestly, what is the point of this video? The way you tackle microservices here is not applicable in production, not in the slightest. And during this video author introduces many antipatterns, both python in general, fastapi and architectural. I understand that this video is not designed to be a manual on how to use microservices in production, but even considering that it does more harm than good imo.
Completely agree. It doesn't even take into account that it's writing blocking code in async views (using requests instead of something like httpx)
@@adrianlazar2185 can you suggest any better video or tutorial?
Please share the source from where I can understand the process.
Exactly. Freecodecamp is declining.
finally a relatable comment - also the teacher doesn't explain the async architecture in detail - it's more like a gulp it down rather than develop your intuition.
looking at this code i realise i still hate python...
Hello @Team,
I get this error
```
raise ConnectionError(self._error_message(e))
redis.exceptions.ConnectionError: Error 111 connecting to localhost:6379. Connection refused.
```
Caused while trying to save to redis, when you comment out the order.save(), there is no error
Found the solution, install redis-server locally and restart your port 8001 sudo apt-get install redis-server 🤣🤣🤣 Happy Coding
Unfortunately, Redis is not supported on Windows. So if you're on a Windows system, you'll need to have a WSL setup and follow setting up a Redis server through the Linux distro.
redis.io/docs/getting-started/installation/install-redis-on-windows/
@@amolikvivian I didn't mention I was using windows 😠😠, I use Ubuntu
@@carrotdev9208 my bad
I have followed your procedure, but I keep getting this error
requests.exceptions.SSLError: HTTPSConnectionPool(host='localhost', port=8000): Max retries exceeded with url: /products/01G9D4114WV4BSPGG5HV2MGKV0 (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1129)')))
hi thanks for this beautiful video, i have tried multiple times to connect both microservices but i keep getting this error i am going to post below...
requests.exceptions.SSLError: HTTPSConnectionPool(host='localhost', port=8000): Max retries exceeded with url: /products/01G9D4114WV4BSPGG5HV2MGKV0 (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1129)')))
Thank you..the timing of this course is great-just finished FastApi course and then this...watching from Nairobi Kenya
Thank you so much 😍👍✌👏🙌😀