2013-11-24

2013-11-24 Sunday - Book Review: Python In Practice



My Book Review:

 I recently had an opportunity to read Python in Practice, by Mark Summerfield as a reviewer for Pearson Education.

Two noteworthy points:
- The code samples are based on Python 3.x
- The author's web site provides sample code download


The very first thing I noticed about this book is that the sample bits of code are very concise - without extraneous fluff.

This book is an excellent addition to any software craftsman's library that needs a quick dive into practical hands-on Python coding.  Each page has a feeling of being written from the perspective of someone who has lived in the trenches producing production-quality python code for over a decade. This book has the feeling of a friendly mentor's guiding hand.

To help you understand the impression that this book left in my mind, let me share another word that arose unbidden in my mind as I made my way through the pages of this book: In Japanese, the phrase "Sensei" is often translated as "teacher", but also has a literal meaning of "One Who Has Gone Before". Mark's transmission of his depth of experience to the printed word is given in that same spirit of a Sensei teaching lessons gleaned from years of practice.

Another unexpected pleasure discovered within the pages of Mark's book: An emphasis on patterns. The first three chapters provide an excellent overview of the python-esque approach to implementing the various patterns that were described in the book Design Patterns: Elements of Reusable Object-Oriented Software.

I also found Chapter 5. Extending Python to be very interesting for focusing the discussion on Python's ctypes and Cython - techniques which are often needed to solve high performance problems.

One minor criticism is the author's choice in focusing on XML-RPC style in Chapter 6. High Level Networking [versus RESTful web service based integration strategies]


Chapter 1. Creational Design Patterns
1.1 Abstract Factory Pattern
1.2 Builder Pattern
1.3 Factory Method Pattern
1.4 Prototype Method Pattern
1.5 Singleton Pattern
Chapter 2. Structural Design Patterns
2.1 Adapter Pattern
2.2 Bridge Pattern
2.3 Composite Pattern
2.4 Decorator Pattern
2.5 Facade Pattern
2.6 Flyweight Pattern
2.7 Prox Pattern
Chapter 3. Behavioral Design Patterns
3.1 Chain of Responsibility Pattern
3.2 Command Pattern
3.3. Interpreter Pattern
3.4 Iterator Pattern
3.5 Mediator Pattern
3.6 Memento Pattern
3.7 Observer Pattern
3.8 State Pattern
3.9 Strategy Pattern
3.10 Template Method Pattern
3.11 Visitor Pattern
3.12 Case Study: An Image Package
Chapter 4. High-Level Concurrency
4.1 CPU-Bound Concurrency
4.2 I/O Bound Concurrency
4.3 Case Study: A Concurrent GUI Application
Chapter 5. Extending Python
5.1 Accessing C Libraries with ctypes
5.2 Using Cython
5.3 Case Study: An Accelerated Image Package
Chapter 6. High-Level Networking
6.1 Writing XML-RPC Applications
6.2 Writing RPyC Applications
Chapter 7. Graphical User Interfaces with Tkinter
7.1 Introduction to Tkinter
7.2 Creating Diaglogs with Tkinter
7.3 Creating Main-Window Applications with TKinter
Chapter 8. OpenGL 3D Graphics
8.1 A Perspective Scene
8.2 An Orthographic Game





2013-11-21

2013-11-21 Thursday - XML/XSD validation in Python and Installing PIP (Python Package Manager)

I'm working on developing a small utility to help automate the documentation and generation of some Enterprise Integration Architecture Context Diagrams from various spreadsheets that list the inventory of different systems and their integration (transforming the data into an XML canonical form, and then using that canonical form as the basis for generating graphviz .dot files).  This way, I will have a reusable tool that can be used across multiple projects - and simply either ask for the data in the canonical form - or limit my future effort to just getting it into the canonical form.

So I found myself needing to incorporate a few 3rd party Python packages into my solution, so I decided to spend some time this evening to finally install a decent package manager in my development environment.

First, install setuptools
https://pypi.python.org/pypi/setuptools#using-setuptools-and-easyinstall


https://pypi.python.org/pypi/pip
http://www.pip-installer.org/en/latest/installing.html

http://stackoverflow.com/questions/4750806/how-to-install-pip-on-windows

http://dubroy.com/blog/so-you-want-to-install-a-python-package/

Unofficial Windows Binaries for Python Extension Packages
http://www.lfd.uci.edu/~gohlke/pythonlibs/

