Slides from my talk at RubyConf India 2012. This is a case in point for a highly productive & scalable enterprise application development platform with JRuby on Rails.
When we started to architect an enterprise micro-blogging solution as part of the internal collaboration platform for a large customer (henceforth referred by dummy name 'CustCollab'), the next immediate question was “Which web application development framework to use?”. Simplicity, productivity, ability to deliver high quality of service (QoS), especially performance & scalability, & alignment with CustCollab's technology stack were our top criteria for framework selection. After considerable research on state-of-the-art, we zeroed in on 2 frameworks – 1) “Ruby on Rails” (RoR) for its super simplicity & productivity & 2) “Java Enterprise Edition” (JEE) for its obvious “enterprise” class, high QoS & greater alignment with CustCollab's technology stack. But we just couldn't rule out either one, since each framework had been proven to deliver qualities not so proven in the other framework. Naturally, we started dreaming of a framework which can deliver best of both worlds! And in reality, there lived such a framework – 'JRuby on Rails'!
In this talk I will focus more on our experience of how JRuby, & hence JRoR, has done a fantastic job of delivering best of RoR & JEE worlds to an enterprise application w.r.t multiple 'quality of service' attributes like scalability (parallel processing, Garbage Collection, compilation, caching, advanced database connection pooling etc.), productivity, extensibility, security (especially CSRF), session management, reusability, total cost of ownership (alignment with existing/preferred technology stack) etc.
With the help of the real world 'CustCollab Micro-blogging' case in point, this presentation demonstrates how the distant, isolated worlds of RoR & JEE can synergize with the help of the JRuby bridge to result in a highly productive & scalable enterprise application development platform.
I hope it encourages others to adapt JRuby, & hence Ruby, in the enterprise. After all, as promised by the JRuby dev. team, the JRuby improvisation is well capable of delivering the best of both Java & Ruby worlds, & hence deserves greater attention in the enterprise world!
Java Performance Fundamental 세미나 교재입니다. 5장은 Execution Engine에 대한 내용을 다루고 있습니다. Class파일에 저장되어 있는 Bytecode를 해석하는 방법을 JIT Compiler와 Hotspot Compiler의 동작과정을 통해 자세히 알아봅니다.
* Execution Engine
* IBM JIT Compiler
* Hotspot Compiler
Java Performance Fundamental 세미나 자료입니다. 6장은 Thread Synchronization를 다루고 있습니다. 여기서는 Java에서 Thread라는 것은 어떻게 관리되어 왔으며 동기화는 어떤 역할을 하는지를 설명합니다. 더 나아가 JVM의 버전이 올라가면서 추가된 Hotspot JVM의 Biased Lock이나 IBM JVM의 Lock Reservation에 대해서도 설명하고 있습니다.
* Java의 Thread
* Java Synchronization
* Hotspot JVM Synchronization
* IBM JVM Synchronization
En esta platica trate de transmitir mejores practicas que se deben tener en cuenta cuando se diseña una API, y como ruby on rails te podria ayudar a desarrollarla en muy poco tiempo
Java Performance Fundamental 세미나 교재입니다. 5장은 Execution Engine에 대한 내용을 다루고 있습니다. Class파일에 저장되어 있는 Bytecode를 해석하는 방법을 JIT Compiler와 Hotspot Compiler의 동작과정을 통해 자세히 알아봅니다.
* Execution Engine
* IBM JIT Compiler
* Hotspot Compiler
Java Performance Fundamental 세미나 자료입니다. 6장은 Thread Synchronization를 다루고 있습니다. 여기서는 Java에서 Thread라는 것은 어떻게 관리되어 왔으며 동기화는 어떤 역할을 하는지를 설명합니다. 더 나아가 JVM의 버전이 올라가면서 추가된 Hotspot JVM의 Biased Lock이나 IBM JVM의 Lock Reservation에 대해서도 설명하고 있습니다.
* Java의 Thread
* Java Synchronization
* Hotspot JVM Synchronization
* IBM JVM Synchronization
En esta platica trate de transmitir mejores practicas que se deben tener en cuenta cuando se diseña una API, y como ruby on rails te podria ayudar a desarrollarla en muy poco tiempo
Comparing JVM Web Frameworks - Devoxx 2010Matt Raible
Comparing JVM Web Frameworks Presentation from Devoxx 2010. Compares many different JVM-based web frameworks, ranks them based on 20 different criteria and compares the Pros, Cons and other stats of the top 5.
JRuby is Ruby for the JVM, right? But what does that really mean? What do you get out of the deal?
We'll explore what makes JRuby unique among Ruby implementations, and why the JVM is a Rubyist's dream come true. Using JRuby means you have the best GC, real threads, easy and scalable deployment, high performance, no-compile cross-platform libraries, and the best monitoring and profiling tools of any VM. And you get it all without leaving Ruby behind. If you're not using JRuby already, this talk will convince you to give it a try.
Here is the presentation I did at Trifork GeekNights, January 12+13.
The talk is about my journey into Erlang land, how we need to start thinking about threads and processes in a new way, and some aspects of the work I have done towards implementing Erlang on the JVM platform.
Follow-up discussion either at my blog: http://javalimit.com/ or at http://groups.google.com/group/erjang
Glass fish rubyconf-india-2010-Arun gupta ThoughtWorks
GlassFish is an open source and production-quality application server with full enterprise support from Sun Microsystems. In addition to traditional Java EE applications, it allows applications developed using different Ruby frameworks to be easily deployed as well. The choice of application frameworks is also available for Groovy/Grails and Python/Django apps and can be easily extended further.
This talk will demonstrate how GlassFish provides an extensible framework that allow applications created using different Ruby frameworks can be easily deployed. The attendees will learn the different deployment models available in GlassFish through live coding examples and several customer use cases of Rails deployments on GlassFish. The talk will show how Rails, Sinatra, Merb and any Rack-based framework can be easily deployed on GlassFish. It demonstrates how popular Rails applications can be easily deployed on GlassFish without any modification, and shows how GlassFish Gem can be used as an effective alternative to WEBrick, Mongrel, and other traditional deployment models.
It also explains the inner workings of GlassFish so that developers understand what’s happening under the hood. It will explain how standard Java monitoring technologies like JMX can be used to monitor/manage these applications.
The session also demonstrates how NetBeans provides a comprehensive IDE for developing, running, and debugging a Rails application directly on GlassFish – all without using any Java code.
Keynote I did at JAX2013 with the topic basically being "the JVM is over - enter the Polyglot Runtime". It is about the work that Oracle and the community is doing to facilitate multiple languages (non Java) on the Java Virtual Machine. This is both relevant for dynamic languages as well as "non dynamic" ones.
Comparing JVM Web Frameworks - Devoxx 2010Matt Raible
Comparing JVM Web Frameworks Presentation from Devoxx 2010. Compares many different JVM-based web frameworks, ranks them based on 20 different criteria and compares the Pros, Cons and other stats of the top 5.
JRuby is Ruby for the JVM, right? But what does that really mean? What do you get out of the deal?
We'll explore what makes JRuby unique among Ruby implementations, and why the JVM is a Rubyist's dream come true. Using JRuby means you have the best GC, real threads, easy and scalable deployment, high performance, no-compile cross-platform libraries, and the best monitoring and profiling tools of any VM. And you get it all without leaving Ruby behind. If you're not using JRuby already, this talk will convince you to give it a try.
Here is the presentation I did at Trifork GeekNights, January 12+13.
The talk is about my journey into Erlang land, how we need to start thinking about threads and processes in a new way, and some aspects of the work I have done towards implementing Erlang on the JVM platform.
Follow-up discussion either at my blog: http://javalimit.com/ or at http://groups.google.com/group/erjang
Glass fish rubyconf-india-2010-Arun gupta ThoughtWorks
GlassFish is an open source and production-quality application server with full enterprise support from Sun Microsystems. In addition to traditional Java EE applications, it allows applications developed using different Ruby frameworks to be easily deployed as well. The choice of application frameworks is also available for Groovy/Grails and Python/Django apps and can be easily extended further.
This talk will demonstrate how GlassFish provides an extensible framework that allow applications created using different Ruby frameworks can be easily deployed. The attendees will learn the different deployment models available in GlassFish through live coding examples and several customer use cases of Rails deployments on GlassFish. The talk will show how Rails, Sinatra, Merb and any Rack-based framework can be easily deployed on GlassFish. It demonstrates how popular Rails applications can be easily deployed on GlassFish without any modification, and shows how GlassFish Gem can be used as an effective alternative to WEBrick, Mongrel, and other traditional deployment models.
It also explains the inner workings of GlassFish so that developers understand what’s happening under the hood. It will explain how standard Java monitoring technologies like JMX can be used to monitor/manage these applications.
The session also demonstrates how NetBeans provides a comprehensive IDE for developing, running, and debugging a Rails application directly on GlassFish – all without using any Java code.
Keynote I did at JAX2013 with the topic basically being "the JVM is over - enter the Polyglot Runtime". It is about the work that Oracle and the community is doing to facilitate multiple languages (non Java) on the Java Virtual Machine. This is both relevant for dynamic languages as well as "non dynamic" ones.
Challenges in Maintaining a High Performance Search Engine Written in Javalucenerevolution
Presented by Simon Willnauer | Apache Lucene - See conference video - http://www.lucidimagination.com/devzone/events/conferences/lucene-revolution-2012
During the last decade Apache Lucene became the de-facto standard in open source search technology. Thousands of applications from Twitter Scale Webservices to Computers playing Jeopardy rely on Lucene, a rock-solid, scaleable and fast information-retrieval library entirely written in Java. Maintaining and improving such a popular software library reveals tough challenges in testing, API design, data-structures, concurrency and optimizations. This talk presents the most demanding technical challenges the Lucene Development Team has solved in the past. It covers a number of areas of software development including concurrency & parallelism, testing infrastructure, data-structures, algorithms, API designs with respect to Garbage Collection, and Memory efficiency and efficient resource utilization. This talk doesn’t require any Apache Lucene or information-retrieval background in general. Knowledge about the Java programming language will certainly be helpful while the problems and techniques presented in this talk aren’t Java specific.
Dynamic Languages & Web Frameworks in GlassFishIndicThreads
“Dynamic languages such as JRuby, Groovy, and Jython are increasingly playing an important role in the web these days. The associated frameworks such as Rails, Grails, and Django are gaining importance because of the agility provided by them.
The GlassFish project provides an easy-to-use and robust development and deployment platform for hosting these web applications. It also enables the various languages to leverage the investment in your existing Java Platform, Enterprise Edition (Java EE platform) infrastructure. This session gives an overview of various Dynamic Languages and associated Web frameworks that can be used on the GlassFish project.
It starts with a brief introduction to JRuby and details on how the GlassFish project provides a robust development and deployment platform for Rails, Merb, Sinatra and other similar applications without pain. As a basis for further discussion, this presentation shows the complete lifycycle for JRuby-on-Rails applications on GlassFish v2 and v3. It discusses the various development options provided by GlassFish v3, demonstrates how popular Rails applications can be easily deployed on GlassFish without any modification, and shows how v3 Gem can be used as an effective alternative to WEBrick and Mongrel. It also demonstrates debugging of Rails applications using NetBeans IDE. For enterprise users, it shows how JMX and other mechanisms can be used to monitor Rails applications.
It also talks in detail about the Groovy/Grails and Python/Django development and deployment models in context of GlassFish v3. By following the simple deployment steps the presentation shows, developers will be able to deploy their existing web applications on the GlassFish project.The session also describes the known limitations and workarounds for each of them.
The talk will show a working sample created in different frameworks and deployed on GlassFish v3. The demo will show how different features of the underlying GlassFish runtime are easily accessible to the frameworks running on top of it.”
This talk provides a number of step-by-step examples that illustrate different ways in which Rails applications can interact effectively with third-party Java libraries. The presentation shows how developers can leverage JRuby to augment Rails applications with the mature, third-party libraries that are widely available in the Java world.
Similar to JRuby on Rails - RoR's Simplicity Meets Java's Class (a case in point) (20)
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.
Unlocking Productivity: Leveraging the Potential of Copilot in Microsoft 365, a presentation by Christoforos Vlachos, Senior Solutions Manager – Modern Workplace, Uni Systems
UiPath Test Automation using UiPath Test Suite series, part 6DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 6. In this session, we will cover Test Automation with generative AI and Open AI.
UiPath Test Automation with generative AI and Open AI webinar offers an in-depth exploration of leveraging cutting-edge technologies for test automation within the UiPath platform. Attendees will delve into the integration of generative AI, a test automation solution, with Open AI advanced natural language processing capabilities.
Throughout the session, participants will discover how this synergy empowers testers to automate repetitive tasks, enhance testing accuracy, and expedite the software testing life cycle. Topics covered include the seamless integration process, practical use cases, and the benefits of harnessing AI-driven automation for UiPath testing initiatives. By attending this webinar, testers, and automation professionals can gain valuable insights into harnessing the power of AI to optimize their test automation workflows within the UiPath ecosystem, ultimately driving efficiency and quality in software development processes.
What will you get from this session?
1. Insights into integrating generative AI.
2. Understanding how this integration enhances test automation within the UiPath platform
3. Practical demonstrations
4. Exploration of real-world use cases illustrating the benefits of AI-driven test automation for UiPath
Topics covered:
What is generative AI
Test Automation with generative AI and Open AI.
UiPath integration with generative AI
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Pushing the limits of ePRTC: 100ns holdover for 100 daysAdtran
At WSTS 2024, Alon Stern explored the topic of parametric holdover and explained how recent research findings can be implemented in real-world PNT networks to achieve 100 nanoseconds of accuracy for up to 100 days.
Sudheer Mechineni, Head of Application Frameworks, Standard Chartered Bank
Discover how Standard Chartered Bank harnessed the power of Neo4j to transform complex data access challenges into a dynamic, scalable graph database solution. This keynote will cover their journey from initial adoption to deploying a fully automated, enterprise-grade causal cluster, highlighting key strategies for modelling organisational changes and ensuring robust disaster recovery. Learn how these innovations have not only enhanced Standard Chartered Bank’s data infrastructure but also positioned them as pioneers in the banking sector’s adoption of graph technology.
GraphRAG is All You need? LLM & Knowledge GraphGuy Korland
Guy Korland, CEO and Co-founder of FalkorDB, will review two articles on the integration of language models with knowledge graphs.
1. Unifying Large Language Models and Knowledge Graphs: A Roadmap.
https://arxiv.org/abs/2306.08302
2. Microsoft Research's GraphRAG paper and a review paper on various uses of knowledge graphs:
https://www.microsoft.com/en-us/research/blog/graphrag-unlocking-llm-discovery-on-narrative-private-data/
Climate Impact of Software Testing at Nordic Testing DaysKari Kakkonen
My slides at Nordic Testing Days 6.6.2024
Climate impact / sustainability of software testing discussed on the talk. ICT and testing must carry their part of global responsibility to help with the climat warming. We can minimize the carbon footprint but we can also have a carbon handprint, a positive impact on the climate. Quality characteristics can be added with sustainability, and then measured continuously. Test environments can be used less, and in smaller scale and on demand. Test techniques can be used in optimizing or minimizing number of tests. Test automation can be used to speed up testing.
In the rapidly evolving landscape of technologies, XML continues to play a vital role in structuring, storing, and transporting data across diverse systems. The recent advancements in artificial intelligence (AI) present new methodologies for enhancing XML development workflows, introducing efficiency, automation, and intelligent capabilities. This presentation will outline the scope and perspective of utilizing AI in XML development. The potential benefits and the possible pitfalls will be highlighted, providing a balanced view of the subject.
We will explore the capabilities of AI in understanding XML markup languages and autonomously creating structured XML content. Additionally, we will examine the capacity of AI to enrich plain text with appropriate XML markup. Practical examples and methodological guidelines will be provided to elucidate how AI can be effectively prompted to interpret and generate accurate XML markup.
Further emphasis will be placed on the role of AI in developing XSLT, or schemas such as XSD and Schematron. We will address the techniques and strategies adopted to create prompts for generating code, explaining code, or refactoring the code, and the results achieved.
The discussion will extend to how AI can be used to transform XML content. In particular, the focus will be on the use of AI XPath extension functions in XSLT, Schematron, Schematron Quick Fixes, or for XML content refactoring.
The presentation aims to deliver a comprehensive overview of AI usage in XML development, providing attendees with the necessary knowledge to make informed decisions. Whether you’re at the early stages of adopting AI or considering integrating it in advanced XML development, this presentation will cover all levels of expertise.
By highlighting the potential advantages and challenges of integrating AI with XML development tools and languages, the presentation seeks to inspire thoughtful conversation around the future of XML development. We’ll not only delve into the technical aspects of AI-powered XML development but also discuss practical implications and possible future directions.
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Albert Hoitingh
In this session I delve into the encryption technology used in Microsoft 365 and Microsoft Purview. Including the concepts of Customer Key and Double Key Encryption.
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!SOFTTECHHUB
As the digital landscape continually evolves, operating systems play a critical role in shaping user experiences and productivity. The launch of Nitrux Linux 3.5.0 marks a significant milestone, offering a robust alternative to traditional systems such as Windows 11. This article delves into the essence of Nitrux Linux 3.5.0, exploring its unique features, advantages, and how it stands as a compelling choice for both casual users and tech enthusiasts.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
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.
GridMate - End to end testing is a critical piece to ensure quality and avoid...ThomasParaiso2
End to end testing is a critical piece to ensure quality and avoid regressions. In this session, we share our journey building an E2E testing pipeline for GridMate components (LWC and Aura) using Cypress, JSForce, FakerJS…
2. Once upon a time…
powerful Java on their beautiful Ruby
way to win
the plot to unfold Enterprize battles to be won
when Java, Ruby tried to win battles on their own…
there were happy times… …& some down times…
…….
then comes the time… Java falls in love with Ruby…
(a little rhyming love song…I promise)
now wait for the climax…
No background music Fast & dramatic No popcorn break 2
3. The script writer & confessions…
x I’m neither too deep into Ruby nor have I run too far onto Rails
so far
But I love its Simplicity
I think & code in usual Java & JEE
And I love its Class
I architect & code solutions at TCS
Thrilled to talk about JRuby when one
of it’s creators & a JRuby hero is here!
(Unbelievable!)
x I tried, but couldn’t further shorten title of this story…
3
4. The plot
Micro-blogging @CustCollab
API
Search Public/private/
corporate/auto
Profiles follow communities
Smart
Follow, unfollow,
phones Micro-blogging
invites etc.
Pretty std notifications
deply arch with Usage
DMZ expected to Timelines,
over a period threads, hashtags
200,000+
total users & Notifications
from other apps
4
5. The actors supporting Java & Ruby
/*
* @author #jruby.org
*/
public class JRuby implements Ruby {
/*
* This implementation of Ruby programming
* language brings class to Ruby/Rails
* & simplicity to Java/JEE.
*/
…
} 5
6. “Ruby on Rails® is an open-source web framework that's
optimized for programmer's happiness and sustainable
productivity. It lets you write beautiful code by favoring
convention over configuration.” - rubyonrails.org
6
“On a rail track” by Ahmad Kavousian (flickr)
7. Is it
the
Silver
Bullet?
7
Silver bullet (flickr)
14. Perf. &
Scale
Threading & Parallel Processing
[Concurrency is a Myth in Ruby by Ilya Grigorik]
JRuby
Thanks to Ilya Grigorik, Evan Phoenix (Ruby, Concurrency, and You) & Sasada Koichi (YARV)
for demystifying the concurrency & parallelism in Ruby implementations… 14
15. Perf. &
Scale
Memory Management
JRuby:
Ruby 1.8 (MRI): More init mem. util (-), JVM GC
Stop the world, mark & sweep optimized to death over the
years. E.g.Min. GC pauses using
Ruby 1.9.3 (YARV): Lazy sweep multi- cores, or….or….(++)
garbage truck (flickr) 15
16. Perf. &
Scale
Code Execution Mechanism
Ruby 1.8
Ruby 1.9 JRuby
- Charles Nutter, Learning More About JRuby 16
18. Perf. &
Scale
Caching
Data store ~ bottleneck
Caching = Don’t hit bottleneck. Closer is faster.
JRoR
JEE RoR
@CustCollab
Session, application scope: Memcached: Simple, fast JEE
• No i/o, protocol for in-memory +1 breakpoint, cache
• Auto expiry +1 component Options++
• App. server’s high availability Cache’s HA to
(HA) = cache’s HA be architected
Scale out options: Ehcache, … Page, view,
Page, view, fragment scope etc. fragment
scope etc.
18
20. Perf. &
Scale
Asynchronous Messaging
Can’t remove bottlenecks?
Decouple them…
JRoR
JEE RoR
@CustCollab
JMS: Good ones like ‘delayed job’ JMS planned
Evolving. As high QoS as as message
• Stood the test of
JVM impls? Twitter FUD. queue
time…& money in
large financial No open std specs as such?
institutions! Product lock-in?
• High Quality of
Service (QoS)
20
21. Perf. &
Scale
JRuby+Java 7+new compiler: Future worth a mention
+
New Compiler: “Give the JVM better byte code.” Wow!
+
“There will always be cases where we win or where we lose. Java 7's features
have made the win cases more frequent and more impressive. In general
if we are slower we consider it a bug and would like bug reports.”
[Sources: Charles Nutter, Learning More About JRuby & red/black tree benchmark ]
21
24. Productivity
Write Less, Do More
Every manager’s dream! Every programmer’s happiness!
Uhh? “programmer’s happiness”? = RoR
JEE RoR JRoR @CustCollab
You being smart isn’t Quick, feature rich
enough …need smarter IDE Genetically coded releases
for the Next Gen
Configuration is the web... Happy happy we
Convention (seen web.xml shall be! When we
of a large app?) learn our JRuby!
AJAX
24
29. Security +
Productivity
SAML Single Sign-On
Don’t re-invent. Reuse.
JEE RoR JRoR @CustCollab
Tested, ready to Develop it or wait till Reused the ready to
use Java someone else does. Then use! That was fast!
OpenSAML customize it, test it.
custom
components in
CustCollab
29
30. Security +
Optimization
Session Management
Key to quality of service for good guys. Master key for bad guys.
Secure to death.
JEE RoR JRoR @CustCollab
In-memory w/o Cookie: 4 KB limit, not Secure, high quality
i/o, w/ auto- b/w friendly, of service session
invalidation vulnerable in principle mgmt. = JEE
Inherits app. server’s AR: db queries + session store
high availability (HA) cleanup daemon =
architecture (perf. + maint.)++ Vary session
timeout based on
Session mgmt. Memcached: +1 intranet or internet
API: Set timeout breakpoint + need to using JEE session
based on IP range design HA + cleanup mgmt. APIs
w/o persistent cookie
30
31. Security +
Productivity
Protection Against Security Threats
Built-in is better.
JEE RoR JRoR @CustCollab
Protection against XSS, XSS, SQL injection, Micro-blogging
SQL injection etc. prepared stmts, use case most
CSRF protection? [JSF 2.2 CSRF… vulnerable to XSS,
(WIP): strong, Servlet Easy to use plug-ins, SQL injection,
spec 3.1 (WIP?): yes?] gems for others. E.g. CSRF. RoR
ReCAPTCHA simplifies
protection.
“protect_from_forgery” + “verify :method =>…”
31
39. Seeing is Believing. Can it walk the talk?
JRuby 1.5 (Ruby 1.8.7), Rails 2.3.5, deployed as a WAR file
on Tomcat 6 with PostgreSQL 8.4 database.
Target load (~50% of prod. estimate): 1500
concurrent/active users in load test environment
Response time target for transaction: 90th percentile
should be < 2 to 3 seconds.
Peak load steady state of 30 minutes.
39
40. 2 application servers: Each w/ RHEL, virtualized, Intel®
Xeon® , 2 vCPUs, 3 GB RAM, 2 GB JVM heap size.
Test data volume: 270,000+ micro-blogging channels,
480,000+ micro-blogs.
JRuby min and max runtimes = 1.
Thread-safe code + “config.threadsafe!” in Rails.
Warm-up database connection pool to around 150.
On your mark…..get set…..
40
42. & the result is…
90th percentile of resp. time < 1.2 sec (!!), 100% passing
Throughput achieved:
o ~127,800 primary requests in steady state (30 min) -
(excludes secondary req like images, css, js)
o ~ 71 primary requests/sec in steady state
CPU utilizations
o Each application server <= 60%
o Database server <= 20%
RAM usage before test ~ RAM usage during & after test
JVM heap space utilization ~ 85% in steady state (peak)
42
43. Quick facts…
Live in production.
Being used via web browser as well as from
other apps & smart phones via micro-blogging
API.
Personal channels: 200,000+
Communities (active than personal): 5000+
Micro-blogs till Feb 2012: 224,000+
43
47. buildFastScalableApp() {
try {
do {
(estimate + architect + design + program).to_scale;
assert_doesnt_scale? : don’t throw new hw($$$) ;
self.be_patient();
everything.tune();
} while (!scale && !tunedTheHellOutOfEverything);
}//end try
finally {
if !scale? {
throw new hw($$$) || throw new (arch && design) ||
throw new (technology) || self.resign();
}//end nightmare
else {
beer.overflow(); RubyConfIndia.talk()?;
}//start celebrations
}//end finally
}//end job 47
48. && while (that’s true)…
{
Classy runtimes like JVM ability to
scale …rest is left up to the developer’s
abilities & ENV[“constraints”]…
}
48
49. &&
{
Simple languages like Ruby &
Convention based frameworks like Rails
productivity (more time to work on
scalability :)...rest is left up to the
developer’s abilities &
ENV[“constraints”]…
}
49
50. &&
{
Classy, Simple, Convention based
marriages like JRuby on Rails ability
to scale && productivity …rest is left
up to you to arrange such a marriage
that’s fast & will last in your
ENV[“constraints”]…
}
50
53. ‘Java + Ruby’ works just well…
Best of both is glued by the JRuby gel…
Its fast… & will scale…
Thanks JRuby, your promise didn’t fail!
- Darshan
53
54. A note of thanks to the backstage
o My colleague Yashasree Barve for letting me know abt
RubyConfIndia CFP.
o RubyConfIndia for this opportunity!
o Manasee, my worried wife, for being cool with JRuby,
Rails, MS ppt & me over all the weekends those followed
my talk’s selection (she’s worried if I would ever finish
preparing these slides & present them well…)
54
55. Artwork credits
oThe creative & open minds on flickr:
o Mr. Ahmad Kavousian for officially permitting me to use
his beautiful art work - /photos/kavous/2473202527/
o Silver bullet - /photos/eschipul/4160817135/
o People - /photos/kheelcenter/5279081507/
o Twitter bird - /photos/travelinlibrarian/4329755033/
o Garbage truck - /photos/jeffyoungstrom/3602384021/
o Rain drops - /photos/photographygal123/4959951870/
o Running along train tracks -
/photos/seandreilinger/3167848378/
55
56. …& they lived happily ever after…
56
“On a rail track” by Ahmad Kavousian (flickr)