AV-Portal 3.23.3 (4dfb8a34932102951b25870966c61d06d6b97156)

Introduction to aiohttp

Video in TIB AV-Portal: Introduction to aiohttp

Formal Metadata

Introduction to aiohttp
Title of Series
Part Number
Number of Parts
CC Attribution - NonCommercial - ShareAlike 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal and non-commercial purpose as long as the work is attributed to the author in the manner specified by the author or licensor and the work or content is shared also in adapted form only under the conditions of this license.
Release Date

Content Metadata

Subject Area
Andrew Svetlov - Introduction to aiohttp aiohttp is asynchronous HTTP client and server library built on top of asyncio. The library allows to write user friendly code which looks like well-known linear one (requests library for client and Django/Flask/Pyramid for server) but utilizes the power of non-blocking sockets and supports websockets natively. The intro describes basic programming patterns for both client and server API as well as more advanced techniques. Tips and tricks for writing asyncio-based code are included as well. The main target of the talk is displaying an alternative to people who want to avoid classic WSGI frameworks (Django/Flask/Pyramid etc) limitations but found Twisted and Tornado too cumbersome. Dive into aiohttp usage with the library author.
Computer animation Software developer
Digital electronics Computer animation Software developer Software developer Device driver Core dump Extension (kinesiology) Rule of inference Flow separation Position operator Software maintenance
Classical physics Medical imaging Server (computing) Computer animation Information Order (biology) Energy level Web browser Client (computing) Object (grammar) Recurrence relation
Server (computing) Scaling (geometry) Computer animation Cellular automaton Endliche Modelltheorie Power set Thread (computing) Task (computing) Library (computing)
Computer animation Root Decision theory Projective plane Sampling (statistics) Data storage device Code Client (computing) System call Reading (process)
Point (geometry) Web 2.0 Dependent and independent variables Computer animation Binary code Coma Berenices Disk read-and-write head Library (computing)
Email Group action Dependent and independent variables Server (computing) Multiplication sign Data storage device Letterpress printing Content (media) Mereology Connected space Computer animation Bridging (networking) Traffic reporting Physical system Condition number Data type
Ocean current Dependent and independent variables Multiplication sign Hessian matrix Open set Content (media) Sequence Demoscene Product (business) Connected space Permutation Data management Word Computer animation Bit rate Single-precision floating-point format Synchronization output Resultant Data type
Rule of inference Functional (mathematics) Greatest element Weight Electronic program guide Coroutine Limit (category theory) Complete metric space Rule of inference Computer programming Word Computer animation Function (mathematics) Order (biology) Synchronization Thumbnail Resultant Task (computing)
Point (geometry) Graph (mathematics) View (database) Client (computing) Mereology Computer programming Computer animation Synchronization Ideal (ethics) Operating system Musical ensemble Information security Resultant Task (computing) Condition number
Data management Context awareness Graph (mathematics) Computer animation Information Internetworking Synchronization Measurement Communications protocol Resultant Connected space Exception handling
Server (computing) Greatest element Functional (mathematics) Code Execution unit Set (mathematics) Price index Client (computing) Graph coloring Revision control Web 2.0 Different (Kate Ryan album) Position operator Exception handling Form (programming) World Wide Web Consortium Socket-Schnittstelle Mobile app Dependent and independent variables Server (computing) Gender Weight Content (media) Mathematical analysis Client (computing) Control flow Cartesian coordinate system Subject indexing Message passing Process (computing) Computer animation Telecommunication Synchronization Video game Right angle Iteration Cycle (graph theory) Object (grammar) Quicksort Router (computing) Directed graph
Mobile app Standard deviation Computer animation Social class Flow separation Metropolitan area network World Wide Web Consortium
Dataflow Code Multiplication sign Range (statistics) Client (computing) Inequality (mathematics) Value-added network Product (business) Mechanism design Goodness of fit Different (Kate Ryan album) Single-precision floating-point format Form (programming) World Wide Web Consortium Socket-Schnittstelle Dependent and independent variables Server (computing) Control flow Connected space Message passing Process (computing) Computer animation Integrated development environment Telecommunication Order (biology) Synchronization Family Resultant Reading (process)
Cycle (graph theory) Software developer Mathematical analysis Distance Single-precision floating-point format Process (computing) Computer animation Internetworking Integrated development environment Software testing Process (computing) Vertex (graph theory) Quicksort Reverse engineering
Dependent and independent variables Computer animation Personal digital assistant Direction (geometry) Telecommunication Synchronization Complete metric space Loop (music) Computer programming Exception handling Task (computing)
Point (geometry) Asynchronous Transfer Mode System call Run time (program lifecycle phase) Run time (program lifecycle phase) Line (geometry) Plotter Computer file Workstation <Musikinstrument> Bit Error message Event horizon Computer animation Object (grammar) Synchronization Quicksort Object (grammar) Exception handling Loop (music) Exception handling
Default (computer science) Functional (mathematics) State of matter Cellular automaton Neighbourhood (graph theory) Complete metric space Medical imaging Protein folding Computer animation Synchronization Social class Software testing Software testing Musical ensemble Proxy server Task (computing) Loop (music) Task (computing) Chi-squared distribution
Mobile app Addition Execution unit Client (computing) Client (computing) Price index Cartesian coordinate system Dimensional analysis Goodness of fit Computer animation Synchronization Entropie <Informationstheorie> output Quicksort Pressure Router (computing) World Wide Web Consortium
Game controller Computer animation Object (grammar) Synchronization Password Set (mathematics) Login Software testing Client (computing) Endliche Modelltheorie Rule of inference
Point (geometry) Trail Server (computing) Functional (mathematics) Computer file Latin square Connectivity (graph theory) Real number Password Data storage device Mereology Product (business) Web 2.0 Different (Kate Ryan album) Term (mathematics) Object (grammar) Software testing Software framework Proxy server Computing platform Task (computing) Mobile app Default (computer science) Dependent and independent variables Structural load Gender Physical law Interior (topology) Login Bit Database Line (geometry) Instance (computer science) Cartesian coordinate system Connected space Web application Arithmetic mean Wave Curvature Befehlsprozessor Computer animation Software Synchronization Natural language Right angle Limit of a function Writing Spacetime
Area Boss Corporation Message passing Arithmetic mean Computer animation Observational study Code Linear regression Personal digital assistant Food energy Library (computing)
to use and slip nothing that love and I think you know what he's talking about the because you hear the and to see for the next local them very interesting and OK thank you few this dried up and make a simple of and election for Our should be I am I and a small on what what and the developer useful the full 16
years and adult before last for bonds I took about and basically development is the comedian and I now my minding their own willful the and of that does not the love is now under I would be somewhere like this
positives drivers there are several RGB extensions the rated driver qualities many articles and find a golf crowded so Prof me all fronts and how to represent a circuit court why of of of almost 4 why do you need to a simple rules called right so and that's what knowledge
is an age old Microsoft's right and was an image of classics edition recurrent client is so is a browser all client which goes through API to recover from outside the front side candidates a lot of micro-services in Donald microservices and external services like treated the problem phrase book order and and then that is this lecture we usually issued to perform many
level it should be requests for all our from outside 2 of microsources collect data back to the past and object to you've of made by hand again use and we can use a single also these casual information can support about falls under diets so but we use a single your use of light with that's uh marked increase to medium
powerful set server might support more of the following cells and maybe they had itself but don't need it but
it's still all imitation is a gradual and any I think girls that wrote also scale of models to do but a little more what a lower world they only the you you want you don't have to use to be want dust in Boston a lot of helpful literally the issue might but to now you so I actually being there is a library because people were agrees rare or a professional and it should be from both sides and going in the support so this is a collection
of hundreds of samples of books and many many of us a sense of later as problem has played years launch storing and adrenaline been and was popular for a single your involves style called due in but to the read but all we started 2 new project and what should be and it was good decision because I had should be root was when he young on those days it changes Gretely end the we
and is 24 develop tended to releases so far is much faster than I know which should be reduced size of 104 call for the good of shows would grow coverage of mention of of client API now planted guy
sound hollow like request it's not just a total it that will be about is point of the what I believe everybody know our requests workers concerned that may be the most popular quite a library for Python on the right uh requests get called get response but it could also hold responsible to school to get to the response body against that Jason binary while the experience of however translate it is by your watch always so that and that because and and I O GPV don't want to encourage them from bed
no not welcome as web users practice the head uh no it's still work I can write it but it's difficult let's go so that a question of the
session of constant the session is that had the full who storage and for of connection to and then you can there were from get requests on sessions it sports bag and ask for the response that that's uh fashion support people i've session support group use bloods 440 my
make your system of articles of 3 5 7 times faster depends on wonderment metro and also long your server these from 1 but I highly commend to use session because of the unfortunately has a tells should reach the user of the condition bridge which user a local of them but it was accommodation of Don encouraged session usage for the most part of the proposed court report which operates with request is not optimal from my experience I have not only the
election he glanced at the current session of socialization that we have know get response but what is the use this increase in a single product manager for the results for a gracefully calls in all resources open connection open response uh and it's facing because we talked so that in a sequence sequences and because of the response here and before of the androgen response body you should use every scene that's again because of the we usually you have heeded this will skew the immediately at hand that he did as a whole response by all of the response body all begin by chance by John takes time and requires by your request Input
alt from permutation so so the require rate yeah and no 1 will say complex all of words about the guardians room this
addendum complex uh concept but for casual users and it and it can be divided into 2 where wedding simple rules problems so got in these functions which is not there but it seems that if you see as and that it means you knew that I would do it so it really is currently and if you will have to go currently hold every toward before before the goal of like and see all the limit function and if your function that they the weights inside it should be currently itself so the function itself should be assumed that all the was of next words
in them as a power over of single most approach the a way for making programs if we need to bridge so resources being battle that began canadian several tasks past using led a trait and execute it in but I will wait for all last 2 reasons for all results although it use the knowledge that is a singular what guide for breaking uh results as they complete their completion order and our fetches the real the real tried to French both bottom all the home what does it mean higher
in died point of view so you're school security French what I want you see music and obviously it's law if if a stop the ideal place invite sense to deal and also the conditions and that is that uh the thing executed in battle but that part of this graph is there way to use the weapons program does not but full knowledge fall deal with that is independent of the a a thing called it's a good there is in this the same stretch very my usually the main thing what siege Michael at the feature between tasks there and it doesn't really quickly the result
need for operation system complex the siege and that's true it supports so many on Venus these the next thing would you should when you uh works we client guy he's them out quite and because the any requests at a drive to acquired data from certain made full away along that you spend millions so demands a new
result disconnection uh exception to of mainly in information any suggestion was so bad is done when it opens you better get exception weekly but sometimes you get white because Internet were rocked things this way in the cannot not so change in the
protocol but this kind of graph are close on by mild context manager and the it's 1st of all I recommend to use the mouse and that's measure really let's look at this very simple
and Hall Real Madrid's WebSockets um instead of the same session get concession bolstered you and use the session uh WebSocket connect what the WebSocket and and get but something object to the delayed are worth messages that something as sink for these sucrose iteration it may wait for next message you still not and on weight a cigar you'll we'll see each true positive costs random when a message is ready to be checked for message content and the streets were for closing we call them and also you know something about the form of communication and this is base basic the bottom and the all looks like and quite would like this is the full life cycle the now what sort of ability everybody and also called right color John and an agenda if you have a review is there is some function reach a set uh request and that our response that you will you will find your my beach makes from that I have for you to of you function and executed quite job done manage coming the aim of which you have almost the same when look at actually the web server high-level that what would maybe I'd that we be died to being the way goes to do gender place bottle to classic rejection of only has 1 exception our code is a single so we can also thank you you it's called but more of a kind of in the version justification beach % progressed job responses and applications to Justice Robert full you parameter everything about what is the Our index is not rare function it's court which means that we
can do a single most work inside produce and it the most severe obviously these began in quest for the art resources while client API and it again and do WebSocket communications and be in to left the communities the uh from broke the shouldn't do during answer as weak as possible we can make use end users blind obviously it really not see an end sort of Greek but it doesn't depend a server is what we did inside our web and that style positive candidates if they have something to do it's their main ends and biggest difference between i which he and all positive we use the Ferber but it also many right these different and there are not and my mind it doesn't detonator demand is also a singles out from a as well as the what that made that the unit of analysis and concepts and demanded that can that made the
request and user should die from me and what I get it man might go through all or some of the mn it to it works I don't way but can you use it but then we found that and applies to uh Red all weapons constant is much easier for the standard for end users that's why we built to a single
a single quote in this way that not in the not frightening WebSockets for quiet for several looks almost the same
as client why what is that only have some difference should create WebSocket response burp range from unequal requests and at the very top of hour messages from but took a response of the things that only seeing what you should keep in mind these are and like all positive literal
communication and you will have to move have some on mechanism for have been the mouse will because the circus that can stop working result in traditional flow for a long time and the brother of product harmonic being and must be form and communication going parameters and if a good form sovereign readings Glenn disconnect In order to promote the use of such as for and how to develop into the problems effectively it feels around this on all data would not be an environment as single process of 10 played in your code after the binding taste and you can deploy on different docking companions and different brands on different nodes he
did all of on the internet in the reverse proximal but for development it's much much easier to would everything into the same process 1 sort of I didn't expect it when to well it's a
different analysis not so you have to pay for what the true removed due dual screen and on the implementation of of the sort of thing the use of what were the if you so the annotation the good don't require an room
and tools like so if you just can't create that long-running task for new direct inside your program it is more much more and easier sometimes you need that the standard uh binding dust and you choose to be be
stopped in the following task completion of has failed but it's this it's institution that in the most cases you can just go new task in in the center of the and you can do where it alone belongs communication inside the country it's written in next distance and and of you if you for that to close gracefully you're responsible MIT stuff you will get an exception like the it's the exceptions fiction awarding
huge exception was never tried it's wrong it's sort of a government yeah uh you see runtime Europe as what world what exceptionals pushed into future before bit and that is all but have no idea where good be just so run from reason by than a single you the ball and what plot and you will see that is by the use the point where uh but it could also be object was could not also had a kind of comment there was little everywhere all don't all speak at all why it's important that it's important because so easy to right this
this explicitly of God told about requiring requirements station
and use each fold trading state and for people to buy the right open connection before so the support and keep alive in the middle what what the uh 1 session we will cover the syllabus for which we waited for all these task completion let's think cultural this isn't about creating new moving through for fall testing set up disable and defaulting and wanted long close to also this function in this the general should be a regular function not working so the history of hopefully will in RGB because decorator image I do not think that these around and incomplete about for understanding really we should have a good working inside the neighborhood function and about skull and why it is important to disable global because is gobbled enable that really got started task you want this initiative successfully a
execute the hand was more based tool or 10 and a on the 12 this is a fusion your task for all of the cells that may fail because then each of their shares of the same you know the uh disabling default will make this really separated and that is why important to grow fossil everywhere I don't watch a collection between the 2 that the different this example how it books music like this forever honestly
I prefer applied this knowledge dotted units for long fall from all indication about censorship but this was not recover but essentially body in and the Anderson looks these entropy kind of kitchen you you have write this client is again the sort most the methods and also and that is the the obligations Boston and then you need to go and the referral this request through our this so that there are lots of that's when it is and where convenient to have
this that and tasting good teams in and is the same day and you don't have to start separate they had for start and application of simple approaches you can call altogether and you can easily insult input could be to be said traceable would a pressure for In addition to the body of work the final it's about and the last 1 the 1 dimension is strong FastICA full question asking to use the uh about code like
this is this is monocline among the decline and it works with around but when he started to write test for this best friend kind what went just because that's a model of client and a set of rules it it also going to women to do full control Justice
finished 2nd best started it created and good enough but they're asking people funding data using modern
glamor have covered not to use any immortal is a bad idea and depends on but it would do request because our it's an an obligation is the decline of 2 you can post everything into this man's face and that is intuitive when creating applications we because 1 lines will into our obligation and space and it just simply not progress with social Dialogue connection through got this is the same you're going to lose
their databases is evidence that would uh an interesting uh not all of them collapsing that is all all of this function and that's what we're interested in German questions and fj the the other questions comments camera so disabling global rental minor mental might serve execution not a single anymore for testing so that test platform will be executed 1 by 1 and not sharing the same on the same track not sharing the main trick just to simplify the binding the right there are ways to use the another person see you can the creative and will and that it just as the new government will this default every dive for evidence that's a default and we'll be new instance by a pond it's the error-prone the the the the the maybe is the heaviest wave by them mom must safe way to pull of possible everywhere maybe some but it's my my opinion and my experience another question yeah so far I was doing to benchmarking of a service following a synchronous framework and mean annual to and what I've noticed is that I can have about 16 news millisecond latency all its requests for like say 20 thousand the requests a 2nd and when I double the load so 14 thousand regressor 2nd it's still the same Latin Cecil what happened so it up is that you know it it was still free CPU of earlier about if I doubled I've doubled the load but it's still the same latency the did you observe something like that or you know that uh they do take a look at this benchmark of of the story that indicate what OK so I will talk to to you and it I hope thanks and Questions here having just a question had a german questions question from previous question was the latency actually it wasn't in a single laws into a network latency women to just just a question and and various you told to uh might be quite a bit of web apps Python has a great story in terms of writing as well where that's really easy to write Web apps and actually payment deployed say you can Martin operates simply Trontelj gender any of of of frameworks and they want to deploy it you have to start configuring engine makes you have to to start a new century furor not running tasks and you have read this for your temporary you tell your catching and you have lots of different components with fragile connection between them so the whole thing becomes before nightmare and they're very fragile part about so a education looks like we can simplify the whole thing a great deal and it will you mentioned getting rid of salary and because of the their long-running tasks and he's amazing framework that's great but I'm just wondering why you suggested and deploying behind engine genetics ecologists he's facing http and and and so that as the concept of the as a product and service that's that's 1 question another question is http to support OK uh as a should you can be used as the just epsilon militarist proxy do but of a complex and I recommend to push the the kind engines white toast you would usually have to have a flat file by files it is the a requirement doing much better is white and we can use the default support but to full real performance and usage of and another a that point of much more important than genetics there has led to the long story for all
couple of preventing about my worst full prevented a document code and it just done by limiting sciences it has when a good experiences a don't it has the best but I don't uh the areas but I'm not 100 % sure we have no useful about that should be doing over whole plants but not in have have not not most of the energy a lot of people request but it's 200 we have 1 more question again I think you for the talk so the question is bit more like the other features in mind to add to the library meaning that the studies on roadmap for this kind of thing you're a remote room was and they're not sold formalized tend to have their own merits but what you can achieve hosted on the top here issues that and the the uh in uh in uh note that it's that should to support performance and message some regression and fixed in our boss you use no pointing to that of course this is any other questions this is not the case this 98 and