http://dubroy.com/blog/so-you-want-to-install-a-python-package/



My original need was to install a package to help develop some code that requires XSD/XML manipulation.

Initially, I thought would be a good fit for my need - but the pip install process seems have some issues (at least in my environment)
http://lxml.de/installation.html
http://lxml.de/validation.html#xmlschema
http://stackoverflow.com/questions/17819884/xml-xsd-feed-validation-against-a-schema
http://code.activestate.com/recipes/578503-validate-xml-with-schemalocation/

A second possible package for consideration (although it doesn't appear to have any development since 2006...):
https://pypi.python.org/pypi/pyxsd

The xlrd package provides support for reading Excel spreadsheets:
https://pypi.python.org/pypi/xlrd
http://www.python-excel.org/ 

2013-11-07

2013-11-07 Thursday - Suggested SOA reading list

A colleague recently asked what resources I might recommend for them to begin learning about SOA (he's recently been dropped into a large enterprise organization that has a complex existing SOA environment)

Here's the reading list I prepared...

First, check InfoQ for articles and conference presentations:
http://www.infoq.com/soa/

Next, check YouTube for recent videos:
http://www.youtube.com/results?filters=year&search_query=service+oriented+architecture+soa&lclk=year


There are 10 IBM SOA Tutorials linked to here:

TechTarget.com has some

This author’s tutorials may be of interest
http://tutorials.jenkov.com/soa/index.html


The best resource for quickly getting up to speed (with a holistic and comprehensive approach) would be to read Jim Bean’s book:
(there is a kindle version available too)

Next, I would direct to you read anything on the web that is SOA-focused by Arnon Rotem-Gal-Oz, as well as his book:
(he is one of the most clear-headed people when it comes to real-world, practical SOA.

Thomas Erl is one of my favorite writers on SOA – because he is meticulous in building a body of knowledge (some might criticize his writing for be repetitive, but I see it as reinforcing the concepts)

I would start with his SOA Design patterns book:

And perhaps then his SOA with REST: Principles, Patterns & Constraints for Building Enterprise Solutions with REST

If you think you still need more foundational information, then go back to his  Service Oriented Architect: Concepts, Technology, and Design

Or his SOA: Principles of Service Design

His most recent book, which I reviewed for Prentice Hall, is also worth reading: Cloud Computing: Concepts, Technology & Architecture

For a more technical deep dive discussion of SOA service contract versioning:


I also reviewed Robert Daigneau’s book: Service Design Patterns: Fundamental Design Solutions for SOAP/WSDL and RESTful Web Services, which has a very light touch on RESTful service – but has some concise writing on service design patterns that may be of interest
http://www.amazon.com/Service-Design-Patterns-Fundamental-Solutions/dp/032154420X/

2013-09-25

2013-09-25 Wednesday - Tooling to Support Continuous Deployment

This posting is a placeholder for resources links and notes about tooling that I find interesting to support DevOps in the challenges of Configuration Management and [Continuous?] Deployment.

For some somewhat agnostic overviews of tooling and processes that can support continuous deployment  in practice...these presentations may be of interest:


While many companies have stringent regulatory constraints that require more thoughtful and methodical approaches to deployment, I thought it worth noting how Etsy.com implemented a RADICAL (!) DevOps culture - as an inspiring example to challenge status quo thinking of "but-that's-not-the-way-we-do-things-here..."

A Wikipedia article - providing a sparse summary/survey of some open source solutions for automated deployment tooling...

There is a great deal of fast-paced innovation in the tooling space for deployment & configuration management – here are some of the tools (slightly listed in order of what I find to be interesting and innovative)…


Microsoft System Center 2012

Less sophisticated, but perhaps a good example of how some shops can still make improvements over manual processes...even if it is just by doing things with bare-bones scripting…for example, via Rex

2013-09-17

2013-09-17 Tuesday - ZeroMQ


Recently, while researching some distributed computing integration patterns, I happened to come across an interesting paper: Middleware Trends and Market Leaders 2011 - produced by researchers at the CERN facility in Switzerland - that cited ZeroMQ.org as a leader.

Ilya Grigorik posted a nice write-up on ZeroMQ back in September 2010
http://www.igvita.com/2010/09/03/zeromq-modern-fast-networking-stack/

WordCount

Copyright

© 2001-2026 International Technology Ventures, Inc., All Rights Reserved.