Webinar topic: ISP Load Balancing with Mikrotik ECMP
Presenter: Achmad Mardiansyah
In this webinar series, We are discussing ISP Load Balancing with Mikrotik ECMP
Please share your feedback or webinar ideas here: http://bit.ly/glcfeedback
Check our schedule for future events: https://www.glcnetworks.com/schedule/
Follow our social media for updates: Facebook, Instagram, YouTube Channel, and telegram
Recording is available on Youtube
https://youtu.be/pUy6-EOy2mM
Technical report representing the State of the Art of IoT Honeypots developed for the Seminar in Advanced Topics in Computer Science course of the Master Degree in Engineering in Computer Science curriculum in Cyber Security at University of Rome "La Sapienza".
The paper presents which are the current technologies for honeypots systems together with an introduction to IoT Malware and Botnets & Distributed Denial of Service (DDoS) attacks.
Webinar topic: ISP Load Balancing with Mikrotik ECMP
Presenter: Achmad Mardiansyah
In this webinar series, We are discussing ISP Load Balancing with Mikrotik ECMP
Please share your feedback or webinar ideas here: http://bit.ly/glcfeedback
Check our schedule for future events: https://www.glcnetworks.com/schedule/
Follow our social media for updates: Facebook, Instagram, YouTube Channel, and telegram
Recording is available on Youtube
https://youtu.be/pUy6-EOy2mM
Technical report representing the State of the Art of IoT Honeypots developed for the Seminar in Advanced Topics in Computer Science course of the Master Degree in Engineering in Computer Science curriculum in Cyber Security at University of Rome "La Sapienza".
The paper presents which are the current technologies for honeypots systems together with an introduction to IoT Malware and Botnets & Distributed Denial of Service (DDoS) attacks.
Support formation vidéo : Réussir la certification Linux LPIC-1 (1)SmartnSkilled
Préparez-vous à la certification linux LPIC-1 avec votre expert Anis Hachani.
Cette formation vous permet de :
- Construire des bases solides avec Linux.
- Devenir opérationnel avec n’importe quelle distribution Linux.
- Préparer à la certification LPIC-1.
- Comprendre et préparer les différents thèmes requis pour l'examen LPIC-1 101 & 102 fixés par LPI.
Suivez la formation vidéo par ici :
https://www.smartnskilled.com/tutoriel/formation-en-ligne-reussir-la-certification-linux-lpic-11
Network LACP/Bonding/Teaming with MikrotikGLC Networks
Webinar topic: Network LACP/Bonding/Teaming with Mikrotik
Presenter: Achmad Mardiansyah
In this webinar series, How Network LACP/Bonding/Teaming with Mikrotik
Please share your feedback or webinar ideas here: http://bit.ly/glcfeedback
Check our schedule for future events: https://www.glcnetworks.com/en/schedule/
Follow our social media for updates: Facebook, Instagram, YouTube Channel, and telegram also discord
Recording available on Youtube
https://youtu.be/smRcyLE42hU
Part 3 - Local Name Resolution in Linux, FreeBSD and macOS/iOSMen and Mice
The focus of this webinar will be to take a deeper look into this local name-resolution system and the implementations for other Unix systems like Linux and FreeBSD. Linux’s new über-Daemon “systemd” supports both mDNS and the Windows LLMNR (Link-Local-Multicast-Name-Resolution). We will also show how well a Systemd-Linux behaves in heterogenous networks running both Windows and macOS.
>> What is Bare Metal?
>> Features of Bare Metal.
>> What Is A Hypervisor?
>> Features of Hypervisors.
>> Advantages of bare metal.
>> Disadvantages of Bare metal.
>> Advantages of hypervisors.
>> Disadvantages of Hypervisors.
Optimizing SAO with Open Source Tools. A deep dive into the Phishing Intelligence Engine (PIE) and how users can leverage infrastructure and open source to automate and respond to threats.
Le lecteur trouvera dans le premier chapitre une brève description de l’architecture du réseau GSM et de ces composants. Le deuxième chapitre discutera les étapes de planification d’un réseau cellulaire parmi lesquelles on trouve celle du réseau fixe. Le troisième chapitre sera consacré à la description et à la formulation des différentes problématiques qui se posent lors de la planification du réseau fixe. Et avant de se lancer dans le chapitre cinq qui explique les différents modules utilisés dans l’application, le chapitre quatre explique le principe de quelques méthodes heuristiques utilisées pour la résolution des problèmes tel que celui étudié dans ce travail
We use websockets for our clients because we care deeply about a fast, responsive user experience. At the Play! Framework meetup based near us in Mountain View, CA (http://www.meetup.com/PlayFramework/), we presented an introduction to using Websockets with Play!. We cover some relevant background into alternatives, benchmarks, and how Websockets work within Play!.
Video: https://www.youtube.com/watch?v=b6yLwvNSDck
Here's the showdown you've been waiting for: Node.js vs Play Framework. Both are popular open source web frameworks that are built for developer productivity, asynchronous I/O, and the real time web. But which one is easier to learn, test, deploy, debug, and scale? Should you pick Javascript or Scala? The Google v8 engine or the JVM? NPM or Ivy? Grunt or SBT? Two frameworks enter, one framework leaves.
This is the English version of the presentation. For the version with Japanese subtitles, see http://www.slideshare.net/brikis98/nodejs-vs-play-framework-with-japanese-subtitles
Support formation vidéo : Réussir la certification Linux LPIC-1 (1)SmartnSkilled
Préparez-vous à la certification linux LPIC-1 avec votre expert Anis Hachani.
Cette formation vous permet de :
- Construire des bases solides avec Linux.
- Devenir opérationnel avec n’importe quelle distribution Linux.
- Préparer à la certification LPIC-1.
- Comprendre et préparer les différents thèmes requis pour l'examen LPIC-1 101 & 102 fixés par LPI.
Suivez la formation vidéo par ici :
https://www.smartnskilled.com/tutoriel/formation-en-ligne-reussir-la-certification-linux-lpic-11
Network LACP/Bonding/Teaming with MikrotikGLC Networks
Webinar topic: Network LACP/Bonding/Teaming with Mikrotik
Presenter: Achmad Mardiansyah
In this webinar series, How Network LACP/Bonding/Teaming with Mikrotik
Please share your feedback or webinar ideas here: http://bit.ly/glcfeedback
Check our schedule for future events: https://www.glcnetworks.com/en/schedule/
Follow our social media for updates: Facebook, Instagram, YouTube Channel, and telegram also discord
Recording available on Youtube
https://youtu.be/smRcyLE42hU
Part 3 - Local Name Resolution in Linux, FreeBSD and macOS/iOSMen and Mice
The focus of this webinar will be to take a deeper look into this local name-resolution system and the implementations for other Unix systems like Linux and FreeBSD. Linux’s new über-Daemon “systemd” supports both mDNS and the Windows LLMNR (Link-Local-Multicast-Name-Resolution). We will also show how well a Systemd-Linux behaves in heterogenous networks running both Windows and macOS.
>> What is Bare Metal?
>> Features of Bare Metal.
>> What Is A Hypervisor?
>> Features of Hypervisors.
>> Advantages of bare metal.
>> Disadvantages of Bare metal.
>> Advantages of hypervisors.
>> Disadvantages of Hypervisors.
Optimizing SAO with Open Source Tools. A deep dive into the Phishing Intelligence Engine (PIE) and how users can leverage infrastructure and open source to automate and respond to threats.
Le lecteur trouvera dans le premier chapitre une brève description de l’architecture du réseau GSM et de ces composants. Le deuxième chapitre discutera les étapes de planification d’un réseau cellulaire parmi lesquelles on trouve celle du réseau fixe. Le troisième chapitre sera consacré à la description et à la formulation des différentes problématiques qui se posent lors de la planification du réseau fixe. Et avant de se lancer dans le chapitre cinq qui explique les différents modules utilisés dans l’application, le chapitre quatre explique le principe de quelques méthodes heuristiques utilisées pour la résolution des problèmes tel que celui étudié dans ce travail
We use websockets for our clients because we care deeply about a fast, responsive user experience. At the Play! Framework meetup based near us in Mountain View, CA (http://www.meetup.com/PlayFramework/), we presented an introduction to using Websockets with Play!. We cover some relevant background into alternatives, benchmarks, and how Websockets work within Play!.
Video: https://www.youtube.com/watch?v=b6yLwvNSDck
Here's the showdown you've been waiting for: Node.js vs Play Framework. Both are popular open source web frameworks that are built for developer productivity, asynchronous I/O, and the real time web. But which one is easier to learn, test, deploy, debug, and scale? Should you pick Javascript or Scala? The Google v8 engine or the JVM? NPM or Ivy? Grunt or SBT? Two frameworks enter, one framework leaves.
This is the English version of the presentation. For the version with Japanese subtitles, see http://www.slideshare.net/brikis98/nodejs-vs-play-framework-with-japanese-subtitles
The word "Reactive" can be confusing. As the founder of the Reactive Amsterdam meetup, I can tell there are two main topics here: Functional Reactive Programming (here with reference to Android) and "Reactive" in the sense of the Reactive Manifesto.
WebSocket MicroService vs. REST MicroserviceRick Hightower
Comparing the speed of RPC calls over WebScoket Microservices versus REST based microservices. Using wrk, QBit, and examples in Java we show how much faster WebSocket is for doing RPC service calls.
Training Webinar: Enterprise application performance with server push technol...OutSystems
1st Session - WebSockets, a Server Push Technology:
- Differences between Pull and Push technologies
- What are WebSockets
- A bit of History behind WebSockets
- When to use WebSockets
- How to integrate WebSockets with OutSystems
- Considerations when using WebSockets
Free Online training: https://www.outsystems.com/learn/courses/
Follow us on Twitter http://www.twitter.com/OutSystemsDev
Like us on Facebook http://www.Facebook.com/OutSystemsDev
Typesafe trainer and consultant Will Sargent describes just how Play Framework is so "fast" for Java and Scala production apps.
More Play, Akka, Scala and Apache Spark webinars, presentations, and videos:
http://typesafe.com/resources/videos
JavaFX 2 and Scala - Like Milk and Cookies (33rd Degrees)Stephen Chin
JavaFX 2.0 is the next version of a revolutionary rich client platform for developing immersive desktop applications. One of the new features in JavaFX 2.0 is a set of pure Java APIs that can be used from any JVM language, opening up tremendous possibilities. This presentation demonstrates the benefits of using JavaFX 2.0 together with the Scala programming language to provide a type-safe declarative syntax with support for lazy bindings and collections. Advanced language features, such as DelayedInit and @specialized will be discussed, as will ways of forcing prioritization of implicit conversions for n-level cases. Those who survive the pure technical geekiness of this talk will be rewarded with plenty of JavaFX UI eye candy.
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...Edward Burns
Servlet is very easily the most important standard in server-side Java. The much awaited HTTP/2 standard is now complete, was fifteen years in the making and promises to radically speed up the entire web through a series of fundamental protocol optimizations.
In this session we will take a detailed look at the changes in HTTP/2 and discuss how it may change the Java ecosystem including the foundational Servlet 4 specification included in Java/Jakarta EE 8.
Why test automation is getting more difficult, and what can be done about it. This slides are from a presentation by Group Director, Product Management at TestPlant, Gordon McKeown, which was presented at the Northern Lights conference in Manchester in April 2016.
Html5 web sockets - Brad Drysdale - London Web 2011-10-20Nathan O'Hanlon
This month we focus in on WebSockets in HTML5 with Brad Drysdale.
You're probably aware of the various chat systems around the web (facebook chat for example) but recently there has been more of a desire for other types of interaction using these technologies. Many have requested talks on Node.js, Comet long-polling, or similar technologies. WebSockets are the evolution of these technologies, and a developing standard being progressed by the IETF.
The HTML 5 standard specifies new APIs for storage, drawing, drag-and-drop, and other areas that have made web programming painful. Browsers have already begun incorporating parts of HTML 5 (canvas, for example) even though the specification is far from complete. The HTML 5 Communication section includes two additional connectivity features: Server-Sent Events, a standardization of HTTP push, and Web Sockets, a cross-domain safe, full-duplex connection. Server-Sent Events will make real-time updates and notifications easy, and Web Sockets provide the functionality necessary to build chat for the web without the previously required hackery.
Come and hear the latest on what this great technology allows!
Brad Drysdale is the Technical Director in EMEA for Kaazing. Brad has also worked at Openwave and Netscape Communications in various pre-sales and technical evangelist roles.
How to Build Single Page HTML5 Apps that ScalePhil Leggetter
Developing large apps is difficult. Ensuring that code is consistent, well structured, tested, maintainable and has an architecture that encourages enhancement is essential. When it comes to large server-focused apps, solutions to this problem have been tried and tested.
But, how do you achieve this when building HTML5 single page apps?
In this talk we’ll cover the signs to watch out for as your HTML5 SPA grows and provide examples of some of the tooling types that can contribute-to as well as ease the growing pains. Finally, we’ll demonstrate how tooling can be used to support a set of conventions, practices and principles that enable a productive developer workflow where the first line of code is feature code, features can be developed in isolation, code conflicts are avoided by grouping assets by feature and features are composed into apps.
The demonstrations will use BladeRunnerJS, an open source developer toolkit written in Java, but the concepts are widely applicable.
Top 10 HTML5 Features for Oracle Cloud DevelopersBrian Huff
Whether you are using Mobile, Social, Java, or Sites in the cloud, HTML5 is probably the easiest way to create and maintain web applications. Most of the Oracle cloud supports HTML5, so it is important to understand what powerful new features are built into this platform.
Code for Startup MVP (Ruby on Rails) Session 1Henry S
First Session on Learning to Code for Startup MVP's using Ruby on Rails.
This session covers the web architecture, Git/GitHub and makes a real rails app that is deployed to Heroku at the end.
Thanks,
Henry
Enjoying the Move from WCF to the Web APIKevin Hazzard
A more advanced talk for those developers thinking of making the move from ASMX or WCF-based services to the ASP.NET Web API. RESTful services have their place in the middle tiers and this talk addresses how to make the mental shift toward REST. There's a lot of focus on how to ease the transition from such a complex framework as WCF to something as simplistic as the Web API.
Slides for the talk I gave at the 2020 conference "Sofware Circus: Down The Rabbit Hole" . Attendees are given an overview of Deep Learning and a unique dataset to start experimenting. Code and images are available here: https://github.com/ticofab/deep-learning-with-scala
Slides of Maxim Burgerhout from RedHat ( @MaximBurgerhout ). This presentation was given at the Reactive Amsterdam meetup: https://www.meetup.com/Reactive-Amsterdam , in collaboration with GOTO Nights Amsterdam. Recording of the talk is here: https://www.youtube.com/watch?v=X2NFGHQzQok
Ten Frustrations From The Community Trenches (And How To Deal With Them)Fabio Tiriticco
As community managers dealing with people, we are all bound to deal with frustrations at some point. This talk goes over a few common ones and reveals a few tips to deal with them.
We all need friends and Akka just found KubernetesFabio Tiriticco
We all feel alone sometimes. Akka got along well with the VM crew ever since it was born, but new friends and fresh ideas are always necessary. Which is why lately Akka loves spending time with Kubernetes! Maybe the reason why they like each other so much is their sharing of core values such as transparent scalability and resilience.
How do these two technologies compare from a Reactive standpoint? Does one supersede the other? In fact, their powers can be combined to design distributed systems all the way from application code to cloud instance.
Cloud native akka and kubernetes holy grail to elasticityFabio Tiriticco
Akka is the most mature choice to implement the traits of the Reactive Manifesto, thanks to the Actor model. But we need to rely on some external infrastructure to automatically scale up or down our services. We found Docker & Kubernetes to be a perfect match for clustered Akka applications.
My personal highlights from the Reactive Summit 2017. I loved the conference from the beginning till the end and I shared some of that with my Reactive Amsterdam meetup. All content belongs to the respective speakers.
Beyond Fault Tolerance with Actor ProgrammingFabio Tiriticco
Actor Programming is a software building approach that lets you can go beyond fault tolerance and achieve Resilience, which is the capacity of a system to self-heal and spring back into a fresh shape. First I'll introduce the difference between Reactive Programming and Reactive Systems, and then we'll go over a couple of implementation examples using Scala and Akka.
The coupled GitHub repository with the code is here: https://github.com/ticofab/ActorDemo
** Video of this talk is here: https://youtu.be/MQGXrrhGUTw **
The first talk of the Meetup on the 11th of April 2017, hosted by weeronline.nl in their Amsterdam offices.
Streams are everywhere! Akka Streams help us model streaming processes using a very descriptive DSL and optimising resource usage.
For most of us, Reactive Android means using RxJava. In this presentation, I try to borrow a few ideas from the backend world and enrich the concept of Reactive in Android.
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...James Anderson
Effective Application Security in Software Delivery lifecycle using Deployment Firewall and DBOM
The modern software delivery process (or the CI/CD process) includes many tools, distributed teams, open-source code, and cloud platforms. Constant focus on speed to release software to market, along with the traditional slow and manual security checks has caused gaps in continuous security as an important piece in the software supply chain. Today organizations feel more susceptible to external and internal cyber threats due to the vast attack surface in their applications supply chain and the lack of end-to-end governance and risk management.
The software team must secure its software delivery process to avoid vulnerability and security breaches. This needs to be achieved with existing tool chains and without extensive rework of the delivery processes. This talk will present strategies and techniques for providing visibility into the true risk of the existing vulnerabilities, preventing the introduction of security issues in the software, resolving vulnerabilities in production environments quickly, and capturing the deployment bill of materials (DBOM).
Speakers:
Bob Boule
Robert Boule is a technology enthusiast with PASSION for technology and making things work along with a knack for helping others understand how things work. He comes with around 20 years of solution engineering experience in application security, software continuous delivery, and SaaS platforms. He is known for his dynamic presentations in CI/CD and application security integrated in software delivery lifecycle.
Gopinath Rebala
Gopinath Rebala is the CTO of OpsMx, where he has overall responsibility for the machine learning and data processing architectures for Secure Software Delivery. Gopi also has a strong connection with our customers, leading design and architecture for strategic implementations. Gopi is a frequent speaker and well-known leader in continuous delivery and integrating security into software delivery.
JMeter webinar - integration with InfluxDB and GrafanaRTTS
Watch this recorded webinar about real-time monitoring of application performance. See how to integrate Apache JMeter, the open-source leader in performance testing, with InfluxDB, the open-source time-series database, and Grafana, the open-source analytics and visualization application.
In this webinar, we will review the benefits of leveraging InfluxDB and Grafana when executing load tests and demonstrate how these tools are used to visualize performance metrics.
Length: 30 minutes
Session Overview
-------------------------------------------
During this webinar, we will cover the following topics while demonstrating the integrations of JMeter, InfluxDB and Grafana:
- What out-of-the-box solutions are available for real-time monitoring JMeter tests?
- What are the benefits of integrating InfluxDB and Grafana into the load testing stack?
- Which features are provided by Grafana?
- Demonstration of InfluxDB and Grafana using a practice web application
To view the webinar recording, go to:
https://www.rttsweb.com/jmeter-integration-webinar
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Generating a custom Ruby SDK for your web service or Rails API using Smithyg2nightmarescribd
Have you ever wanted a Ruby client API to communicate with your web service? Smithy is a protocol-agnostic language for defining services and SDKs. Smithy Ruby is an implementation of Smithy that generates a Ruby SDK using a Smithy model. In this talk, we will explore Smithy and Smithy Ruby to learn how to generate custom feature-rich SDKs that can communicate with any web service, such as a Rails JSON API.
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Jeffrey Haguewood
Sidekick Solutions uses Bonterra Impact Management (fka Social Solutions Apricot) and automation solutions to integrate data for business workflows.
We believe integration and automation are essential to user experience and the promise of efficient work through technology. Automation is the critical ingredient to realizing that full vision. We develop integration products and services for Bonterra Case Management software to support the deployment of automations for a variety of use cases.
This video focuses on the notifications, alerts, and approval requests using Slack for Bonterra Impact Management. The solutions covered in this webinar can also be deployed for Microsoft Teams.
Interested in deploying notification automations for Bonterra Impact Management? Contact us at sales@sidekicksolutionsllc.com to discuss next steps.
2. Two words about myself
Currently freelancing and working on my own ideas.
…one of which involves and WebSockets!
Bicycle Touring Amsterdam
3. Agenda
• What are WebSockets?
• WebSocket clients
• Relationship and comparison with HTTP
• Advantages and disadvantages
• WebSocket servers in Play!
• Simple examples & exercises
• Use case
4. What are WebSockets?
• Full-duplex channel between client and server.
• Persistent connection. Both parties can send data
at any time.
• Very simple API.
• Standardised by the IETF as RFC 6455 in 2011,
which has lead to broader adoption.
6. The API, Client-side
RECEPTION CALLBACKS
• onOpen
• onClosed
• onMessage(message)
• onError(error)
CONNECTION
• open
• close
SEND DATA
• send(message)
7. var myWebSocket = new WebSocket("ws://fabio.com/example");
// define callbacks
myWebSocket.onmessage = function(event) {
console.log("got data: " + event.data);
}
myWebSocket.onopen = function(event) {
console.log("Connection open ...");
};
myWebSocket.onclose = function(event) {
console.log("Connection closed.");
};
myWebSocket.onerror = function(event) {
console.log("Error!");
};
myWebSocket.send("Hello from Javascript!”); // send stuff
myWebSocket.close(); // close connection
JavaScript client example
8. WebSocketClient mWsClient = new WebSocketClient(URI.create(“ws://fabio.com/example”), new
Listener() {
@Override
public void onMessage(final String message) {
Log.d(TAG, “onMessage: ” + message);
}
@Override
public void onError(final Exception error) {
Log.e(TAG, "Error!", error);
}
@Override
public void onDisconnect(final int code, final String reason) {
Log.d(TAG, String.format("Disconnected! Code: %d Reason: %s", code, reason));
}
@Override
public void onConnect() {
Log.d(TAG, "onConnect");
}
}, mExtraHeaders);
mWsClient.connect();
mWsClient.send(“Hello from Android!”);
mWSClient.disconnect();
Android (Java) client example
9. Request URL:ws://echo.websocket.org/
Request Method:GET
Status Code:101 Web Socket Protocol Handshake
Connection:Upgrade
Host:echo.websocket.org
Sec-WebSocket-Version:13
Upgrade:websocket
Relationship with HTTP
• A websocket connection is initiated via a
standard HTTP GET request, where the client
asks for an ‘Upgrade’
• The response will be a 101 status, ‘Switching
protocol’
10. Why WebSockets?
• The ‘native’ web built around HTTP only relies on
client’s action. Only the client can request new content
by for instance opening a new page.
• A way to make things more dynamic is using intense
polling, which is bad for performance and traffic.
• The need to give impression of a ‘dynamic’ web was
solved using workarounds like Long-polling or
Streaming.
• It works but it’s complicated and it doesn’t solve the
big issue of the HTTP overhead!
11. WS vs HTTP: overhead
HTTP: up to 2000 bytes (2Kb)
WebSocket: 2 bytes
13. Downsides of WebSockets
• You need to build your own protocol, even for the
simplest thing! You cannot use any of the friendly
HTTP statuses, body etc. Lower level of abstraction.
• If your application doesn’t require a lot of dynamic
interaction, HTTP is much simpler to implement.
• Regular sockets vs WebSockets: plain TCP is even
faster, but very low level (difficult to access).
14. A few useful links
• https://tools.ietf.org/html/rfc6455 (official doc)
• http://www.html5rocks.com/en/tutorials/websockets/
basics/ (basic tutorial)
• http://www.websocket.org (the echo server folks)
• http://blog.arungupta.me/2014/02/rest-vs-websocket-
comparison-benchmarks/ (HTTP vs WebSocket
comparison)
• http://eng.42go.com/websockets-vs-regular-sockets/
15. WebSockets in Play!
Similar signature to a regular HTTP Action:
val echo = Action { request =>
Ok("Got request [" + request + "]")
}
def index = WebSocket.using[String] { request =>
val in = Iteratee.foreach[String](chunk => println(chunk))
val out = Enumerator("Hello!")
(in, out)
}
using[A](f: (RequestHeader) (Iteratee[A, _], Enumerator[A]))
WebSocket.using signature:
16. WebSockets in Play!
There is also an ‘async’ version which combines the
two channels asynchronously and returns a Future.
def index = WebSocket.async[String] { request =>
Future {
val in = Iteratee.foreach[String](chunk => println(chunk))
val out = Enumerator("Hello!")
(in, out)
}
}
async[A](f: (RequestHeader) Future[(Iteratee[A, _], Enumerator[A])])
WebSocket.async signature:
17. Iteratees and Enumerators
• Complex functional abstractions. Very powerful but
difficult to grasp.
• In the WebSocket domain, all you need to know is that
they represent the two channels where data flows
between client and server.
18. Iteratees & Enumerators
How To
• They both take a type:
• Play! Framework provides various utilities to create
them and use them together.
• Time for some concrete examples!
trait Iteratee[E, +A] extends AnyRef
trait Enumerator[E] extends AnyRef
19. Repositories
(ask Google for “ticofab github” or something like that)
• https://github.com/ticofab/simple-websocket-client
(test client)
• https://github.com/ticofab/simple-play-websocket-
server (test server)
20. WebSockets in Play!
Even though you can wrap the pair (Iteratee, Enumerator) into
an Actor, the framework also offers a way to manage a
WebSocket using actors out of the box. The signature of the
accept function is unusual: a function that returns a function
which takes an ActorRef and returns the Props of an actor!
acceptWithActor[A, B](f: (RequestHeader) (ActorRef) Props)
There is also a way to reject a Websocket connection:
tryAcceptWithActor[A, B](f: (RequestHeader) Future[Either[Result,
(ActorRef) Props]])
Return Left to reject or Right(WebsocketActor.Props) to accept.
21. def index = WebSocket.acceptWithActor[String, String] { request => out =>
WebsocketActor.props(out)
}
object MyWebSocketActor {
def props(out: ActorRef) = Props(new WebsocketActor(out))
}
class WebsocketActor(out: ActorRef) extends Actor {
def receive = {
case msg: String =>
out ! ("I received your message: " + msg)
}
}
WebSockets in Play!
22. Little exercise
1. Uses Actors to handle connections wrapping Iteratee and
Enumerators.
2. It echoes anything it receives, but closes the connection if it
receives a specific string of your choice.
3. Bonus: make the endpoint proxy the result of the API call to:
Create a new Play! app with a WebSocket endpoint.
http://api.openweathermap.org/data/2.5/weather?q=Amsterdam,nl
23. Two good articles
• Iteratees and Enumerators for human beings: http://
mandubian.com/2012/08/27/understanding-play2-
iteratees-for-normal-humans/
• WebSocket examples: http://blog.tksfz.org/
2012/10/12/websockets-echo-using-play-scala-
and-actors-part-i/