Stefano Tommesani

  • Increase font size
  • Default font size
  • Decrease font size

Using Amazon SimpleDB from Delphi

E-mail Print PDF

 

Table of contents 1 - Introduction to Amazon SimpleDB 2 - SimpleDB and Delphi 3 - Extending Data.Cloud.AmazonAPI

Download_32 Download SimpleDBExplorer project files and executable

Introduction to Amazon SimpleDB

The best description of the Amazon SimpleDB service is given by Amazon itself here:

Amazon SimpleDB is a highly available and flexible non-relational data store that offloads the work of database administration. Developers simply store and query data items via web services requests and Amazon SimpleDB does the rest. Unbound by the strict requirements of a relational database, Amazon SimpleDB is optimized to provide high availability and flexibility, with little or no administrative burden. Behind the scenes, Amazon SimpleDB creates and manages multiple geographically distributed replicas of your data automatically to enable high availability and data durability. The service charges you only for the resources actually consumed in storing your data and serving your requests. You can change your data model on the fly, and data is automatically indexed for you. With Amazon SimpleDB, you can focus on application development without worrying about infrastructure provisioning, high availability, software maintenance, schema and index management, or performance tuning.

Amazon stresses that SimpleDB is optimized for high availability, thaks to distributed replicas of data, and low administrative costs, as there are no schemas and indexes to manage. With SimpleDB, you don't have to define a schema for each database table before you can use it, and you don't have to change that schema before storing your data in a different way. As there is no schema, there are no data types, as all data values are treated as variable length char data. So, if you want to add a new field to an existing database, you just data the new field to the data items that require it, and there is no enforcing that all data items contains the same fields. The drawback of having no schema is that you have to handle formatting and type conversions in your code, and this has a serious impact on queries.

The terminology used in SimpleDB is different from the usual DBMS one, so the following table shows how the different terms are related:

DBMS Amazon SimpleDB
table domain
row item
column attribute

The domain is analogous to a database table, but a domain has no schema, so the only parameter you can set is the name of the domain. All the data stored in a domain has the form of name-value attribute pairs, and each attributes pair belongs to an item, which is similar to a table row. The attribute name is similar to a table column, but each item can have different attribute names, so you can store data with different layouts in the same domain, and add new fields to items without restructuring the table. It is also possible to have, for a given attribute, not just one value, but an array of values, so when you add an attribute name-value pair to an item, you can choose if SimpleDB should replace the existing pair with the same attribute pair, or add the new value to the existing pair.

Queries on SimpleDB are mostly done with a key-value approach, where you retrieve an item and its attributes from the item's name. But you can also use a SQL-style query language to issue queries over the scope of a single domain. When designing queries, you should be aware that all the data stored in SimpleDB is treated as plain string data (be careful with numerical data!), and that all values are automatically indexed.

Last Updated on Friday, 27 July 2012 11:12
 

AltaCdCover - convert CD covers

E-mail Print PDF

AltaCdCoverQuickly convert a digipak CD cover into a traditional jewel-box CD back cover!

Just drop the CD cover to convert into the source area, AltaCdCover will automatically recognize if it contains both front and back sides or only the back side, drop the front side if found, and reconstruct the missing spine, finally adjust the resulting image's aspect ratio so that it matches that of jewel-box back covers, without requiring any action from you! Optionally, you can adjust for non-standard spine sizes using the slider on the toolbar.

You can download the latest version of AltaCdCover from the Download section of the site.

Last Updated on Saturday, 01 June 2013 15:19
 

AltaPixShare - free image optimization and sharing

E-mail Print PDF

AltaPixShare0

DownloadSmallYou're having a chat on Skype with a friend of yours, talking about your last holiday, and then you want to send him some pictures. Your new 16 megapixel camera takes amazing pictures, so you drop them in the chat window, and... it takes forever to send them! In fact, each photo is bigger than 6 megabytes, so sending just 20 pictures requires more than 100 megabytes of bandwidth usage. And your friend is just watching those photos on a PC screen, which has a 1 to 2 megapixel resolution, so nearly 90% of the transferred resolution is wasted.

