Presented at code::dive (2016-11-15)
Video available at https://www.youtube.com/watch?v=brfqm9k6qzc
It is all to easy to dismiss problematic codebases on some nebulous idea of bad practice or bad programmers. Poor code, however, is rarely arbitrary and random in its structure or formulation. Systems of code, well or poorly structured, emerge from systems of practice, whether effective or ineffective. To improve code quality, it makes more sense to pick apart the specific practices and see their interplay — the cause — than to simply focus on the code itself — the effect. This talk looks at how a handful of coding habits, design practices and assumptions can systematically balloon code and compound its accidental complexity.
Presented at Foo Café (2019-03-21)
Video at https://www.youtube.com/watch?v=tLSKLLxrZyY
Programmers use coding katas to kick the tyres of their programming languages, paradigms and practices. Typically anchored in a TDD cycle, katas are simple problems that give programmers the opportunity to exercise deliberate practice and explore different approaches, whether programming style, pair programming or test-first programming.
But the simplicity can be deceptive, with many programmers tiring of these katas too soon, missing out on some of the more mind-bending and paradigm-expanding opportunities on offer.
This session will pick on a couple of katas and dig deeper into TDD, lambdas, language(s), (dys)functional programming and Alcubierre drive. It will present code in a variety of languages, highlight the weaknesses of some common mantras, play around with ideas — and blend code, humour and general nerdiness to be both an enjoyable and educational session.
Presented at ACCU (25th April 2015)
Fizz Buzz. It's a drinking game. It's an educational game to teach kids division. It's an interview question. It's a coding kata. It's all these things. And it can be fun. It can also be used to illustrate different coding paradigms, languages and techniques, from the serious to the jocoserious to the you-cannot-be-serious. This talk uses this simple problem to take you on a bazaar and bizarre tour, from plain examples to provocative examples in common and less common languages, sequential to concurrent, procedural to functional, elegant to ridiculous.
Keynote presented at Reaktor Breakpoint (25th September 2015)
Video available at https://vimeo.com/144335290
FizzBuzz. It's a drinking game. It's an educational game to teach kids division. It's an interview question. It's a coding kata. It's all these things. And it can be fun. It can also be used to illustrate different coding paradigms, languages and techniques, from the serious to the jocoserious to the you-cannot-be-serious. This talk uses this simple problem to take you on a bazaar and bizarre trek, from plain examples to provocative examples in common and less common languages, sequential to concurrent, procedural to functional, elegant to ridiculous.
Слово final многогранно и многокрасочно. Ни для кого не секрет, что оно может запрещать наследование классов и запрещать изменение значений полей. Более узкому кругу лиц знакомо, что final обладает особыми свойствами при работе нескольких потоков.
К сожалению, в сети много мифов о том какие свойства даёт final, и нет внятного толкования почему и как оно работает. Даже на докладах про java memory model final’ы упоминают лишь вскользь. Что же делать? Совсем не использовать final’ы? Это явно не выбор человека, который любит докапываться до истины!
В данном докладе мы расставим все точки в слове final, рассмотрим на конкретных примерах как работает раздел 17.5 спецификации языка Java "Final Field Semantics", а также то, какие бывают типичные ошибки в трактовке спецификации.
Presented at Foo Café (2019-03-21)
Video at https://www.youtube.com/watch?v=tLSKLLxrZyY
Programmers use coding katas to kick the tyres of their programming languages, paradigms and practices. Typically anchored in a TDD cycle, katas are simple problems that give programmers the opportunity to exercise deliberate practice and explore different approaches, whether programming style, pair programming or test-first programming.
But the simplicity can be deceptive, with many programmers tiring of these katas too soon, missing out on some of the more mind-bending and paradigm-expanding opportunities on offer.
This session will pick on a couple of katas and dig deeper into TDD, lambdas, language(s), (dys)functional programming and Alcubierre drive. It will present code in a variety of languages, highlight the weaknesses of some common mantras, play around with ideas — and blend code, humour and general nerdiness to be both an enjoyable and educational session.
Presented at ACCU (25th April 2015)
Fizz Buzz. It's a drinking game. It's an educational game to teach kids division. It's an interview question. It's a coding kata. It's all these things. And it can be fun. It can also be used to illustrate different coding paradigms, languages and techniques, from the serious to the jocoserious to the you-cannot-be-serious. This talk uses this simple problem to take you on a bazaar and bizarre tour, from plain examples to provocative examples in common and less common languages, sequential to concurrent, procedural to functional, elegant to ridiculous.
Keynote presented at Reaktor Breakpoint (25th September 2015)
Video available at https://vimeo.com/144335290
FizzBuzz. It's a drinking game. It's an educational game to teach kids division. It's an interview question. It's a coding kata. It's all these things. And it can be fun. It can also be used to illustrate different coding paradigms, languages and techniques, from the serious to the jocoserious to the you-cannot-be-serious. This talk uses this simple problem to take you on a bazaar and bizarre trek, from plain examples to provocative examples in common and less common languages, sequential to concurrent, procedural to functional, elegant to ridiculous.
Слово final многогранно и многокрасочно. Ни для кого не секрет, что оно может запрещать наследование классов и запрещать изменение значений полей. Более узкому кругу лиц знакомо, что final обладает особыми свойствами при работе нескольких потоков.
К сожалению, в сети много мифов о том какие свойства даёт final, и нет внятного толкования почему и как оно работает. Даже на докладах про java memory model final’ы упоминают лишь вскользь. Что же делать? Совсем не использовать final’ы? Это явно не выбор человека, который любит докапываться до истины!
В данном докладе мы расставим все точки в слове final, рассмотрим на конкретных примерах как работает раздел 17.5 спецификации языка Java "Final Field Semantics", а также то, какие бывают типичные ошибки в трактовке спецификации.
Testing: the final frontier. These are the voyages of Software Craftsmanship. Its continuing mission: to explore strange new worlds, to seek out new code and new patterns, to boldly go where no one has gone before. Looking to take your testing to new worlds? Want to verify your code meetings your user's requirements? Come learn about behavior and property testing in .Net. We'll look at how SpecFlow can get everyone on the same page and how to find more edge cases with property testing using FsCheck.
Code Obfuscation, PHP shells & more
What hackers do once they get passed your code - and how you can detect & fix it.
Content:
- What happens when I get hacked?
- What's code obfuscation?
- What are PHP shells?
- Show me some clever hacks!
- Prevention
- Post-hack cleanup
What is this not about:
- How can I hack a website?
- How can I DoS a website?
- How can I find my insecure code?
The Anatomy of an Exploit (NDC TechTown 2019)Patricia Aas
Security vulnerabilities and secure coding is often talked about in the abstract by programmers, but rarely understood. In this talk we will walk through simple exploit attempts, and finally a simple stack buffer overflow exploit, how it’s developed and how it’s used.
The goal is to try to get a feeling for the point of view of an "attacker", and to slowly start looking at exploitation as just another programming practice. We will mainly be looking at C and x86_64 assembly, so bring snacks.
Instead of Tree or other weak classifiers we take NaiveBayes which is not necessarily a weak learner and evaluate what happens when Cross Validate a not so weak learner.
Testing: the final frontier. These are the voyages of Software Craftsmanship. Its continuing mission: to explore strange new worlds, to seek out new code and new patterns, to boldly go where no one has gone before. Looking to take your testing to new worlds? Want to verify your code meetings your user's requirements? Come learn about behavior and property testing in .Net. We'll look at how SpecFlow can get everyone on the same page and how to find more edge cases with property testing using FsCheck.
Code Obfuscation, PHP shells & more
What hackers do once they get passed your code - and how you can detect & fix it.
Content:
- What happens when I get hacked?
- What's code obfuscation?
- What are PHP shells?
- Show me some clever hacks!
- Prevention
- Post-hack cleanup
What is this not about:
- How can I hack a website?
- How can I DoS a website?
- How can I find my insecure code?
The Anatomy of an Exploit (NDC TechTown 2019)Patricia Aas
Security vulnerabilities and secure coding is often talked about in the abstract by programmers, but rarely understood. In this talk we will walk through simple exploit attempts, and finally a simple stack buffer overflow exploit, how it’s developed and how it’s used.
The goal is to try to get a feeling for the point of view of an "attacker", and to slowly start looking at exploitation as just another programming practice. We will mainly be looking at C and x86_64 assembly, so bring snacks.
Instead of Tree or other weak classifiers we take NaiveBayes which is not necessarily a weak learner and evaluate what happens when Cross Validate a not so weak learner.
Самые вкусные баги из игрового кода: как ошибаются наши коллеги-программисты ...DevGAMM Conference
Один из лучших способов снизить количество багов в играх – это показывать программистам, как не стоит писать код. В своём докладе я соберу самые вкусные и необычные ошибки, которые удалось найти в C++ и C# коде таких игр, как VVVVVV, Space Engineers, Command & Conquer, osu! и даже Doom. Я уверен, что каждый из слушателей обязательно узнает для себя что-то новое. В конце концов, это просто приятно – лично увидеть ошибки из кода знакомой и любимой игры!
Reversing & Malware Analysis Training Part 6 - Practical Reversing (I)securityxploded
This presentation is part of our Reverse Engineering & Malware Analysis Training program.
For more details refer our Security Training page
http://securityxploded.com/security-training.php
Similar to Clean Coders Hate What Happens To Your Code When You Use These Enterprise Programming Tricks (20)
Presented at .NET South West (2024-03-26)
https://www.meetup.com/dotnetsouthwest/events/299766807/
One of the greatest shifts in modern programming practices has been how programmers across many different domains, languages and environments have embraced unit testing. Good unit testing, however, is more than waving NUnit at your C# source. Tests help to make long-term product development cost effective rather than a cost centre, they underpin the effective flow of CI/CD and reduce failure demand on a team.
But the discussion of unit testing goes further than simply writing tests: what makes a good unit test? It is not enough to have tests; poor quality tests can hold back development just as good tests can streamline it. This session provides a perspective on what good unit tests (GUTs) can look like with a couple of examples.
Presented at Agile meets Architecture (2023-10-05)
Video at https://www.youtube.com/watch?v=LLEXAdO3X1o
One of the (most overlooked) principles of the Manifesto for Agile Software Development is that "Continuous attention to technical excellence and good design enhances agility". All too often, work that focuses on addressing technical issues is deprioritised in the name of focusing on business value.
Is there a case for technical excellence — in code, in architecture, in people — beyond its appearance on a might-as-well-be-hidden page on a manifesto that's over two decades old? Is technical excellence only the concern of technical roles? Is a good architecture in conflict with business value or a vehicle for it?
This session looks to go beyond buzzwords to build a case for technical excellence that appeals to all roles in a development organisation, noting that "The best architectures, requirements, and designs emerge from self-organizing teams".
Presented online for Build Stuff meetup (https://www.buildstuff.events/events/online-build-stuff-meetup-with-kevlin-henney-and-cassandra-faris)
Whether we are talking about software architecture, coding practices or our development process, it's important to keep it real. All too often we find ourselves attracted to ideas that sound great in theory, but may not work out in practice. All too often we assume we are right — the planned release schedule, the key architectural decisions, the good practices we saw in a blog — but fail to adjust for reality. We fail to acknowledge that our knowledge was incomplete or that the situation has changed, sticking to the plan and practice regardless.
In this talk we will look at what an empirical approach to development means in practice, why it is that up-front architecture is risky and expensive, why it is that most teams who say they're doing agile development are not, and how we can use uncertainty and instability to structure our time and our code.
Presented online for C++ on Sea (2020-07-17)
Video at https://www.youtube.com/watch?v=Bai1DTcCHVE
Lambdas. All the cool kid languages have them. But does lambda mean what C++ and other languages, from Java to Python, mean by lambda? Where did lambdas come from? What were they originally for? What is their relationship to data abstraction?
In this session we will into the history, the syntax, the uses and abuses of lambdas and the way in which lambda constructs in C++ and other languages do (or do not) match the original construct introduced in lambda calculus.
Presented online for javaBin (2020-04-14)
Video at https://www.youtube.com/watch?v=orcSUE0Jjdc
Lambdas. All the cool kid languages have them. But does ‘lambda’ mean what Java, JavaScript, etc. mean by ‘lambda’? Where did lambdas come from? What were they originally for? What is their relationship to data abstraction?
In this session we will look into the history, the syntax and the uses of lambdas and the way in which lambda constructs in Java and other languages do (or do not) match the original construct introduced in lambda calculus.
Presented at DevSum (2018-05-31)
The SOLID principles are often presented as being core to good code design practice. Each of S, O, L, I and D do not, however, necessarily mean what programmers expect they mean or are taught. By understanding this range of beliefs we can learn more about practices for objects, components and interfaces than just S, O, L, I and D.
This talk reviews the SOLID principles and reveals contradictions and different interpretations. It is through paradoxes and surprises we often gain insights. We will leave SOLID somewhat more fluid, but having learnt from them more than expected.
Procedural Programming: It’s Back? It Never Went AwayKevlin Henney
Presented at ACCU Conference 2018 (2018-04-12)
Video at https://www.youtube.com/watch?v=mrY6xrWp3Gs
When programmers describe code as 'procedural', it’s generally not meant as a compliment. There is a belief that we have collectively moved pass such thinking and onto better paradigms. But a paradigm is no more than a pattern language, a family of solutions fit for a context. Change the kind of problem you are solving and you may find a different solution makes sense — even, in these days where pure functions battle it out with classy objects, procedural programming.
This talk takes a look at some of the past, present and future of procedural programming, looking at how there’s more to it than many first assume, how it has informed and continues to influence language design and how it relates to other paradigms, such as functional and OO.
Structure and Interpretation of Test CasesKevlin Henney
Presented at ACCU Cambridge (2018-10-23)
Throw a line of code into many codebases and it's sure to hit one or more testing frameworks. There's no shortage of frameworks for testing, each with their particular spin and set of conventions, but that glut is not always matched by a clear vision of how to structure and use tests — a framework is a vehicle, but you still need to know how to drive. The computer science classic, Structure and Interpretation of Computer Programs, points out that "Programs must be written for people to read, and only incidentally for machines to execute". The same is true of test code.
This talk takes a deep dive into unit testing, looking at examples and counterexamples across a number of languages and frameworks, from naming to nesting, exploring the benefits of data-driven testing, the trade-offs between example-based and property-based testing, how to get the most out of the common given–when–then refrain and knowing how far to follow it.
Keynote present at Agile Tour Vienna (2018-10-06)
Velocity. Sprints. More points, more speed. An obsession with speed often overtakes the core values of agile software development. It’s not just development of software; it’s development of working software. Sprints are not about sprinting; they’re about sustainable pace. Time to market is less important than time in market. Full-stack development is normally a statement about technology, but it also applies to individuals and interactions. The full stack touches both the code and the world outside the code, and with that view comes responsibility and pause for thought. Doing the wrong thing smarter is not smart. The point of a team is its group intelligence not its numbers. Is scaling up the challenge, or is scaling down the real challenge? The distraction and misuse of speed, velocity, point-based systems, time, team size, scale, etc. is not the accelerant of agile development. Agility lies in experimentation, responsiveness and team intelligence.
Keynote presented at NewCrafts (2018-06-18)
Video available at https://vimeo.com/276832516
It has been said that immutability changes everything. But what does that mean in practice? What does it mean for existing code that looks more like the mutant apocalypse than an elegant application of mathematical thinking? Immutability can be an ideal that is hard to reach. Refactoring, on the other hand, is all about the art of the possible. In this talk we'll be clarifying motivation and exploring some approaches to help reducing state mutability in code.
Keynote presented at GOTO Chicago (2018-04-26)
Video available at https://www.youtube.com/watch?v=AbgsfeGvg3E
Everything is changing. Everything is new. Frameworks, platforms and trends are displaced on a weekly basis. Skills are churning.
And yet... Beneath this seemingly turbulent flow there is a slow current, strong and steady, changing relatively little over the decades. Concepts with a long history appear in new forms and fads and technologies. Principles are revisited. Ideas once lost to the mainstream are found again.
In this keynote we revisit the present through the past, looking at the enduring principles that shape programming languages, architecture, development practice and development process, the ideas that cycle round, each time becoming perhaps a little better defined, a little more mature, and look to see what else might be on the horizon.
Presented at SwanseaCon (2017-09-26)
We default to considering systems from an insider's perspective; the view from outside can be quite different. Can we apply this inversion to more than just requirements?
We may say we want testing, but what do we want from testing? We may say we want logging, but what do we want from logging? We may say we want clean code, but what do we want from clean code? We may say we want an agile process, but what do we want from an agile process? These are harder questions, but their answers can make for better solutions.
Presented at .NET South West (2017-07-25)
Code is basically made up of three things: names, spacing and punctuation. With these three tools a programmer needs to communicate intent, and not simply instruct. But if we look at most approaches to naming, they are based on the idea that names are merely labels, so that discussion of identifier naming becomes little more than a discussion of good labelling.
A good name is more than a label; a good name should change the way the reader thinks. A good name should describe structure with intention, as opposed to the affix-heavy approach common to many naming conventions in current use, where the addition of more prefixes and suffixes becomes homeopathic, diluting the meaning. Good naming is part of good design. This session looks at why and what it takes to get a good name.
Thinking Outside the Synchronisation QuadrantKevlin Henney
Presented at code::dive (2016-11-16)
Video available at https://www.youtube.com/watch?v=yl25p91flLY
Ask programmers what comes to mind when you say concurrency and most are likely to say threads. Ask what comes to mind when you say threads and most are likely to say locks or synchronisation. These assumptions are so deeply held that they define and constrain how programmers are taught and think about concurrency: thread safety is almost synonymous with the avoidance of race conditions and the guarded protection of mutable state. But this is only one quadrant of four possibilities, a quadrant diagram partitioned by mutable–immutable along one axis and shared–unshared along another. Modern C++ supports programmers in all four quadrants, not just the synchronisation quadrant. From immutability to actors, this talk will take a look at patterns and practices that encourage thinking and coding outside the locked box.
Presented at GOTO Amsterdam (2017-06-13)
Video available at https://www.youtube.com/watch?v=YyhfK-aBo-Y
What is risk? Many people aren't sure, but it's not just uncertainty: risk is exposure to uncertainty.
Instead of just plastering over the cracks, security should also involve reducing the size and number of cracks, reducing the opportunities for cracks to appear, reducing the class of errors and oversights that can open a system to failure instigated from the outside. We can learn a lot from other kinds of software failure, because every failure unrelated to security can be easily reframed as a security-failure opportunity.
This is not a talk about access control models, authentication, encryption standards, firewalls, etc. This is a talk about reducing risk that lives in the code and the assumptions of architecture, reducing the risk in development practices and in the blind spot of development practices.
Keynote presented at SATURN (2nd May 2017)
Video available at https://www.youtube.com/watch?v=MS3c9hz0bRg
"It's just a detail." Have you ever said that or been told that? Whether it's about implementation or requirements, we often use the word detail to suggest that something is not important enough to worry about. There are so many things to worry about in software development that we need to prioritize—too much detail, not enough focus. The problem is that in software, the details matter because that is what software is: lots of details brought together in combination. If we don't focus on the details, we get debt, defects, and delays.
Presented at Agile Bath & Bristol (21st March 2017)
If software development is a co-operative game, as Alistair Cockburn observed, then what kind of game is Scrum? Lots of people are playing it — or say they are — but there seems to be some disagreement about what the point of the game is, how to play it and even, in many cases, what the rules are. This talk looks at Scrum and other agile approaches through the lens of nomic games, hypothesis-driven development and fun.
Presented at the European Bioinformatics Institute (17th March 2017)
We often talk about good code — that we would like to write it, that there isn't enough of it, that it should not be considered an optional attribute of a codebase. We often talk about it but, when it comes to being precise, we don't always agree what constitutes good code, nor do we necessarily share a common view on its value.
Keynote presented at European Testing Conference (9th February 2017)
What happens when things break? What happens when software fails? We regard it as a normal and personal inconvenience when apps crash or servers become unavailable, but what are the implications beyond the individual user? Is software reliability simply a business decision or does it have economic, social and cultural consequences? What are the moral and practical implications for software developers? And when we talk of ‘systems’, are we part of the ‘system’? What about the bugs on our side of the keyboard? In this talk we will explore examples of failures in software and its application, and how they affect us at different scales, from user to society.
Seven Ineffective Coding Habits of Many ProgrammersKevlin Henney
Presented at DevTernity (1st December 2016)
Video available at https://www.youtube.com/watch?v=SUIUZ09mnwM
Habits help you manage the complexity of code. You apply existing skill and knowledge automatically to the detail while focusing on the bigger picture. But because you acquire habits largely by imitation, and rarely question them, how do you know your habits are effective? Many of the habits that programmers have for naming, formatting, commenting and unit testing do not stand up as rational and practical on closer inspection. This talk examines seven coding habits that are not as effective as programmers believe, and suggests alternatives.
Atelier - Innover avec l’IA Générative et les graphes de connaissancesNeo4j
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Allez au-delà du battage médiatique autour de l’IA et découvrez des techniques pratiques pour utiliser l’IA de manière responsable à travers les données de votre organisation. Explorez comment utiliser les graphes de connaissances pour augmenter la précision, la transparence et la capacité d’explication dans les systèmes d’IA générative. Vous partirez avec une expérience pratique combinant les relations entre les données et les LLM pour apporter du contexte spécifique à votre domaine et améliorer votre raisonnement.
Amenez votre ordinateur portable et nous vous guiderons sur la mise en place de votre propre pile d’IA générative, en vous fournissant des exemples pratiques et codés pour démarrer en quelques minutes.
Enterprise Resource Planning System includes various modules that reduce any business's workload. Additionally, it organizes the workflows, which drives towards enhancing productivity. Here are a detailed explanation of the ERP modules. Going through the points will help you understand how the software is changing the work dynamics.
To know more details here: https://blogs.nyggs.com/nyggs/enterprise-resource-planning-erp-system-modules/
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...Crescat
Crescat is industry-trusted event management software, built by event professionals for event professionals. Founded in 2017, we have three key products tailored for the live event industry.
Crescat Event for concert promoters and event agencies. Crescat Venue for music venues, conference centers, wedding venues, concert halls and more. And Crescat Festival for festivals, conferences and complex events.
With a wide range of popular features such as event scheduling, shift management, volunteer and crew coordination, artist booking and much more, Crescat is designed for customisation and ease-of-use.
Over 125,000 events have been planned in Crescat and with hundreds of customers of all shapes and sizes, from boutique event agencies through to international concert promoters, Crescat is rigged for success. What's more, we highly value feedback from our users and we are constantly improving our software with updates, new features and improvements.
If you plan events, run a venue or produce festivals and you're looking for ways to make your life easier, then we have a solution for you. Try our software for free or schedule a no-obligation demo with one of our product specialists today at crescat.io
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxrickgrimesss22
Discover the essential features to incorporate in your Winzo clone app to boost business growth, enhance user engagement, and drive revenue. Learn how to create a compelling gaming experience that stands out in the competitive market.
OpenMetadata Community Meeting - 5th June 2024OpenMetadata
The OpenMetadata Community Meeting was held on June 5th, 2024. In this meeting, we discussed about the data quality capabilities that are integrated with the Incident Manager, providing a complete solution to handle your data observability needs. Watch the end-to-end demo of the data quality features.
* How to run your own data quality framework
* What is the performance impact of running data quality frameworks
* How to run the test cases in your own ETL pipelines
* How the Incident Manager is integrated
* Get notified with alerts when test cases fail
Watch the meeting recording here - https://www.youtube.com/watch?v=UbNOje0kf6E
Software Engineering, Software Consulting, Tech Lead, Spring Boot, Spring Cloud, Spring Core, Spring JDBC, Spring Transaction, Spring MVC, OpenShift Cloud Platform, Kafka, REST, SOAP, LLD & HLD.
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisGlobus
JASMIN is the UK’s high-performance data analysis platform for environmental science, operated by STFC on behalf of the UK Natural Environment Research Council (NERC). In addition to its role in hosting the CEDA Archive (NERC’s long-term repository for climate, atmospheric science & Earth observation data in the UK), JASMIN provides a collaborative platform to a community of around 2,000 scientists in the UK and beyond, providing nearly 400 environmental science projects with working space, compute resources and tools to facilitate their work. High-performance data transfer into and out of JASMIN has always been a key feature, with many scientists bringing model outputs from supercomputers elsewhere in the UK, to analyse against observational or other model data in the CEDA Archive. A growing number of JASMIN users are now realising the benefits of using the Globus service to provide reliable and efficient data movement and other tasks in this and other contexts. Further use cases involve long-distance (intercontinental) transfers to and from JASMIN, and collecting results from a mobile atmospheric radar system, pushing data to JASMIN via a lightweight Globus deployment. We provide details of how Globus fits into our current infrastructure, our experience of the recent migration to GCSv5.4, and of our interest in developing use of the wider ecosystem of Globus services for the benefit of our user community.
Unleash Unlimited Potential with One-Time Purchase
BoxLang is more than just a language; it's a community. By choosing a Visionary License, you're not just investing in your success, you're actively contributing to the ongoing development and support of BoxLang.
Navigating the Metaverse: A Journey into Virtual Evolution"Donna Lenk
Join us for an exploration of the Metaverse's evolution, where innovation meets imagination. Discover new dimensions of virtual events, engage with thought-provoking discussions, and witness the transformative power of digital realms."
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).
Essentials of Automations: The Art of Triggers and Actions in FMESafe Software
In this second installment of our Essentials of Automations webinar series, we’ll explore the landscape of triggers and actions, guiding you through the nuances of authoring and adapting workspaces for seamless automations. Gain an understanding of the full spectrum of triggers and actions available in FME, empowering you to enhance your workspaces for efficient automation.
We’ll kick things off by showcasing the most commonly used event-based triggers, introducing you to various automation workflows like manual triggers, schedules, directory watchers, and more. Plus, see how these elements play out in real scenarios.
Whether you’re tweaking your current setup or building from the ground up, this session will arm you with the tools and insights needed to transform your FME usage into a powerhouse of productivity. Join us to discover effective strategies that simplify complex processes, enhancing your productivity and transforming your data management practices with FME. Let’s turn complexity into clarity and make your workspaces work wonders!
Software Engineering, Software Consulting, Tech Lead.
Spring Boot, Spring Cloud, Spring Core, Spring JDBC, Spring Security,
Spring Transaction, Spring MVC,
Log4j, REST/SOAP WEB-SERVICES.
Top 7 Unique WhatsApp API Benefits | Saudi ArabiaYara Milbes
Discover the transformative power of the WhatsApp API in our latest SlideShare presentation, "Top 7 Unique WhatsApp API Benefits." In today's fast-paced digital era, effective communication is crucial for both personal and professional success. Whether you're a small business looking to enhance customer interactions or an individual seeking seamless communication with loved ones, the WhatsApp API offers robust capabilities that can significantly elevate your experience.
In this presentation, we delve into the top 7 distinctive benefits of the WhatsApp API, provided by the leading WhatsApp API service provider in Saudi Arabia. Learn how to streamline customer support, automate notifications, leverage rich media messaging, run scalable marketing campaigns, integrate secure payments, synchronize with CRM systems, and ensure enhanced security and privacy.
Globus Connect Server Deep Dive - GlobusWorld 2024Globus
We explore the Globus Connect Server (GCS) architecture and experiment with advanced configuration options and use cases. This content is targeted at system administrators who are familiar with GCS and currently operate—or are planning to operate—broader deployments at their institution.
How to Position Your Globus Data Portal for Success Ten Good PracticesGlobus
Science gateways allow science and engineering communities to access shared data, software, computing services, and instruments. Science gateways have gained a lot of traction in the last twenty years, as evidenced by projects such as the Science Gateways Community Institute (SGCI) and the Center of Excellence on Science Gateways (SGX3) in the US, The Australian Research Data Commons (ARDC) and its platforms in Australia, and the projects around Virtual Research Environments in Europe. A few mature frameworks have evolved with their different strengths and foci and have been taken up by a larger community such as the Globus Data Portal, Hubzero, Tapis, and Galaxy. However, even when gateways are built on successful frameworks, they continue to face the challenges of ongoing maintenance costs and how to meet the ever-expanding needs of the community they serve with enhanced features. It is not uncommon that gateways with compelling use cases are nonetheless unable to get past the prototype phase and become a full production service, or if they do, they don't survive more than a couple of years. While there is no guaranteed pathway to success, it seems likely that for any gateway there is a need for a strong community and/or solid funding streams to create and sustain its success. With over twenty years of examples to draw from, this presentation goes into detail for ten factors common to successful and enduring gateways that effectively serve as best practices for any new or developing gateway.
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/
10. enterprise, noun
a project or undertaking that is especially bold,
complicated or arduous
readiness to engage in undertakings of difficulty, risk,
danger or daring
a design of which the execution is attempted
a commercial or industrial undertaking
a firm, company or business
a unit of economic organisation or activity
Concise Oxford English Dictionary ∙ Oxford English Dictionary ∙ Merriam-Webster's Collegiate Dictionary
11. enterprise, noun
a project or undertaking that is especially bold,
complicated or arduous
readiness to engage in undertakings of difficulty, risk,
danger or daring
a design of which the execution is attempted
a commercial or industrial undertaking
a firm, company or business
a unit of economic organisation or activity
Concise Oxford English Dictionary ∙ Oxford English Dictionary ∙ Merriam-Webster's Collegiate Dictionary
12. code, noun
a set of instructions for a computer
a computer program, or a portion thereof
a system of words, figures or symbols used to
represent others, especially for the purposes of secrecy
a set of conventions or principles governing behaviour
or activity in a particular domain
Concise Oxford English Dictionary ∙ Oxford English Dictionary ∙ Merriam-Webster's Collegiate Dictionary
13.
14. Fizz buzz is a group word
game for children to teach
them about division.
http://en.wikipedia.org/wiki/Fizz_buzz
15. Players generally sit in a circle. The player
designated to go first says the number "1", and
each player thenceforth counts one number in
turn. However, any number divisible by three is
replaced by the word fizz and any divisible by five
by the word buzz. Numbers divisible by both
become fizz buzz. A player who hesitates or
makes a mistake is eliminated from the game.
http://en.wikipedia.org/wiki/Fizz_buzz
16. Players generally sit in a circle. The player
designated to go first says the number "1", and
each player thenceforth counts one number in
turn. However, any number divisible by three is
replaced by the word fizz and any divisible by five
by the word buzz. Numbers divisible by both
become fizz buzz. A player who hesitates or
makes a mistake is eliminated from the game.
http://en.wikipedia.org/wiki/Fizz_buzz
17. Players generally sit in a circle. The player
designated to go first says the number "1", and
each player thenceforth counts one number in
turn. However, any number divisible by three is
replaced by the word fizz and any divisible by five
by the word buzz. Numbers divisible by both
become fizz buzz. A player who hesitates or
makes a mistake is eliminated from the game.
http://en.wikipedia.org/wiki/Fizz_buzz
18. Adults may play Fizz buzz as a
drinking game, where making
a mistake leads to the player
having to make a drinking-
related forfeit.
http://en.wikipedia.org/wiki/Fizz_buzz
[citation needed]
19. Fizz buzz has been used as an
interview screening device for
computer programmers.
http://en.wikipedia.org/wiki/Fizz_buzz
20. FizzBuzz was invented to avoid
the awkwardness of realising
that nobody in the room can
binary search an array.
https://twitter.com/richardadalton/status/591534529086693376
21. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
22. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
23. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
24. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
25. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
26. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
27. // Define constants
#define FIZZ "fizz"
#define BUZZ "buzz"
#define NULL 0
#define PI 3.14
std::string FizzBuzzCalculator(int n)
{
// Declarations
char buffer[1024];
memset(buffer, 0, 1024);
std::string retval;
auto isDivisibleBy3 = [&]() { if (n % 3 == 0) { strcpy(buffer, FIZZ); return true; } return false; };
auto isDivisibleBy5 = [&]() { if (n % 5 == 0) { strcat(buffer, BUZZ); return true; } return false; };
// Check to see if argument is between 1 and 100, otherwise log and throw
if (n < 1 || n > 100)
{
sprintf(buffer, "FizzBuzzCalculator, argument must be in range: %i", n);
Log::Instance().Write(buffer);
throw std::invalid_argument(buffer);
}
// Check if need to write number
if (!isDivisibleBy3() & !isDivisibleBy5())
{
sprintf(buffer, "%i", n);
}
// Assign return value (retval) and return
retval.assign(buffer, strlen(buffer));
return retval;
}
28. I have yet to see any problem,
however complicated, which,
when you looked at it in the
right way, did not become still
more complicated.
Anderson's Law
40. string fizzbuzz(int n)
{
auto test =
[=](int d, string s, function<string(string)> f)
{
return
n % d == 0
? [=](string) { return s + f(""); }
: f;
};
auto fizz = bind(test, 3, "Fizz", _1);
auto buzz = bind(test, 5, "Buzz", _1);
auto id = [](auto s) { return s; };
return fizz(buzz(id))(to_string(n));
}
41. A work of art is the
unique result of a
unique temperament.
Oscar Wilde
42. Cargo cult programming is a style of computer
programming characterized by the ritual inclusion of
code or program structures that serve no real purpose.
http://en.wikipedia.org/wiki/Cargo_cult_programming
43. Signal-to-noise ratio (often abbreviated SNR or
S/N) is a measure used in science and engineering
that compares the level of a desired signal to the
level of background noise.
Signal-to-noise ratio is sometimes used informally
to refer to the ratio of useful information to false or
irrelevant data in a conversation or exchange.
http://en.wikipedia.org/wiki/Signal_to_noise_ratio
45. A common fallacy is to assume authors
of incomprehensible code will somehow
be able to express themselves lucidly
and clearly in comments.
Kevlin Henney
https://twitter.com/KevlinHenney/status/381021802941906944
46. Cargo cult programming is a style of computer
programming characterized by the ritual inclusion of
code or program structures that serve no real purpose.
Cargo cult programming can also refer to the results of
applying a design pattern or coding style blindly
without understanding the reasons behind that design
principle.
http://en.wikipedia.org/wiki/Cargo_cult_programming
52. People will be using the words
you choose in their conversation
for the next 20 years. You want
to be sure you do it right.
Unfortunately, many people get
all formal [...]. Just calling it what
it is isn't enough.
53. They have to tack on a flowery,
computer science-y, impressive
sounding, but ultimately
meaningless word, like Object,
Thing, Component, Part,
Manager, Entity, or Item.
58. Refactoring (noun): a change made to
the internal structure of software to
make it easier to understand and
cheaper to modify without changing
its observable behavior.
Refactor (verb): to restructure
software by applying a series of
refactorings without changing the
observable behavior of the software.
61. Connection * CreateServerConnection()
{
// Declarations
char buffer[1024];
std::string cfgAddress;
unsigned long address;
std::string cfgPort;
unsigned short port;
Connection * result;
// Get address and check that its OK (throw an exception if its not)
cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
{
sprintf(buffer, "Configuration value missing: %s", "address");
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
// Convert adress to bytes and check that its OK (throw an exception if its not)
address = inet_addr(cfgAddress.data());
if (address == -1)
{
sprintf(buffer, "Invalid address: %s", cfgAddress.data());
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
// Get port and check that its OK (throw an exception if its not)
cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
{
sprintf(buffer, "Configuration value missing: %s", "port");
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
// Convert port too bytes
port = htons(atoi(cfgPort.data()));
// Creation connection and check that its OK (throw an exception if its not)
result = new Connection(address, port);
if (!result || !result->IsOK())
{
sprintf(buffer, "Failed to connect: %s:%s", cfgAddress.data(), cfgPort.data());
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
// Return the connection
return result;
}
63. Connection * CreateServerConnection()
{
...
// Get address and check that its OK (throw an exception if its not)
cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
{
sprintf(buffer, "Configuration value missing: %s", "address");
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
...
}
64. Connection * CreateServerConnection()
{
...
// Convert adress to bytes and check that its OK (throw an exception if its not)
address = inet_addr(cfgAddress.data());
if (address == -1)
{
sprintf(buffer, "Invalid address: %s", cfgAddress.data());
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
...
}
65. Connection * CreateServerConnection()
{
...
// Get port and check that its OK (throw an exception if its not)
cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
{
sprintf(buffer, "Configuration value missing: %s", "port");
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
...
}
67. Connection * CreateServerConnection()
{
...
// Creation connection and check that its OK (throw an exception if its not)
result = new Connection(address, port);
if (!result || !result->IsOK())
{
sprintf(buffer, "Failed to connect: %s:%s", cfgAddress.data(), cfgPort.data());
Log::Instance().Write(buffer);
throw ConnectionException(buffer);
}
...
}
69. Connection * CreateServerConnection()
{
// Declarations
...
// Get address and check that its OK (throw an exception if its not)
...
// Convert adress to bytes and check that its OK (throw an exception if its not)
...
// Get port and check that its OK (throw an exception if its not)
...
// Convert port too bytes
...
// Creation connection and check that its OK (throw an exception if its not)
...
// Return the connection
...
}
70. Connection * CreateServerConnection()
{
// Declarations
...
// Get address and check that it's OK (throw an exception if it's not)
...
// Convert address to bytes and check that it's OK (throw an exception if it's not)
...
// Get port and check that it's OK (throw an exception if it's not)
...
// Convert port to bytes
...
// Creation connection and check that it's OK (throw an exception if it's not)
...
// Return the connection
...
}
89. Connection * CreateServerConnection()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
{
static const char * logMessage = "Configuration value missing: address";
Log::Instance().Write(logMessage);
throw ConnectionException(logMessage);
}
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
{
auto logMessage = "Invalid address: " + cfgAddress;
Log::Instance().Write(logMessage);
throw ConnectionException(logMessage);
}
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
{
static const char * logMessage = "Configuration value missing: port");
Log::Instance().Write(logMessage);
throw ConnectionException(logMessage);
}
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
{
auto logMessage = "Failed to connect: " + cfgAddress + ":" + cfgPort;
Log::Instance().Write(logMessage);
throw ConnectionException(logMessage);
}
return result.release();
}
90. Connection * CreateServerConnection()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
{
FailedToConnect("Configuration value missing: address");
}
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
{
FailedToConnect("Invalid address: " + cfgAddress);
}
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
{
FailedToConnect("Configuration value missing: port");
}
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
{
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
}
return result.release();
}
91. Connection * CreateServerConnection()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result.release();
}
92. Connection * CreateServerConnection()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result.release();
}
93. Connection * CreateServerConnection()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result.release();
}
94. std::unique_ptr<Connection> CreateServerConnection()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result;
}
95. std::unique_ptr<Connection> ConnectToServer()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result;
}
96. std::unique_ptr<Connection> ConnectToServer()
{
auto cfgAddress = ConfigurationManager::Instance().GetValue("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().GetValue("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result;
}
97. std::unique_ptr<Connection> ConnectToServer()
{
auto cfgAddress = ConfigurationManager::Instance().ValueOf("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = ConfigurationManager::Instance().ValueOf("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result;
}
98. std::unique_ptr<Connection> ConnectToServer()
{
auto cfgAddress = Configuration::Instance().ValueOf("address");
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
auto cfgPort = Configuration::Instance().ValueOf("port");
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result;
}
99. std::unique_ptr<Connection> ConnectToServer(
const std::string & cfgAddress, const std::string & cfgPort)
{
if (cfgAddress.empty())
FailedToConnect("Configuration value missing: address");
auto address = inet_addr(cfgAddress.c_str());
if (address == -1)
FailedToConnect("Invalid address: " + cfgAddress);
if (cfgPort.empty())
FailedToConnect("Configuration value missing: port");
auto port = htons(stoi(cfgPort));
auto result = std::make_unique<Connection>(address, port);
if (!result->IsOK())
FailedToConnect("Failed to connect: " + cfgAddress + ":" + cfgPort);
return result;
}