This presentation is based on a blog post I made:
http://eyalgo.com/2014/02/01/the-single-responsibility-principle/
More details are in that blog post.
I had a presentation at work with these slides.
This presentation is based on a blog post I made:
http://eyalgo.com/2014/02/01/the-single-responsibility-principle/
More details are in that blog post.
I had a presentation at work with these slides.
Slides from a talk about unit tests in Node.js. The talk was held as a part of an internal Node.js course in ironSource's offices in Tel-Aviv. On Wednesday, September 14th, 2016
All 3 Clean Code presentations provide great value by themselves, but taken together are designed to offer a holistic approach to successful software creation. This first session creates the foundation for the 2nd and 3rd Clean Code presentation on Dependency Injection, as it explains expected base knowledge. Why writing Clean Code makes us more efficient Over the lifetime of a product, maintaining the product is actually one - if not the most - expensive area(s) of the overall product costs.
We will dive into the basics of Inversion of Control (IOC) and Dependency Injection (DI) to review different ways of achieving decoupling, using and exploring both: Best Practices, Design and Anti Patterns. This presentation requires knowledge and understanding of basics like DRY, SoC, SRP, SOLID etc. which are building the base for decoupled architecture. However, we will start at the basics of DI and will work towards intermediate and advanced scenarios depending on the participating group.
This presentation is based on C# and Visual Studio 2013. However, the demonstrated patterns and practice can be applied to every other programming language too.
Note: Moving forwards this presentation will be updated with the latest version of the slides for the last event I did the presentation instead of creating new separate slide decks here on SlideShare.
Presentation dates and locations:
2015-10-03 Silicon Valley Code Camp, San Jose, CA
2015-06-27 SoCal Code Camp - San Diego, CA
2015-06-25 Bay.NET South Bay, Mountain View, CA
2014-11-14 SoCal Code Camp - Los Angeles, CA
2014-10-11 Silicon Valley Code Camp, Los Altos Hills, CA
An introduction to reactive programming concepts and basics. I aim here to show what's reactive programming, why it's used and show some frameworks and benchmarks that support it.
The session will provide the knowledge about react page life cycle and how more precise actions or operations can be performed using react hooks concepts
The new GraalVM from Oracle supports multiple language including JavaScript, Python, Ruby, R, C++ as well as Java and other JVM languages. This opens up interesting possibilities for polygot enterprise applications. Now you can use a Node library in a Java application or call an R statistical function from an EJB. Previously, this type of integration was extremely challenging. This session will provide recipes to get up and running along with best practices and some cool demos.
Code: https://github.com/rcuprak/graalvm_jee
Slides from a talk about unit tests in Node.js. The talk was held as a part of an internal Node.js course in ironSource's offices in Tel-Aviv. On Wednesday, September 14th, 2016
All 3 Clean Code presentations provide great value by themselves, but taken together are designed to offer a holistic approach to successful software creation. This first session creates the foundation for the 2nd and 3rd Clean Code presentation on Dependency Injection, as it explains expected base knowledge. Why writing Clean Code makes us more efficient Over the lifetime of a product, maintaining the product is actually one - if not the most - expensive area(s) of the overall product costs.
We will dive into the basics of Inversion of Control (IOC) and Dependency Injection (DI) to review different ways of achieving decoupling, using and exploring both: Best Practices, Design and Anti Patterns. This presentation requires knowledge and understanding of basics like DRY, SoC, SRP, SOLID etc. which are building the base for decoupled architecture. However, we will start at the basics of DI and will work towards intermediate and advanced scenarios depending on the participating group.
This presentation is based on C# and Visual Studio 2013. However, the demonstrated patterns and practice can be applied to every other programming language too.
Note: Moving forwards this presentation will be updated with the latest version of the slides for the last event I did the presentation instead of creating new separate slide decks here on SlideShare.
Presentation dates and locations:
2015-10-03 Silicon Valley Code Camp, San Jose, CA
2015-06-27 SoCal Code Camp - San Diego, CA
2015-06-25 Bay.NET South Bay, Mountain View, CA
2014-11-14 SoCal Code Camp - Los Angeles, CA
2014-10-11 Silicon Valley Code Camp, Los Altos Hills, CA
An introduction to reactive programming concepts and basics. I aim here to show what's reactive programming, why it's used and show some frameworks and benchmarks that support it.
The session will provide the knowledge about react page life cycle and how more precise actions or operations can be performed using react hooks concepts
The new GraalVM from Oracle supports multiple language including JavaScript, Python, Ruby, R, C++ as well as Java and other JVM languages. This opens up interesting possibilities for polygot enterprise applications. Now you can use a Node library in a Java application or call an R statistical function from an EJB. Previously, this type of integration was extremely challenging. This session will provide recipes to get up and running along with best practices and some cool demos.
Code: https://github.com/rcuprak/graalvm_jee
"APIs: the Glue of Cloud Computing"
CloudExpo Europe Keynote - June 22, 2010
The second day of the CloudExpo Europe that was taking place in Prague the 21st and 22nd of June, Steven Willmott, the CEO of 3scale, made a presentation on APIs and their importance for Cloud Computing.
The key highlights of this presentation are:
1. Cloud Computing pushes to the “hyper integration” of the Web and the enabling of key platform to emerge (e.g. the new SkypeKit)…. But not only for computing power
2. Cloud Computing and its different elements fit into an MVC “Cloud Edition” framework thanks to APIs
3. APIs enable Cloud Scale MVC
4. You need to become indispensable in the Value Chain otherwise someone may eat your lunch
5. APIs are key to become indispensable but need to be managed
Best Practices for Architecting a Pragmatic Web API.Mario Cardinal
This presentation teach how to design a real-world and pragmatic web API. It draws from the experience Mario Cardinal have gained over the years being involved architecting many Web API. This presentation begins by differencing between a Web and a REST API, and then continue with the design process. We conclude with the core learnings of the session which is a review of the best practices when designing a web API. Armed with skills acquired, you can expect to see significant improvements in your ability to design a pragmatic web API.
Real World API Business Models That Worked
Mark Boyd, Writer, ProgrammableWeb
What business revenue models are most successful for API providers seeking to build active third-party developer communities? How much can an API act to leverage revenue growth and market share, and what timeline for success is realistic? This presentation goes beyond the theory to share some initial data on what businesses are experiencing when implementing an API strategy.
This presentation summarizes the critical success factors from 15 API business case studies including:
- Type of business model used and revenue-share data against cost estimations
- What developer engagement strategies grew API usage the fastest
- What factors reduced churn rate amongst third-party developers
- Developer onboarding timeframe
- What factors influenced internal support for an API strategy
Les Hazlewood, Stormpath co-founder and CTO and the Apache Shiro PMC Chair demonstrates how to design a beautiful REST + JSON API. Includes the principles of RESTful design, how REST differs from XML, tips for increasing adoption of your API, and security concerns.
Presentation video: https://www.youtube.com/watch?v=5WXYw4J4QOU
More info: http://www.stormpath.com/blog/designing-rest-json-apis
Further reading: http://www.stormpath.com/blog
Sign up for Stormpath: https://api.stormpath.com/register
Stormpath is a user management and authentication service for developers. By offloading user management and authentication to Stormpath, developers can bring applications to market faster, reduce development costs, and protect their users. Easy and secure, the flexible cloud service can manage millions of users with a scalable pricing model.
Welcome to the API Economy: Developing Your API StrategyMuleSoft
View the recording of this webinar: http://www.mulesoft.com/webinars/esb/welcome-api-economy
Learn more about our Anypoint Platform for APIs: https://www.mulesoft.com/platform/api
Gartner predicts 75% of Fortune 500 enterprises will open an API by 2014. In this new API economy, those without an API strategy will be left behind. What does this mean for you and your business? Join Ross Mason, MuleSoft Founder, for a discussion on key API trends and what you can do in this New Enterprise era to unlock competitive advantage for your organization.
Questions discussed:
What has changed with APIs?
What is the API economy and how did we get here?
How are APIs transforming enterprises?
What are key API trends my organization should be planning for?
How can APIs make my business more competitive?
What's a good API business model? If you have an API, or you plan to have an open API, or just want to use APIs in your web or mobile app, what models make sense? See 20 different API business models. This comprehensive survey of the gamut of today's options covering anything from paid to getting paid to indirect.
WARNING: This will be an opinionated webinar.
Among Web architects and API designers we've seen growing interest in HATEOAS as a valuable approach to RESTful Web APIs. In this Webinar, we'll introduce the core principles, look at examples, and explore the value of the approach for API providers and application developers.
Join this live Webinar with Brian Mulloy to discuss the fundamentals and to explore the trade-offs of providing and consuming HATEOAS APIs.
If you can't join the live webinar, register and we'll send you a video recording.
We Will Discuss »
Overview of HATEOAS
Example Applications
Pros and cons of using HATEOS for RESTful API design
Practices and Tools for Building Better APIsPeter Hendriks
The most important part of well-designed Java code is a nice API. A good API helps developers be more productive and write high-quality code quickly. API design matters for any developer, especially in building larger systems with a team. Modern coding tools such as Eclipse and FindBugs contain advanced tooling to help with designing an API and checking for bad usage. This session demonstrates the latest innovations, including new capabilities in Java 8, by presenting realistic examples based on real experiences in large codebases. They show that just a few Java tricks and simple annotations can make all the difference for building a great API.
One of the greatest challenges to developing an API is ensuring that your API lasts. After all, you don’t want to have to release and manage multiple versions of your API just because you weren’t expecting users to use it a certain way, or because you didn’t anticipate far enough down the roadmap. In this session, we’ll talk about the challenge of API Longevity, as well as ways to increase your API lifecycle including having a proper mindset, careful design, agile user experience and prototyping, best design practices including hypermedia, and the challenge of maintaining persistence.
Practices and tools for building better API (JFall 2013)Peter Hendriks
Een belangrijke voorwaarde om goede en leesbare Java code te schrijven is om gebruik te maken van een goede API. Een goede API helpt ontwikkelaars om sneller hoogwaardige code te schrijven. Het ontwerp van een API is daarom belangrijk, zeker als er grotere systemen worden gerealiseerd in teamverband. Moderne ontwikkeltools als Eclipse, IntelliJ IDEA en FindBugs helpen met het schrijven van goede API, en het detecteren van slecht gebruik. Deze sessie gaat in op de laatste ontwikkelingen en mogelijkheden, inclusief nieuwe taalmogelijkheden in Java 8. Er wordt hierbij gebruik gemaakt van praktische situaties en concrete codevoorbeelden, gebaseerd op echte ervaringen in grote codebases. Met praktische tips en toegankelijke tools kan al een grote stap gemaakt worden om in de praktijk beter met API ontwerp om te gaan!
Understanding and Executing on API Developer ExperienceSmartBear
What is Developer Experience, and how can you leverage it to drive adoption and growth for your API? Our very own Keshav Vasudevan will take you through it. Learn more: https://blog.smartbear.com/apis/developer-experience-the-key-to-a-successful-api/
Presentation on how to design applications that are efficient to work with. Focuses on what is efficiency and how can product designers affect it in a positive way. Discusses picking the right features to design, automate manual tasks, streamline input options, ensure the application is understandable, and increase the speed of the application.
API Developer Experience: Why it Matters, and How Documenting Your API with S...SmartBear
Whether you’re new to Swagger, or have already been using the framework for API design, there’s a good chance you still have questions about how to improve your API documentation. Creating API documentation your consumers will love can take some work, but the investment will have a significant payoff in the form of a great developer experience, easier implementation, and improved adoption of your API.
This presentation covers good developer experience in detail, focusing on why and how to provide an optimal experience for developers using your API. We will also cover how Swagger has changed the API design and documentation landscape, and finally show some good practices for API documentation using Swagger in SwaggerHub’s integrated API development platform.
Things to expect in this webinar:
What is Developer Experience (DX)?
What does it mean for an API to have good DX?
API documentation in the context of good DX?
An introduction to the Swagger framework
Designing APIs from a usability perspective using Swagger and SwaggerHub
Understanding and Executing on API Developer ExperienceKeshav Vasudevan
Developer experience (DX) is an extension of general User Experience, which emphasizes the developer, and their experiences working your API. A good API developer experience goes beyond technical writing. It is about providing all the right resources that help your end consumers successfully integrate and work with your API. A well designed developer experience has API documentation at the center of it.
API documentation is the information that is required to successfully consume and integrate with an API. This would be in the form of technical writing, code samples and examples for better understanding how to consume an API.
The OpenAPI Specification is the industry standard API design framework, allowing developers and teams to design, build, document and consume RESTful web services. The OpenAPI Specification is the de facto framework used when API practitioners want to optimize the developer experience.
This talk covers what it means to have an API with good DX by understanding the types of API consumers and their journey from discovery to API integration, and how OpenAPI Spec/Swagger Spec can help in improving general API DX with great documentation.
Given at DevNation 2014, this presentation provides a high level overview for developers about why user experience practices should be a part of every project they undertake.
Through a focus on user-centric design practices, usability testing, and visual design - developers can provide a first-class application that meets and exceeds their user's needs the first time, rather than undergoing serious re-writes of applications due to misunderstandings between project stakeholders and users.
Kevin Whinnery: Best Practices for Cross-Platform Mobile DevelopmentAxway Appcelerator
Kevin Whinnery, Appcelerator Evangelist, shares best practices for creating mobile apps for cross-device deployment. Titanium Mobile is not a "write once, run everywhere" technology solution. Because Titanium provides the platform-specific APIs necessary to create best of breed native applications, the way in which you approach user interface development on one platform might differ significantly for another platform. It is, however, very possible to "write once, adapt everywhere" - to provide rich native experiences while achieving maximum code reuse.
In this presentation, we will cover real world techniques for maximizing code reuse while leveraging platform-specific APIs in Titanium applications. Come with questions, and leave with multiple projects and code examples showing techniques Titanium developers use today to deliver sophisticated and performant cross-platform applications.
Make Your Contribution Count. Adding Value to the API as a Technical Communic...Petko Mikhailov
Even though documenting APIs is a highly technical proposition, the contribution that a technical communicator can make to the documentation is not the same as that of the writing developer. In fact, API documentation is the place where we can shine and make the difference between failure and success of a product on the market.
In this presentation, we'll see what makes good API documentation and how API writers can bring unique value to it.
Presented at the tekom Spring Conference 2019 (Vienna).
E Learning Management System By Tuhin Roy Using PHPTuhin Ray
Bachelor of Information Technology Final Year Project on E-Learning Management System i.e: Creating a site for virtual classroom, sharing materials, students-teacher database and many more. 2019
A Comprehensive Look at Generative AI in Retail App Testing.pdfkalichargn70th171
Traditional software testing methods are being challenged in retail, where customer expectations and technological advancements continually shape the landscape. Enter generative AI—a transformative subset of artificial intelligence technologies poised to revolutionize software testing.
top nidhi software solution freedownloadvrstrong314
This presentation emphasizes the importance of data security and legal compliance for Nidhi companies in India. It highlights how online Nidhi software solutions, like Vector Nidhi Software, offer advanced features tailored to these needs. Key aspects include encryption, access controls, and audit trails to ensure data security. The software complies with regulatory guidelines from the MCA and RBI and adheres to Nidhi Rules, 2014. With customizable, user-friendly interfaces and real-time features, these Nidhi software solutions enhance efficiency, support growth, and provide exceptional member services. The presentation concludes with contact information for further inquiries.
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Shahin Sheidaei
Games are powerful teaching tools, fostering hands-on engagement and fun. But they require careful consideration to succeed. Join me to explore factors in running and selecting games, ensuring they serve as effective teaching tools. Learn to maintain focus on learning objectives while playing, and how to measure the ROI of gaming in education. Discover strategies for pitching gaming to leadership. This session offers insights, tips, and examples for coaches, team leads, and enterprise leaders seeking to teach from simple to complex concepts.
Quarkus Hidden and Forbidden ExtensionsMax Andersen
Quarkus has a vast extension ecosystem and is known for its subsonic and subatomic feature set. Some of these features are not as well known, and some extensions are less talked about, but that does not make them less interesting - quite the opposite.
Come join this talk to see some tips and tricks for using Quarkus and some of the lesser known features, extensions and development techniques.
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns
Unlocking Business Potential: Tailored Technology Solutions by Prosigns
Discover how Prosigns, a leading technology solutions provider, partners with businesses to drive innovation and success. Our presentation showcases our comprehensive range of services, including custom software development, web and mobile app development, AI & ML solutions, blockchain integration, DevOps services, and Microsoft Dynamics 365 support.
Custom Software Development: Prosigns specializes in creating bespoke software solutions that cater to your unique business needs. Our team of experts works closely with you to understand your requirements and deliver tailor-made software that enhances efficiency and drives growth.
Web and Mobile App Development: From responsive websites to intuitive mobile applications, Prosigns develops cutting-edge solutions that engage users and deliver seamless experiences across devices.
AI & ML Solutions: Harnessing the power of Artificial Intelligence and Machine Learning, Prosigns provides smart solutions that automate processes, provide valuable insights, and drive informed decision-making.
Blockchain Integration: Prosigns offers comprehensive blockchain solutions, including development, integration, and consulting services, enabling businesses to leverage blockchain technology for enhanced security, transparency, and efficiency.
DevOps Services: Prosigns' DevOps services streamline development and operations processes, ensuring faster and more reliable software delivery through automation and continuous integration.
Microsoft Dynamics 365 Support: Prosigns provides comprehensive support and maintenance services for Microsoft Dynamics 365, ensuring your system is always up-to-date, secure, and running smoothly.
Learn how our collaborative approach and dedication to excellence help businesses achieve their goals and stay ahead in today's digital landscape. From concept to deployment, Prosigns is your trusted partner for transforming ideas into reality and unlocking the full potential of your business.
Join us on a journey of innovation and growth. Let's partner for success with Prosigns.
First Steps with Globus Compute Multi-User EndpointsGlobus
In this presentation we will share our experiences around getting started with the Globus Compute multi-user endpoint. Working with the Pharmacology group at the University of Auckland, we have previously written an application using Globus Compute that can offload computationally expensive steps in the researcher's workflows, which they wish to manage from their familiar Windows environments, onto the NeSI (New Zealand eScience Infrastructure) cluster. Some of the challenges we have encountered were that each researcher had to set up and manage their own single-user globus compute endpoint and that the workloads had varying resource requirements (CPUs, memory and wall time) between different runs. We hope that the multi-user endpoint will help to address these challenges and share an update on our progress here.
Large Language Models and the End of ProgrammingMatt Welsh
Talk by Matt Welsh at Craft Conference 2024 on the impact that Large Language Models will have on the future of software development. In this talk, I discuss the ways in which LLMs will impact the software industry, from replacing human software developers with AI, to replacing conventional software with models that perform reasoning, computation, and problem-solving.
Cyaniclab : Software Development Agency Portfolio.pdfCyanic lab
CyanicLab, an offshore custom software development company based in Sweden,India, Finland, is your go-to partner for startup development and innovative web design solutions. Our expert team specializes in crafting cutting-edge software tailored to meet the unique needs of startups and established enterprises alike. From conceptualization to execution, we offer comprehensive services including web and mobile app development, UI/UX design, and ongoing software maintenance. Ready to elevate your business? Contact CyanicLab today and let us propel your vision to success with our top-notch IT solutions.
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...Mind IT Systems
Healthcare providers often struggle with the complexities of chronic conditions and remote patient monitoring, as each patient requires personalized care and ongoing monitoring. Off-the-shelf solutions may not meet these diverse needs, leading to inefficiencies and gaps in care. It’s here, custom healthcare software offers a tailored solution, ensuring improved care and effectiveness.
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...informapgpstrackings
Keep tabs on your field staff effortlessly with Informap Technology Centre LLC. Real-time tracking, task assignment, and smart features for efficient management. Request a live demo today!
For more details, visit us : https://informapuae.com/field-staff-tracking/
We describe the deployment and use of Globus Compute for remote computation. This content is aimed at researchers who wish to compute on remote resources using a unified programming interface, as well as system administrators who will deploy and operate Globus Compute services on their research computing infrastructure.
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Globus
Large Language Models (LLMs) are currently the center of attention in the tech world, particularly for their potential to advance research. In this presentation, we'll explore a straightforward and effective method for quickly initiating inference runs on supercomputers using the vLLM tool with Globus Compute, specifically on the Polaris system at ALCF. We'll begin by briefly discussing the popularity and applications of LLMs in various fields. Following this, we will introduce the vLLM tool, and explain how it integrates with Globus Compute to efficiently manage LLM operations on Polaris. Attendees will learn the practical aspects of setting up and remotely triggering LLMs from local machines, focusing on ease of use and efficiency. This talk is ideal for researchers and practitioners looking to leverage the power of LLMs in their work, offering a clear guide to harnessing supercomputing resources for quick and effective LLM inference.
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...Juraj Vysvader
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I didn't get rich from it but it did have 63K downloads (powered possible tens of thousands of websites).
In software engineering, the right architecture is essential for robust, scalable platforms. Wix has undergone a pivotal shift from event sourcing to a CRUD-based model for its microservices. This talk will chart the course of this pivotal journey.
Event sourcing, which records state changes as immutable events, provided robust auditing and "time travel" debugging for Wix Stores' microservices. Despite its benefits, the complexity it introduced in state management slowed development. Wix responded by adopting a simpler, unified CRUD model. This talk will explore the challenges of event sourcing and the advantages of Wix's new "CRUD on steroids" approach, which streamlines API integration and domain event management while preserving data integrity and system resilience.
Participants will gain valuable insights into Wix's strategies for ensuring atomicity in database updates and event production, as well as caching, materialization, and performance optimization techniques within a distributed system.
Join us to discover how Wix has mastered the art of balancing simplicity and extensibility, and learn how the re-adoption of the modest CRUD has turbocharged their development velocity, resilience, and scalability in a high-growth environment.
Check out the webinar slides to learn more about how XfilesPro transforms Salesforce document management by leveraging its world-class applications. For more details, please connect with sales@xfilespro.com
If you want to watch the on-demand webinar, please click here: https://www.xfilespro.com/webinars/salesforce-document-management-2-0-smarter-faster-better/
Code reviews are vital for ensuring good code quality. They serve as one of our last lines of defense against bugs and subpar code reaching production.
Yet, they often turn into annoying tasks riddled with frustration, hostility, unclear feedback and lack of standards. How can we improve this crucial process?
In this session we will cover:
- The Art of Effective Code Reviews
- Streamlining the Review Process
- Elevating Reviews with Automated Tools
By the end of this presentation, you'll have the knowledge on how to organize and improve your code review proces
1. public void saveAsMidi()
{
Player player = new Player();
Pattern pattern = new Pattern("A5q B5q C5q");
try {
player.saveMidi(pattern, new File("MySong.midi"));
} catch (IOException e)
{
// handle IO Exception
}
}
public void loadAndPlayMidi()
{
Player player = new Player();
try {
player.playMidiDirectly(new File("MySong.midi"));
} catch (IOException e)
{
// handle IO Exception
} catch (InvalidMidiDataException e)
{
// handle Invalid MIDI Data Exception
}
}
public void savePattern()
{
Pattern pattern = new Pattern("A5q B5q C5q");
try {
pattern.savePattern(new File("MusicString.jfugue"));
} catch (IOException e)
{
// handle IO Exception
}
}
public void loadPattern()
{
Player player = new Player();
Pattern pattern = null;
try {
pattern = Pattern.loadPattern(new File("MusicString.jfugue"));
player.play(pattern);
Golden Rules of API Design
David Koelle
davekoelle.com
July 19, 2011
2. Objectives
• Learn guidelines for creating a solid API
• Understand the importance of API Usability
• Consider how even the best-designed API needs to
be accompanied with clear documents and guides to
succeed
3. Overview
• Background and Definitions
• The Importance of API Usability
• Guidelines for API Design
• The Importance of Effective Communication in API
Usability
• Questions and Discussion
4. Overview
• Background and Definitions
• The Importance of API Usability
• Guidelines for API Design
• The Importance of Effective Communication in API
Usability
• Questions and Discussion
5. Speaker background
• David Koelle
• First computer: TI-99/4A in 2nd grade
• Graduate of Worcester Polytechnic Institute
(Massachusetts, USA)
• 14-year career spans large and small businesses and start-ups
• Three-time Java Rock Star for talks given at JavaOne
• David has developed APIs for:
• Music Programming (JFugue)
• User Interfaces
• Graphics and Animation
• Business Intelligence
• Social Network Analysis
6. Definitions
• An Application Programming Interface (API) is
comprised of the exposed code that other
developers use to access a program’s functionality
• Examples:
• JFugue API for music programming (Java)
• Google Maps API (JavaScript, Flash, and web services)
• API Usability is a set of guidelines for creating APIs
that others can understand and use effectively
7. Definitions of usability
“Usability is how easy, efficient, and pleasant
it is to use a service”
– Jacob Nielsen
“Usability is the effectiveness, efficiency, and satisfaction
with which specified users achieve specified goals
in particular environments”
– ISO-9241 (Ergonomics of Human System Interaction)
• These definitions come from the User Interface (UI)
community, but are applicable to API Design as well!
8. Components of API Usability
• API Usability is informed by good programming
practices and user interface design
Good
Programming
Practices
User
Interface
Design
API Usability
9. Components of API Usability
• Effective communication is also an important part of
getting an API used!
Good
Programming
Practices
User
Interface
Design
API Usability
Effective
Communication
10. Good programming practices
• To design a good API, you need to use good
development practices
• A good API will follow all of the guidance in Joshua
Bloch’s book, “Effective Java”. A selection:
• Item 13: Minimize the accessibility of classes and members
• Item 38: Check parameters for validity
• Item 56: Adhere to generally accepted naming conventions
• Item 64: Strive for failure atomicity
11. User interface design
• The most important question in user interface design
is: Who is the user?
• Who are the users of an API? Other developers!
• This should be a group that’s easy for us to understand
• You could get into “personas” if you want: “Mike is a 25-
year old college graduate who learned programming in
high school and reads a lot of xkcd…”
• You also need to know: What are the user’s goals?
• What will the user try to achieve by using your API?
• How will the user measure success?
• How can you help the user succeed?
12. Four principles for highly usable systems
(D. Norman)
• Good visibility: The possible actions, the states and
the alternatives for action must be exposed
• Good conceptual model: The use of helpful,
consistent and complete abstractions helping the
users to create a proper mental image model of the
system
• Good mapping between actions and results: Natural
mapping between actions and their results
• Good feedback about results of actions: Full and
continuous feedback about the results of actions
13. Metrics for evaluating usability of a system
(B. Schneiderman)
• Time to learn a system
• Speed of task execution
• Rate of errors
• Knowledge retention over time
• Subjective user satisfaction
14. Characteristics of a good API (J. Bloch)
• Easy to learn
• Easy to use, even without documentation
• Hard to misuse
• Easy to read and maintain code that uses it
• Sufficiently powerful to satisfy requirements
• Easy to extend
• Appropriate to audience
From Joshua Bloch’s “How to Design a Good API and Why it Matters”
15. Overview
• Background and Definitions
• The Importance of API Usability
• Guidelines for API Design
• The Importance of Effective Communication in API
Usability
• Questions and Discussion
16. Realize that publicizing an API
represents a commitment
• An API is a coding “contract”, and users of your API will
expect future versions to be compatible with released
versions
• It’s easy to add new functionality
• It’s hard to delete functionality
• This is why so many methods in the Java API are deprecated
• It’s just wrong to make a method to something
completely different between versions
• I’m glad I can’t come up with a good example for this one!
• This is the most important rule. The rest is all detail.
17. Begin with the end in mind
• Know what you want your API to achieve
• Mock up several sample applications that will use
your API before you start developing the API itself
• Develop your API using Test-Driven Development
18. Make conceptually easy things
simple to do
• Use the hidden layers of your API to offload
complexity from the end-user developer
• Example: Letting the user make an audible beep:
Bad API Good API
Open a sound data line
beep(int frequency)
Create a clip object
Generate bytes for the
frequencies
Send the clip to the data line
Close the data line
Make sure all variables are
cleaned up
19. Construct complete objects only
• Never allow a user to construct an object that is not
fully formed. Bad example:
Foo foo = new Foo();
foo.setCriticalValue(true); // This needs to be
set before the object can be used
• Two problems with this:
• Your API cannot force developers to call methods in a
predictable order
• Additional method calls require the user to learn about
those calls
• Make users think up front about what they need to
provide to create a complete object
20. Expose the minimum amount of code
• Learn how to use these Java keywords effectively:
Scope: public, private, protected (and package scope)
Modifiers: final, transient
• Using scope and modifiers properly helps users know
what they should and should not touch
• Realize that the more classes and methods you
publish, the more you’ll be accountable for in the
future
21. Be compact and concise
• Help the user derive the most benefit from the
fewest lines of code
• Example - play music in JFugue:
Player player = new Player();
player.play(“C D E F G A B”);
• Provide the smallest set of functionality in your code
that provides the most benefit
• You could write the “War and Peace” of APIs, and it might
be great, but no one would take the time to learn it all!
22. Be absolutely correct
• People rely on your API to do exactly what it says it
will do
• Make sure your API works correctly, and generates
correct output
Borrowed from Elliotte Rusty Harold’s
XOM Design Principles
23. Encode common patterns and
encourage best practices
• Notice when there code that you repeat over and
over in your sample programs
• This common pattern may be something that your users
will do, too
• Make the common code a part of your API
• Notice when you’ve identified the best way to
perform a task or achieve a goal with your API
• This may also be something your users will do
• Make the best practice a part of your API
24. Report errors immediately and clearly
• Report errors and exceptions as soon as they happen
• Guard against error-prone input by using assertions
at the beginning of a method
• Make errors as verbose as possible
• Bad example: “Can’t find file”
• Good example: “The file filename was not found in folder
folder name”
25. Overview
• Background and Definitions
• The Importance of API Usability
• Guidelines for API Design
• The Importance of Effective Communication in API
Usability
• Questions and Discussion
26. The importance of effective
communication in API Usability
• When designing an API, it’s important to use:
• Employ good programming practices
• Perform user interface design
• Now you have a quality API, and you want people to
use it. What next?
• Once the API is complete, your communication about
the API is critical to its success
27. Engage with the user community
• Allow users to communicate with you, and engage
your users in discussion
• Track requests and defects in a defect tracking
system (e.g., Google Code, Jira)
• Be responsive to email comments from users
• Publish a blog with discussions about your API
• When people contact you, ask them how they’re
using your API!
• You need to know what your users are doing, so you can
make effective changes to future versions of your API
• You may be delighted at some of the responses
28. Be open in communicating an
evolving API
• If you need to make changes to your published API,
be clear about it
• People with older versions of your API depend on
new versions acting the same way for existing
functionality
29. Provide clear support materials
• The success of your API project also depends on your
presentation of your material that markets the API:
• Documentation
• Website
• Discussion boards
• If someone goes to your webpage and can't figure
out what your API does, how to download it, how to
use it, and what some simple examples might be,
they probably won't use it
30. Finally: Delight your users
• Make sure your users enjoy using your API!
• Think of ways to make your API clever and well-
crafted
• Ensure your API anticipates the user’s needs by
providing easy access to features users want
• Prefer enjoyment through effective code as opposed
to humor in class and method names
• That comes off as a little tacky, and humor doesn’t always
translate well
31. Overview
• Background and Definitions
• The Importance of API Usability
• Guidelines for API Design
• The Importance of Effective Communication in API
Usability
• Questions and Discussion
32. Resources
• Joshua Bloch, “How to Design a Good API and Why it
Matters”
http://www.youtube.com/watch?v=aAb7hSCtvGw
• Joshua Bloch, “Effective Java”
http://www.amazon.com/Effective-Java-2nd-Joshua-Bloch/dp/0321356683
• Bill Venners, “API Design with Java”
http://www.artima.com/apidesign/
• Five-part discussion with Bill Venners and Elliotte Rusty
Harold on API design for JDOM and XOM
Part 5: http://www.artima.com/intv/xomdesign.html
• Jaroslav Tulach, “Practical API Design” (Apress)
http://www.apress.com/9781430209737
33. public void saveAsMidi()
{
Player player = new Player();
Pattern pattern = new Pattern("A5q B5q C5q");
try {
player.saveMidi(pattern, new File("MySong.midi"));
} catch (IOException e)
{
// handle IO Exception
}
}
public void loadAndPlayMidi()
{
Player player = new Player();
try {
player.playMidiDirectly(new File("MySong.midi"));
} catch (IOException e)
{
// handle IO Exception
} catch (InvalidMidiDataException e)
{
// handle Invalid MIDI Data Exception
}
}
public void savePattern()
{
Pattern pattern = new Pattern("A5q B5q C5q");
try {
pattern.savePattern(new File("MusicString.jfugue"));
} catch (IOException e)
{
// handle IO Exception
}
}
public void loadPattern()
{
Player player = new Player();
Pattern pattern = null;
try {
pattern = Pattern.loadPattern(new File("MusicString.jfugue"));
player.play(pattern);
Thank You!
David Koelle
davekoelle.com
July 19, 2011