Share E-Book
Scan to open this page

Scan with your phone to open this page

Author: Stephen Morris

Rating No ratings yet

As legacy and other critical systems continue to migrate online, the need for continuous operation is imperative. Code has to handle data issues as well as hard external problems today, including outages of networks, storage systems, power, and ancillary systems. This practical guide provides system administrators, DevSecOps engineers, and cloud architects with a concise yet comprehensive overview on how to use PL/SQL to develop resilient database solutions. Integration specialist Stephen B Morris helps you understand the language, build a PL/SQL toolkit, and collect a suite of reusable components and patterns. You'll dive into the benefits of synthesizing the toolkit with a requirements-driven, feature-oriented approach and learn how to produce resilient solutions by synthesizing the PL/SQL toolkit in conjunction with a scale of resilience. • Build solid PL/SQL solutions while avoiding common PL/SQL antipatterns • Learn why embedding complex business logic in SQL is often a brittle proposition • Learn how to recognize and improve weak PL/SQL code • Verify PL/SQL code by running data-driven, in-database tests • Understand the safe operation, maintenance, and modification of complex PL/SQL systems • Learn the benefits of thinking about features rather than just use cases • Define good requirements for PL/SQL and hybrid solutions involving PL/SQL and high level languages

AI Reading Assistant

Whole-book reading guide from stratified index samples; jump to passages in the text

AI guide
【One-Line Pitch】 A practical field guide to writing Oracle PL/SQL that survives real-world chaos—outages, bad data, and legacy integration—by building a reusable toolkit and scoring your code against an empirical "scale of resilience." Best for DBAs, DevSecOps engineers, and architects who own database logic that must keep running. 【Book Arc】 - **Opening (~0%–10%)**: Frames the core problem—continuous operation under network, storage, power, and ancillary failures—and introduces the book's central device: an empirical scale of resilience for numerically grading PL/SQL blocks. - **Early (~10%–30%)**: Grounds you in the language and environment: reading unfamiliar/legacy PL/SQL, why database logic belongs in the database rather than an ORM layer, and standing up a containerized Oracle instance with SQL Developer. - **Middle (~30%–55%)**: Moves into engineering discipline—version-controlling all schema and PL/SQL artifacts so a database can be rebuilt from scratch, and the first scale requirements such as capturing every error and exception. - **Late (~55%–85%)**: Builds the reusable toolkit and patterns, applies the scale iteratively to refactor weak code, and covers data-driven, in-database testing plus hybrid PL/SQL–Java integration (e.g., invoking procedures from Java). - **Ending (~85%–100%)**: Consolidates takeaways—avoiding egregious antipatterns, treating errors as teachers, reading code critically, and thinking in features rather than use cases. 【Key Takeaways】 - **Resilience is measurable, not aspirational** (Early): the scale of resilience turns vague "good code" talk into numeric scores you can iterate against during refactoring. - **Keep database logic in the database** (Early): PL/SQL offers security, performance, encapsulation, and far better exception handling than pushing logic into high-level-language persistence layers. - **ORM and driver-specific shortcuts create brittle coupling** (Early): tying application code to a particular database driver version means a routine security upgrade can break your app. - **Version-control every artifact, including views and schema scripts** (Middle): if both active and backup databases are lost, only a complete script set lets you rebuild—"unlikely" is not "never." - **Capture all errors and exceptions** (Middle): this is framed as the first requirement of the scale; suppressing or over-broadly swallowing errors undermines resilience. - **Complex business logic embedded in SQL is often brittle** (Late): the book argues for PL/SQL as the safer home for such logic. - **Test inside the database, driven by data** (Late): in-database, data-driven tests verify PL/SQL where it actually runs. - **Think in features, not just use cases** (Late): features act as coarse-grained placeholders that shape better requirements for PL/SQL and hybrid solutions. 【Reading Tips】 - Deep-read the opening chapters on the scale of resilience—it's the lens for everything after; skim the Docker/installation walkthrough if you already have an Oracle instance. - Treat the code examples as refactoring exercises: score them yourself before reading the author's assessment. - Pay closest attention to the exception-handling and version-control chapters; these carry the most transferable operational value. - If you're a Java/high-level-language developer, focus on the integration chapters to understand where the PL/SQL boundary should sit. 【Coverage Limits】 These excerpts are heavily weighted toward the front matter, table of contents, and early chapters; the later toolkit, testing, and Java-integration material is only partially represented, so specifics there are inferred from headings and blurbs rather than fully covered.
Page 11
oice Creation PL/SQL Procedure 199 Run the Draft PL/SQL Code First in SQL Developer 201 Insert a Row in the INVOICES Table 202 Add Two Helpers 204 Performanc...
View in text
Excerpt 2
to me that, aside from the unnecessary complexity and inte‐ gration effort, the finished code was then tied to that particular version of the data‐ base driv...
View in text
Excerpt 3
for the container registry login page in Figure 2-3. If the login succeeds, then copy the docker pull command from the Pull Command for Latest section in the...
View in text
Excerpt 4
ve not opted to move their data infrastructure to the cloud. So, all actions (updates, deletes, etc.) made against the active database instance are automati‐...
View in text
Excerpt 5
ice (or helper) procedure with the name updateEmployeeData. The main procedure (update_employees) handles any exceptions as well. So, if the service procedur...
View in text
Excerpt 6
ION (action_message IN logging.action_message%TYPE, code_location IN logging.code_location%TYPE) To provide parameters for the procedure call, click the Job...
View in text
Excerpt 7
r in update_employees is the packaged LOG_ACTION procedure. By looking at the PL/SQL code in this way, it becomes possible to break it into its constituent f...
View in text
Excerpt 8
n, the invoice is a business artifact. An invoice is just a financial record of work done for a given client on a specific project. The invoice might be sent...
View in text
Tags
AI categories
DatabaseSQLSoftware
ISBN: 1098134117
Publisher: O'Reilly Media
Publish Year: 2023
Language: English
Pages: 308
File Format: PDF
File Size: 9.9 MB
Text Preview (First 20 pages)
Registered users can read the full content for free

Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.

Generating text preview…