So a simple solution would be opening each picture in an image editor, rescaling it, saving it with a different name and, finally, dropping the new file to the chat window. Boring for just an image, do you really want to repeat it for each picture?

Luckily, there's a simpler, quicker and free solution, AltaPixShare! Just drop the pictures in the app, choose the rescaling factor with a single mouse click, and optionally apply an image effect, then drop them all to the chat window with a single mouse gesture.

Last Updated on Friday, 09 August 2013 20:14
 

AltaLux in XnView

E-mail Print PDF

The AltaLux image enhancement filter is now available in the popular XnView image viewer!

Now you can enjoy AltaLux technology inside an advanced image viewer and editor, so trying how AltaLux can effectively enhance your photos is just a click away while you keep using your favourite image viewer.

AltaLuxXnView1

Last Updated on Friday, 14 October 2011 12:27
 

AltaSonita - image denoising software

E-mail Print PDF

AltaSonita is an image denoising application built to run on nVidia video boards using CUDA technology. Three different denoising algorithms, and five intensity levels let you remove most of noise from photos without blurring small details and edges.

AltaSonita is provided as free software, and you can download it from here. Please note that AltaSonita requires a CUDA-enabled video board, that is a recent nVidia video board; it will not run on any other video board.

As the following images show, the intensity setting works by separating edgy areas (drawn in red) from mostly plain areas (drawn in blue), and in plain areas the amount of noise filtering is higher as there are no relevant edges that would be blurred by the denoising process. Increasing the intensity setting reduces the amount of edge-preserving areas, so that aggressive noise filtering is applied to more zones of the image.

NLM0
Original image
KNNmin
KNNminstat
KNN filter with min intensity Edges (drawn in red) of KNN filter with min intensity
KNNmax
KNNmaxstat

KNN filter with max intensity Edges (drawn in red) of KNN filter with max intensity
NLMmin
NLMminstat
NLM filter with min intensity Edges (drawn in red) of NLM filter with min intensity
NLMmax
NLMmaxstat

NLM filter with max intensity Edges (drawn in red) of NLM filter with max intensity
Last Updated on Thursday, 14 July 2011 09:57
 

Quexal MMX goes freeware

E-mail Print PDF

Back in 2000, Quexal changed the way programmers had to deal with MMX programming. A friendly user interface simplified building parallel versions of algorithms, an optimizing compiler made sure that the resulting code would run fast, and a visual debugger helped pinpoint programming errors.

Even if the focus of the programming community has moved on to more recent instructions sets, after many years I still get queries about Quexal, so I've decided to release it as freeware, as it may be useful for learning SIMD coding. However, simply releasing the last published version of Quexal was not enough, and this was an opportunity to spend some time on this pet project of mine and improve it.

So here you have it, an updated version of Quexal for free! Just go to the download section to get it.

QuexalScreenShot

Last Updated on Saturday, 01 June 2013 15:20
 


Page 8 of 9
View Stefano Tommesani's profile on LinkedIn

Latest Articles

Necessary evil: testing private methods 29 January 2017, 21.41 Testing
Necessary evil: testing private methods
Some might say that testing private methods should be avoided because it means not testing the contract, that is the interface implemented by the class, but the internal implementation of the class itself. Still, not all
I am right and you are wrong 28 December 2016, 14.23 Web
I am right and you are wrong
Have you ever convinced anyone that disagreed with you about a deeply held belief? Better yet, have you changed your mind lately on an important topic after discussing with someone else that did not share your point of
How Commercial Insight changes R&D 06 November 2016, 01.21 Web
How Commercial Insight changes R&D
The CEB's Commercial Insight is based on three pillars: Be credible/relevant – Demonstrate an understanding of the customer’s world, substantiating claims with real-world evidence. Be frame-breaking – Disrupt the
Windows Forms smells funny, but... 07 April 2016, 15.38 Software
Windows Forms smells funny, but...
In the "2016 .NET Community Report" just released by Telerik, the answers to the question "What technology would you choose if building for Windows Desktop?" were as follows: So roughly half of new desktop developments would
Say goodbye to
It is not easy to monitor how our code behaves on a vast array of different machines. A myriad of different configurations can lead to errors that are difficult to reproduce and even more difficult to anticipate. And when the

Translate