The document provides an overview of deploying Ruby on Rails applications. It discusses the history of different web servers and technologies used for Rails deployment such as CGI, Apache, Lighttpd. It introduces Mongrel as a faster alternative and discusses how it works with Rails. It then covers using Nginx as a front-end proxy for Mongrel, noting its high performance. It also discusses clustering Mongrel processes and using virtualization with Xen to deploy Rails in a modularized way across multiple servers. Overall, the document offers advice and best practices on optimizing Rails performance and scalability.
Slides of erlang factory 2011 London talk "Designing for performance with erlang"
Video of this presentation available at http://vimeo.com/26715793#at=0
Erlang factory SF 2011 "Erlang and the big switch in social games"Paolo Negri
talk given at erlang factory 2011 about using erlang to build social games backends
Watch the video of this presentation http://vimeo.com/22144057#at=0
Slides of erlang factory 2011 London talk "Designing for performance with erlang"
Video of this presentation available at http://vimeo.com/26715793#at=0
Erlang factory SF 2011 "Erlang and the big switch in social games"Paolo Negri
talk given at erlang factory 2011 about using erlang to build social games backends
Watch the video of this presentation http://vimeo.com/22144057#at=0
A high level overview of MeteorJS, Amazon Web Services, and how to scale MeteorJS on Amazon's cloud to handle tends of thousands of concurrent websocket connections.
Covers how we built a set of high-speed reactive microservices and maximized cloud/hardware costs while meeting objectives in resilience and scalability. Talks about Akka, Kafka, QBit, in-memory computing, from a practitioners point of view. Based on the talks delivered by Geoff Chandler, Jason Daniel, and Rick Hightower at JavaOne 2016 and SF Fintech at Scale 2017, but updated.
Reactive Micro Services with Java seminarGal Marder
Abstract –
Micro services is the current architectural trend. In this seminar, we'll go over the concepts behind a good micro-service implementation and see how to implement it with available Java frameworks.
Target Audience
Java developers, team leaders, project managers.
Prerequisites
Java knowledge
Contents:
Overview of Micro-service architecture principles.
- Technical stacks:
- The Spring Stack (Spring Boot & Cloud)
- Lagom
- Akka and Play
- Vertx
- Complementaries
- Discovery
- Configuration
- Monitoring
Go Reactive: Event-Driven, Scalable, Resilient & Responsive SystemsJonas Bonér
The demands and expectations for applications have changed dramatically in recent years. Applications today are deployed on a wide range of infrastructure; from mobile devices up to thousands of nodes running in the cloud—all powered by multi-core processors. They need to be rich and collaborative, have a real-time feel with millisecond response time and should never stop running. Additionally, modern applications are a mashup of external services that need to be consumed and composed to provide the features at hand.
We are seeing a new type of applications emerging to address these new challenges—these are being called Reactive Applications. In this talk we will discuss four key traits of Reactive; Event-Driven, Scalable, Resilient and Responsive—how they impact application design, how they interact, their supporting technologies and techniques, how to think when designing and building them—all to make it easier for you and your team to Go Reactive.
NATS - A new nervous system for distributed cloud platformsDerek Collison
NATS is an open-source, high-performance, lightweight cloud messaging system.
NATS was created by Derek Collison, Founder/CEO of Apcera who has spent 20+ years designing, building, and using publish-subscribe messaging systems. Unlike traditional enterprise messaging systems, NATS has an always-on dial tone that does whatever it takes to remain available. This forms a great base for building modern, reliable, and scalable cloud and distributed systems.
Event Driven Architecture with Apache Camelprajods
This presentation describes Event Driven Architecture(EDA) support in Camel, and scalability features like SEDA and Akka support in Camel.It starts with an overview of Camel and introduces its simple syntax
A high level overview of MeteorJS, Amazon Web Services, and how to scale MeteorJS on Amazon's cloud to handle tends of thousands of concurrent websocket connections.
Covers how we built a set of high-speed reactive microservices and maximized cloud/hardware costs while meeting objectives in resilience and scalability. Talks about Akka, Kafka, QBit, in-memory computing, from a practitioners point of view. Based on the talks delivered by Geoff Chandler, Jason Daniel, and Rick Hightower at JavaOne 2016 and SF Fintech at Scale 2017, but updated.
Reactive Micro Services with Java seminarGal Marder
Abstract –
Micro services is the current architectural trend. In this seminar, we'll go over the concepts behind a good micro-service implementation and see how to implement it with available Java frameworks.
Target Audience
Java developers, team leaders, project managers.
Prerequisites
Java knowledge
Contents:
Overview of Micro-service architecture principles.
- Technical stacks:
- The Spring Stack (Spring Boot & Cloud)
- Lagom
- Akka and Play
- Vertx
- Complementaries
- Discovery
- Configuration
- Monitoring
Go Reactive: Event-Driven, Scalable, Resilient & Responsive SystemsJonas Bonér
The demands and expectations for applications have changed dramatically in recent years. Applications today are deployed on a wide range of infrastructure; from mobile devices up to thousands of nodes running in the cloud—all powered by multi-core processors. They need to be rich and collaborative, have a real-time feel with millisecond response time and should never stop running. Additionally, modern applications are a mashup of external services that need to be consumed and composed to provide the features at hand.
We are seeing a new type of applications emerging to address these new challenges—these are being called Reactive Applications. In this talk we will discuss four key traits of Reactive; Event-Driven, Scalable, Resilient and Responsive—how they impact application design, how they interact, their supporting technologies and techniques, how to think when designing and building them—all to make it easier for you and your team to Go Reactive.
NATS - A new nervous system for distributed cloud platformsDerek Collison
NATS is an open-source, high-performance, lightweight cloud messaging system.
NATS was created by Derek Collison, Founder/CEO of Apcera who has spent 20+ years designing, building, and using publish-subscribe messaging systems. Unlike traditional enterprise messaging systems, NATS has an always-on dial tone that does whatever it takes to remain available. This forms a great base for building modern, reliable, and scalable cloud and distributed systems.
Event Driven Architecture with Apache Camelprajods
This presentation describes Event Driven Architecture(EDA) support in Camel, and scalability features like SEDA and Akka support in Camel.It starts with an overview of Camel and introduces its simple syntax
Full stack development using javascript what and why - ajay chandravadiyaajayrcgmail
This presentation is about my first encounter with world of fullstack development using html, css, javascript, jsp, servlet, struts, hibernate, hql, spring, sql, stored procs and lot of other pains and second encounter with fullstack development using html, css and javascript.
I hope you got the message ;)
Messaging, interoperability and log aggregation - a new frameworkTomas Doran
In this talk, I will talk about why log files are horrible, logging log lines, and more structured performance metrics from large scale production applications as well as building reliable, scaleable and flexible large scale software systems in multiple languages.
Why (almost) all log formats are horrible will be explained, and why JSON is a good solution for logging will be discussed, along with a number of message queuing, middleware and network transport technologies, including STOMP, AMQP and ZeroMQ.
The Message::Passing framework will be introduced, along with the logstash.net project which the perl code is interoperable with. These are pluggable frameworks in ruby/java/jruby and perl with pre-written sets of inputs, filters and outputs for many many different systems, message formats and transports.
They were initially designed to be aggregators and filters of data for logging. However they are flexible enough to be used as part of your messaging middleware, or even as a replacement for centralised message queuing systems.
You can have your cake and eat it too - an architecture which is flexible, extensible, scaleable and distributed. Build discrete, loosely coupled components which just pass messages to each other easily.
Integrate and interoperate with your existing code and code bases easily, consume from or publish to any existing message queue, logging or performance metrics system you have installed.
Simple examples using common input and output classes will be demonstrated using the framework, as will easily adding your own custom filters. A number of common messaging middleware patterns will be shown to be trivial to implement.
Some higher level use-cases will also be explored, demonstrating log indexing in ElasticSearch and how to build a responsive platform API using webhooks.
Interoperability is also an important goal for messaging middleware. The logstash.net project will be highlighted and we'll discuss crossing the single language barrier, allowing us to have full integration between java, ruby and perl components, and to easily write bindings into libraries we want to reuse in any of those languages.
Talk given at ClueCon 2016 that discusses FreeSWITCH and its place in a microservices architecture. Covers a specific deployment case using Docker and Adhearsion, along with certain features that make FreeSWITCH a model use-case for such a technology stack.
The evolution of micro services architecture. Mainframe, Midrange, Client Server, SOA. Best practices of microservices. Load balancing, BigData, design patterns. When and why to use microservices.
Two popular tools for doing Machine Learning on top of JVM ecosystem is H2O and SparkML. This presentation compares these two tools as Machine Learning libraries (Didn't consider Spark's Data Munjing perspective). This work was done during June of 2018.
OpenStack Days East -- MySQL Options in OpenStackMatt Lord
In most production OpenStack installations, you want the backing metadata store to be highly available. For this, the de facto standard has become MySQL+Galera. In order to help you meet this basic use case even better, I will introduce you to the brand new native MySQL HA solution called MySQL Group Replication. This allows you to easily go from a single instance of MySQL to a MySQL service that's natively distributed and highly available, while eliminating the need for any third party library and implementations.
If you have an extremely large OpenStack installation in production, then you are likely to eventually run into write scaling issues and the metadata store itself can become a bottleneck. For this use case, MySQL NDB Cluster can allow you to linearly scale the metadata store as your needs grow. I will introduce you to the core features of MySQL NDB Cluster--which include in-memory OLTP, transparent sharding, and support for active/active multi-datacenter clusters--that will allow you to meet even the most demanding of use cases with ease.
Sanger, upcoming Openstack for Bio-informaticiansPeter Clapham
Delivery of a new Bio-informatics infrastructure at the Wellcome Trust Sanger Center. We include how to programatically create, manage and provide providence for images used both at Sanger and elsewhere using open source tools and continuous integration.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
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
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
2. Who am I?
• Ezra Zygmuntowicz
• Rubyist for 4 years
• Engine Yard Founder and Architect
• Blog: http://brainspl.at
3. Deploying Rails
• Details have changed rapidly over the years
• Many different webservers have come and
gone
• Basics remain the same
4. Full Stack Request/Response Life-Cycle
• Request comes into gateway
server
• Rewrite rules are evaluated and
request gets served directly if it’s
a static asset
• Dynamic requests are proxied to
one Mongrel in the Mongrel
Cluster
• Mongrel dispatches request
through Rails and returns
response to client
9. Mongrel is an HTTP Server
Library written by Zed Shaw
• Fast HTTP Parser written in Ragel + C
• Fast URI Classifier written in C
• Stackable Request Handlers
• Flexible Configuration
• Secure and RFC Compliant HTTP Parser
11. Why is Mongrel better?
• HTTP is a well known and well tooled
protocol
• Mongrel is way easier to setup and use
• Transparent wire protocol
12. But Rails isn’t Thread Safe!
• Giant Mutex Lock around Rails Dispatch
• Only one request served at a time by one
mongrel
• Use mongrel_cluster to scale with multiple
processes
13. Rails Internal Request/Response Life-Cycle
• Mongrel Locks Mutex
• Rails Dispatcher is invoked with
request/response objects
• Routing is invoked and returns
the proper Controller object or
404 if no route found
• Filter chain is invoked
• Controller’s Action is called,
manipulates Models
• View is rendered and any after
filters are called
• Mongrel Unlocks Mutex
• Final response or error page
returned to client
14. New dog seeking old
tricks
• Wide array of options for HTTP tools to front mongrel
clusters
• Pen, Pound, Balance, Haproxy ( No static file serving, just
proxies)
• Lightspeed can serve static files and proxy to mongrel
• Apache2.2.x/mod_proxy_balancer can do the same
15. On the prowl for the
perfect stack
• Pen(no ssl support, no connection rate limiting)
• Pound(Falls down under high load, no connection rate limiting)
• Haproxy(supports conn rate limits, very high perf, no static files
so more moving parts in a full stack)
• Lightspeed(free version is crippled)
• Apache2.2.x(Does work but.. bloat, bloat, bloat...)
16. Nginx:
From Russia, with Love
• Seriously bent on performance
• Super small resource footprint
• Stands up under the heaviest loads without leaking memory
• Killer rewrite and proxy modules
• Approachable author and growing community
17. Nginx + Mongrel
• This is *the* stack to be on
• Only keep apache around for mod_dav_svn
• Flexible nginx.conf syntax allows for serving static files and
rails caches and proxying dynamic requests to mongrel
• Fast, fast, fast
• Did I say it’s fast yet?
18. A few gotchas
• Nginx buffers file uploads, so no mongrel_upload_progress. This
will be addressed soon
• No connection rate limiting for proxy module yet, this too shall
pass
19. A bright future for nginx
• mod_rewrite is going away
• To be replaced with http_script_module
• This will embed the NekoVM(http://nekovm.org/) directly in
nginx so customizing behavior for rewriting and proxying will
become infinitley flexible
22. Swiftiply: Evented Mongrel
• Hot patch to Mongrel
• Removes Ruby’s Thread’s and Socket handling from Mongrel
Core
• Replace with EventMachine event loop
• Mongrel becomes Single threaded, event driven
• Noticable Speed and IO throughtput increase
• Stands up much better under higher concurrent load without
starting to slow down or leak memory
23. But how does a single threaded
event driven mongrel outperform
a multithreaded mongrel?
• Ruby’s green threads have a lot of overhead in context switching
and have to copy a lot of state context for each thread
• Mutual exclusion locks are expensive
• One process can only do so much IO
• Event driven means running in a tight loop and firing callbacks in
response to network ‘events’
• Since there is no context switching between threads, a single
process has less overhead to deal with which allows for higher
throughput and faster networking IO
24. Mongrel VS Evented Mongrel
in a Hello World dogfight
Mongrel:
1 concurrent
user
Evented
Mongrel:
1 concurrent
user
26. Swiftiply Proxy
• Event driven proxy, small memory footprint(7-10Mb)
• Faster then Haproxy
• Did I mention Fast?
27. How it differs from a
normal proxy
Standard proxy must know about the With swiftiply, the backends connect to the proxy. So
ports of all backends. Usually requires all mongrels get started on the same port and then
restart to add more backends they open a persistent connection to the proxy
28. This means you can start and stop as many
mongrels as you want and they get auto
configured in the proxy!
This opens the door for scaling the number of mongrels
automatically in response to increased load on the fly!
30. Monolithic Linux VS
Modularized Linux
• Old way of thinking is dedicated boxes running all services in
one big hodgepodge on one kernel
• New school is sharply targeted virtualized linux with each VM
running a single tier or service
31. We all strive for code
modularization right?
• Why not do the same thing with our servers?
• Each VM runs one or two related services
• Simplifies deployment and scaling
• Even if you only have one box you absolutely should run
Xen on it from the start
34. Old School
• Get another box and move mysql on there
• Get another box to run some of the other services
• Lots of setup required, downtime to migrate
• Complex Linux installs with many services running are harder
to debug when performance problems happen
• This *can* scale but is way less flexible
35. New School
• Add another box with Xen installed
• Pick a few services that need more resources and migrate
them *live* to the other machine
• Each VM runs one thing and runs it well
• Easy to target performance problems
• Scales much better
36. Advanced Clustering
• Virtualized compute nodes that boot Xen dom0 off of USB
thumb drives
• SAN storage for all Xen domU(VPS’s)
• Red Hat Clustering Suite for fencing and cluster quorems
• GFS for 100% posix compliant clustered filesystem(no shitty
NFS)
• Hardware load balancers or dedicated boxes running Ultra
Monkey or just straight LVS
37. Fabric of Compute and
Storage
• When a compute node fails just swap it out for a new one and
plug in the thumbdrive and you’re back in business
• Move hot VM’s to less loaded nodes easily as they are not tied
to a single machine
• Deploy your app code to one node and then bounce the
mongrels on all nodes with a clustered filesystem like GFS
• Fragment and page caching consistency across all nodes
instantly
• Scale from one or 2 VM’s to as many as traffic requires *and*
back down again once traffic subsides.
38. RAM RAM RAM
• Most Rails apps are RAM bound way before they are CPU
bound
• Average mongrel size on 64bit EngineYard is 70-120Mb *per*
mongrel. Slightly less on 32 bit systems
• Rmagick and :include the worst culprits
• 95% of Rails apps will leak memory at one point or another
39. Rails eats Database
resources for breakfast
• Majority of app in the wild have *no* indexes in their
databases
• Learn when and where to apply indexes, it will save your
ass
• ActiveRecord insulates developers from SQL to the point
of massive ineficiencies. Look at your logs and see what
SQL is being generated. Do not fear the SQL and don’t
think you can get away without some denormalization and
custom SQL if you plan on your app having a chance of
scaling
40. Other tips & tricks
• *Don’t* use filesystem sessions, AR or SQLSession or
memcached if you don’t need persistance
• script/runner is massively ineficient. Try as hard as possible
to not load all of rails in your background processes. Use
the raw Mysql library and plain ruby if you can and your
servers will thank you for it
• *Do not* use script runner to process incoming email.
Run a daemon in a loop and poll a mail server with net/
pop2 or net/imap. Forking a whole rails process for each
incoming email will never work in a production
environment period
41. Rails is great for the
80/20 rule
• But you are on your own when you need the last 20%
• Learn how to write custom mongrel handlers for perf critical
sections of your app
• When is optimization not premature?
• Ruby is plenty fast, it’s rails that tends to be on the slow side
• Cache, cache, cache. It doesnt get much faster then service
cached static html files
42. Parting Thought
• Don’t take what I or anyone else says about this stuff as
gospel
• Test it and benchmark it for yourself to be sure
• Trust but verify and you will stay in good shape