May 30

PHP ZipCode to TimeZone

I have been building a database of customers to call and found one slight issue, I needed to be able to workout which timezone each of the contacts are in so I only call when its suitable for them!

I started off by using one of the online ZipCode to TimeZone converters and manually adding the data to the existing database, but soon ran into difficulties because the websites limit the number of requests that could be run (Its cookie based so while I could probably have worked round it I needed a better solution). I also looked at using the telephone area code in the database and the various online converters which provide the TimeZone based on it, again after a number of requests the pages stopped working.

Having to cut and paste the Zipcode between the pages was also very painful, I wanted something I could just program and run. There are a number of API’s out there that will allow you to run requests against web pages and receive XML data back. These tended to return data which needed more massaging and required conversion of XML structures to allow the database to be updated.

I wanted to have a database of ZipCodes which had the Timezones included, I found one at the following link. I did find others but this one appeared to have been updated more recently. I started by importing the sql into a new MySQL database called ziptotz. On reviewing the data I found that the TimeZone was in a format such as ‘America/Alaska’. I needed to take this data and work out the time offset.

My solution was to simply add a new field to the end of each row which would hold the offset from GMT, I could have made it simpler by determining the offset of my current timezone from GMT and subtracting it from the result but the data would then be location specific so I decided offset from GMT would work just fine.

This is the script I used to add the new values.


// connect to the server
$con = mysql_connect("my_host","my_user","my_pwd");
if (!$con) {
die('Could not connect: ' . mysql_error());
}
// select the database
mysql_select_db("ziptotz",$con);
// list the timezones supported by PHP for the US only
$timeZones = DateTimeZone::listIdentifiers(DateTimeZone::PER_COUNTRY, 'US');
// loop through the returned array
foreach ($timeZones as $key => $zoneName ) {
// create a timezone object
$tz = new DateTimeZone($zoneName);
// create a new datetime object using the timezone object time is current
$dateTime = new DateTime("now",$tz);
// create the offset char string
$timeoffset = date_format($dateTime, 'P');
// add the offset to the list of zipcodes
$query = "UPDATE timezonebyzipcode SET offset_gmt = '" .$timeoffset ."' WHERE timezone = '" .$zoneName ."'";
$result = mysql_query($query);
if (!$result) {
$message = 'Invalid query: ' . mysql_error() . "\n";
$message .= 'Whole query: ' . $query;
die($message);
}
}
// close the server connection
mysql_close($con);

Now I have a full list of ZipCodes with the gmt offset stored in a database table. Now I can use the data in this new table to add a new field to the contact database which will show the time offset allowing me to know when I should be able to call without waking them at 5AM in the morning.

Have fun..

Chris..

Sep 22

LinkedIn group formed for EASYCOM for PHP.


We have started a group for EASYCOM for PHP on LinkedIn. If you are interested in getting involved or have some questions about EASYCOM for PHP it is a place to visit. We are hoping to increase the awareness of the product and its capabilities plus engage others in discussing coding issues around the IBM i PHP environment.

If you are using LinkedIn or just want to get involved take a look and post your questions etc. We hope to make the group a lively and engaging place for people to discuss EASYCOM for PHP and the IBM i.

Chris…

Sep 07

New XMLService is not what I expected.

As posted in the previous post I was setting up the Zend Server on our V6R1 system to give the new XMLSERVICE a try to see if the program calls would be faster using it rather than the old i5_toolkit API’s. Unfortunately we had to abandon the V6R1 install due to a number of problems with the install of the XMLSERVICE and the NewToolkit install. After 5 hours of installing and configuring trying to get things running we were ready to give up.

However we decided to give it a go on the V7R1 system as it did seem to compile the RPG XMLSERVICE programs etc OK. We installed the latest download of the ZendServer but did not install the update Cum package. This seems to have resolved our initial problem with the XMLSERVICE requests which ended in error when calling the Db2supp.php script? But that might be a total co-incidence.

Once we had everything installed we connected all of our old web configurations back up and started the main webserver (we have 5 virtualhosts running below the main webserver) to begin testing the setup. As far as the main PHP services went everything seemed to be running OK so we decide to set up the XMLSERVICE.

First program we compiled CRTXML worked perfectly and the XMLSERVICE programs all created correctly. However as we wanted to use the ZENDSVR install we then tried to run the CRTXML2 program, this ended with an error creating the XMLSERVICE program due to some missing definitions. A quick compare of the 2 programs showed the CRTXML2 program did not create or embed the PLUDB2 or PLUGSQL modules in the service programs. We amended the program and re-created it and then everything worked as it should.

Next we had to link the NewToolkit directory to the web server we were going to use and add the relevant configs to make sure we could use the symbolic links we created to the directory.

The XMLSERVICE is started the first time it is called according to the documentation but to be honest its a bit sparse and not easily understood when this is the first time you go to use it. I am not an expert in the product but I did get it working so it can’t be that bad. So all we had to do was create a couple of scripts to test things out.

A program is shipped in the NewToolkit library which can be compiled and used for the tests. It is called ZZCALL and is an RPG program that takes a few parameters and just adds some values to them. I am not an RPG expert as I have said all along, but the program is pretty simple which is all we needed for the test.

The next thing we needed is the scripts which will call the program and capture time information as they run.

First program calls the RPG program sending in new parameters each time.


<?php
/*
RPG program parameters definition
INCHARA S 1a
INCHARB S 1a
INDEC1 S 7p 4
INDEC2 S 12p 2
INDS1 DS
DSCHARA 1a
DSCHARB 1a
DSDEC1 7p 4
DSDEC2 12p 2
*/
include_once 'authorization.php';
include_once '../API/ToolkitService.php';
include_once 'helpshow.php';

$loop = 5000;

$start_time = microtime();
echo "New Zend Toolkit. Input value is changing on each call.<br><br>";

try {
$ToolkitServiceObj = ToolkitService::getInstance($db, $user, $pass);
}
catch (Exception $e) {
echo $e->getMessage(), "\n";
exit();
}

$ToolkitServiceObj->setToolkitServiceParams(array('InternalKey'=>"/tmp/$user"));

$IOParam['var1'] = array("in"=>"Y", "out"=>"" );
$param[] = $ToolkitServiceObj->AddParameterChar('both', 1,'INCHARA', 'var1', $IOParam['var1']['in']);

$IOParam['var2'] = array( "in"=>"Z", "out"=>"" );
$param[] = $ToolkitServiceObj->AddParameterChar('both', 1,'INCHARB', 'var2', $IOParam['var2']['in']);

$IOParam['var3'] = array( "in"=>"001.0001" ,"out"=>"");
$param[] = $ToolkitServiceObj->AddParameterPackDec('both', 7, 4, 'INDEC1', 'var3', '001.0001');

$IOParam['var4'] = array( "in"=>"0000000003.04","out"=>"" );
$param[] = $ToolkitServiceObj->AddParameterPackDec('both',12,2,'INDEC2', 'var4', '0000000003.04');

$IOParam['ds1'] = array( "in"=>"A" ,"out"=>"");
$ds[] = $ToolkitServiceObj->AddParameterChar('both', 1, 'DSCHARA', 'ds1','A');

$IOParam['ds2'] = array( "in"=>"B" ,"out"=>"");
$ds[] = $ToolkitServiceObj->AddParameterChar('both', 1, 'DSCHARB', 'ds2','B');

$IOParam['ds3'] = array( "in"=>"005.0007","out"=>"" );
$ds[] = $ToolkitServiceObj->AddParameterPackDec('both',7, 4, 'DSDEC1', 'ds3', '005.0007' );

$IOParam['ds4'] = array("in"=>"0000000006.08" ,"out"=>"");
$ds[] = $ToolkitServiceObj->AddParameterPackDec('both',12, 2, 'DSDEC1', 'ds4', '0000000006.08');

//$param[] = array('ds'=>$ds);
$param[] = $ToolkitServiceObj->AddDataStruct($ds);
$param[2]->setParamValue(0);
for ($i=0;$i<$loop;$i++) {
$result = $ToolkitServiceObj->PgmCall('ZZCALL', "ZENDSVR", $param, null, null);
$param[2]->setParamValue($result['io_param']['ds3']);
} // end loop

$end_time = microtime();
$wire_time= control_microtime_used($start_time,$end_time)*1000000;
echo
sprintf("<br><strong>Time (loop=$loop) total=%1.2f sec (%1.2f ms per call)</strong><br>",
round($wire_time/1000000,2),
round(($wire_time/$loop)/1000,2));

if($result){

/*update parameters array by return values */
foreach($IOParam as $key=> &$element){
$element['out'] = $result['io_param'][$key];
}

echo "<br>";
showTableWithHeader(array("Parameter name","Input value", "Output value"), $IOParam);
}
else
echo "Execution failed.";
/* Do not use the disconnect() function for "state full" connection */
$ToolkitServiceObj->disconnect();

function control_microtime_used($before,$after) {
return (substr($after,11)-substr($before,11))+(substr($after,0,9)-substr($before,0,9));
}

?>

Running this script resulted in the following results.

New Zend Toolkit. Input value is changing on each call.

Time (loop=5000) total=26.11 sec (5.22 ms per call)

Parameter name Input value Output value
var1 Y C
var2 Z D
var3 001.0001 321.1234
var4 0000000003.04 1234567890.12
ds1 A E
ds2 B F
ds3 005.0007 333.3330
ds4 0000000006.08 4444444444.44

The next test we ran would just call the program without changing the parameters to see what effect it had.


<?php
/*
RPG program parameters definition
INCHARA S 1a
INCHARB S 1a
INDEC1 S 7p 4
INDEC2 S 12p 2
INDS1 DS
DSCHARA 1a
DSCHARB 1a
DSDEC1 7p 4
DSDEC2 12p 2
*/
include_once 'authorization.php';
include_once '../API/ToolkitService.php';
include_once 'helpshow.php';

$loop = 5000;

$start_time = microtime();
echo "New Zend Toolkit. Input values never change on each call.<br><br>";

try {
$ToolkitServiceObj = ToolkitService::getInstance($db, $user, $pass);
}
catch (Exception $e) {
echo $e->getMessage(), "\n";
exit();
}

$ToolkitServiceObj->setToolkitServiceParams(array('InternalKey'=>"/tmp/$user"));

$IOParam['var1'] = array("in"=>"Y", "out"=>"" );
$param[] = $ToolkitServiceObj->AddParameterChar('both', 1,'INCHARA', 'var1', $IOParam['var1']['in']);

$IOParam['var2'] = array( "in"=>"Z", "out"=>"" );
$param[] = $ToolkitServiceObj->AddParameterChar('both', 1,'INCHARB', 'var2', $IOParam['var2']['in']);

$IOParam['var3'] = array( "in"=>"001.0001" ,"out"=>"");
$param[] = $ToolkitServiceObj->AddParameterPackDec('both', 7, 4, 'INDEC1', 'var3', '001.0001');

$IOParam['var4'] = array( "in"=>"0000000003.04","out"=>"" );
$param[] = $ToolkitServiceObj->AddParameterPackDec('both',12,2,'INDEC2', 'var4', '0000000003.04');

$IOParam['ds1'] = array( "in"=>"A" ,"out"=>"");
$ds[] = $ToolkitServiceObj->AddParameterChar('both', 1, 'DSCHARA', 'ds1','A');

$IOParam['ds2'] = array( "in"=>"B" ,"out"=>"");
$ds[] = $ToolkitServiceObj->AddParameterChar('both', 1, 'DSCHARB', 'ds2','B');

$IOParam['ds3'] = array( "in"=>"005.0007","out"=>"" );
$ds[] = $ToolkitServiceObj->AddParameterPackDec('both',7, 4, 'DSDEC1', 'ds3', '005.0007' );

$IOParam['ds4'] = array("in"=>"0000000006.08" ,"out"=>"");
$ds[] = $ToolkitServiceObj->AddParameterPackDec('both',12, 2, 'DSDEC1', 'ds4', '0000000006.08');

//$param[] = array('ds'=>$ds);
$param[] = $ToolkitServiceObj->AddDataStruct($ds);
$param[2]->setParamValue(0);
for ($i=0;$i<$loop;$i++) {
$result = $ToolkitServiceObj->PgmCall('ZZCALL', "ZENDSVR", $param, null, null);
//$param[2]->setParamValue($result['io_param']['ds3']);
} // end loop

$end_time = microtime();
$wire_time= control_microtime_used($start_time,$end_time)*1000000;
echo
sprintf("<br><strong>Time (loop=$loop) total=%1.2f sec (%1.2f ms per call)</strong><br>",
round($wire_time/1000000,2),
round(($wire_time/$loop)/1000,2));

if($result){

/*update parameters array by return values */
foreach($IOParam as $key=> &$element){
$element['out'] = $result['io_param'][$key];
}

echo "<br>";
showTableWithHeader(array("Parameter name","Input value", "Output value"), $IOParam);
}
else
echo "Execution failed.";
/* Do not use the disconnect() function for "state full" connection */
$ToolkitServiceObj->disconnect();

function control_microtime_used($before,$after) {
return (substr($after,11)-substr($before,11))+(substr($after,0,9)-substr($before,0,9));
}

?>

This resulted in the following output.

New Zend Toolkit. Input values never change on each call.

Time (loop=5000) total=26.95 sec (5.39 ms per call)

Parameter name Input value Output value
var1 Y C
var2 Z D
var3 001.0001 321.1234
var4 0000000003.04 1234567890.12
ds1 A E
ds2 B F
ds3 005.0007 333.3330
ds4 0000000006.08 4444444444.44

After this we ran the same request using the old i5_toolkit option using the following code.


<?php
//require_once('connection.inc');

$loop = 5000;

$start_time = microtime();
echo "Original Easycom Toolkit.<br><br>";

$conn = i5_connect( "", "", "");
if (!$conn)
{ $tab = i5_error();
die("Connect: ".$tab[2]." "."$tab[3], $tab[0]");
}

/* prepare */
$description =
array
(
// single parms
array
( "Name"=>"INCHARA","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_CHAR,"Length"=>"1"),
array
( "Name"=>"INCHARB","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_CHAR,"Length"=>"1"),
array
( "Name"=>"INDEC1","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_PACKED,"Length"=>"7.4"),
array
( "Name"=>"INDEC2","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_PACKED,"Length"=>"12.2"),
// structure parm
array
( "DSName"=>"INDS1",
"Count"=>1,
"DSParm"=>
array
(
array
( "Name"=>"DSCHARA","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_CHAR,"Length"=>"1"),
array
( "Name"=>"DSCHARB","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_CHAR,"Length"=>"1"),
array
( "Name"=>"DSDEC1","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_PACKED,"Length"=>"7.4"),
array
( "Name"=>"DSDEC2","IO"=>I5_IN|I5_OUT,"Type"=>I5_TYPE_PACKED,"Length"=>"12.2"),
)
)
);
$pgm = i5_program_prepare("ZENDSVR/ZZCALL", $description);
if (!$pgm)
{ $tab = i5_error();
die("Prepare: ".$tab[2]." "."$tab[3], $tab[0]");
}

// *** parameter list allocation
$list=
array
(
"DSCHARA"=>"x",
"DSCHARB"=>"y",
"DSDEC1"=>66.6666,
"DSDEC2"=>77777.77,
);
// *** parameter values passed to procedure
$in =
array
(
"INCHARA"=>"a",
"INCHARB"=>"b",
"INDEC1"=>0,
"INDEC2"=>222.22,
"INDS1"=>$list,
);
// *** name of variables created for out parameters
$out =
array
(
"INCHARA"=>"INCHARA",
"INCHARB"=>"INCHARB",
"INDEC1"=>"INDEC1",
"INDEC2"=>"INDEC2",
"INDS1"=>"OUTDS1",
);

for ($i=0;$i<$loop;$i++) {
$rc=i5_program_call($pgm, $in, $out);
if ($rc != false)
{
}
else
{ $tab = i5_error();
die("Call: ".$tab[2]." "."$tab[3], $tab[0]");
}
$in['INDEC1']=$OUTDS1['DSDEC1'];
} // end loop

$end_time = microtime();
$wire_time= control_microtime_used($start_time,$end_time)*1000000;
echo
sprintf("<br><strong>Time (loop=$loop) total=%1.2f sec (%1.2f ms per call)</strong><br>",
round($wire_time/1000000,2),
round(($wire_time/$loop)/1000,2));

echo "<br>";
echo $INCHARA."<br>";
echo $INCHARB."<br>";
echo $INDEC1."<br>";
echo $INDEC2."<br>";
echo $OUTDS1['DSDEC1'].'<br>';
//var_dump($INDS1);

/* close */
/*flush();
set_time_limit(60);
for(;;);
*/

$rc = i5_close($conn);

function control_microtime_used($before,$after) {
return (substr($after,11)-substr($before,11))+(substr($after,0,9)-substr($before,0,9));
}

This resulted in the following output.

Original Easycom Toolkit.

Time (loop=5000) total=0.66 sec (0.13 ms per call)

C
D
321.1234
1234567890.12
333.333

Next we looked at the new XML request using the new i5_toolkit, this is available for download from the Aura website and will install the required objects over an existing ZendCore or ZendServer install. This is good for those developers who wanted an XML type interface for program calls especially as Zend regularly said it was something users wanted as they found the old i5_toolkit method difficult to understand.

This is the code it ran.


<?php
//require_once('connection.inc');

$loop = 5000; //50000;

$start_time = microtime();
echo "Xml Easycom, using Associative Arrays Input/Output.<br><br>";

$conn = i5_connect( "", "", "");
if (!$conn)
{ $tab = i5_error();
die("Connect: ".$tab[2]." "."$tab[3], $tab[0]");
}

/* prepare */

$SRPG="DS1 DS;
DSCHARA 1a;
DSCHARB 1a;
DSDEC1 7p4;
DSDEC2 12p2;

ZZCALL PR extpgm(ZENDSVR/ZZCALL);
INCHARA 1a;
INCHARB 1a;
INDEC1 7p4;
INDEC2 12p2;
INDS1 likeds(DS1);
";
i5_XmlDefine ("s-rpg", $SRPG);

// *** parameter list allocation
$list=array(
"DSCHARA"=>"x",
"DSCHARB"=>"y",
"DSDEC1"=>66.6666,
"DSDEC2"=>77777.77,
);
$ArrayIn["INCHARA"] = "a";
$ArrayIn["INCHARB"] = "b";
$ArrayIn["INDEC1"] = 0;
$ArrayIn["INDEC2"] = 222.22;
$ArrayIn["INDS1"] = $list;

for ($i=0;$i<$loop;$i++) {
$ArrayIn["INDEC1"] = $i/1000;
$ArrayOut = i5_XmlCallProgram ("ZZCALL", $ArrayIn);
$ArrayIn["INDEC1"] = $ArrayOut['INDS1']['DSDEC1'];
} // end loop

$end_time = microtime();
$wire_time= control_microtime_used($start_time,$end_time)*1000000;
echo
sprintf("<br><strong>Time (loop=$loop) total=%1.2f sec (%1.2f ms per call)</strong><br>",
round($wire_time/1000000,2),
round(($wire_time/$loop)/1000,2));

echo '<UL><LI><PRE>';
print_r($ArrayOut);
echo '</PRE></LI></UL>';

/* close */
/*flush();
set_time_limit(60);
for(;;);
*/

$rc = i5_close($conn);

function control_microtime_used($before,$after) {
return (substr($after,11)-substr($before,11))+(substr($after,0,9)-substr($before,0,9));
}

This is the output.

Xml Easycom, using Associative Arrays Input/Output.

Time (loop=5000) total=4.27 sec (0.85 ms per call)

Array
(
[INCHARA] => C
[INCHARB] => D
[INDEC1] => 321.1234
[INDEC2] => 1234567890.12
[INDS1] => Array
(
[DSCHARA] => E
[DSCHARB] => F
[DSDEC1] => 333.333
[DSDEC2] => 4444444444.44
)

)

Finally we decide to look at the performance hit using our preferred installation which is Easycom Server running on the IBMi with Apache and PHP running on a PC or Linux server. The script run on the Linux/PC box with the program being run on the IBMi. The ode we ran is eactly the same code which ran for the test on the IBMi.

here is the output.

Original Easycom Toolkit.

Time (loop=5000) total=1.23 sec (0.25 ms per call)

C
D
321.1234
1234567890.12
333.333

So it looks like the claims against the Easycom i5_toolkit and how the new toolkit is much faster do not stand up in this situation? Is this representative? Maybe Maybe not.. As you can see from the above the old i5_toolkit is around 5 times faster (actually over 40 see the comment) than the new XMLSERVICE using the test programs, the new XML request provided in the new i5_toolkit is also slower than it predecessor but no way near as slow as the new XMLSERVICE, even running the old i5_toolkit requests on a PC and adding the delay for communication is still faster than the new IBM/Zend toolkit.

So we have done what we set out to do and looked at a simple test to see if the new XMLSERVICE stands up to its marketing, our opinion is it is not as fast based on our very simple tests. If you have different results share them with us.

If you would like to understand more about our PHP experiences let us know.

Chris…

Apr 18

Planning for COMMON 2011 at the end of the month

We thought it was about time we went back to the COMMON conference this year so we have bitten the bullet and decided to attend the Minneapolis event at the end of this month. As usual we are doing things at the last moment so we have a lot of things to get into place before we attend. We had considered taking a booth but our lack of commitment early enough meant we missed the chance to get everything in place in time. Maybe we will move fast enough to get a booth at either the next conference or maybe one of the European events?

Our main focus will be attending many of the sessions related to PHP and High Availability, so if you are there make sure you say Hi! If you are looking at High Availability there are a couple I would suggest you look at (Particularly if you are looking at a home grown solution) which are the Larry Youngren and Chuck Stupca sessions that are spread throughout the conference such as HA on a Shoestring.

I am personally looking forward to finding out what IBM and Zend have come up with for the Open Source PHP toolkit? One of the biggest problems I see with the IBM i and its PHP implementation is its lack of openness so maybe this will help remove some of those issues for me? We are also looking forward to meeting up with our friends at Aura Equipments who have a booth, if you are interested in PHP on the IBM i these are some people who you should make sure you pop round to see. They have a solution which allows you to connect to the IBM i from other platforms using PHP calls just the same as you do from the IBM i HTTP/Zend solution except you can talk to remote IBM installations. This brings a number of benefits one which we feel is important which is security. You don’t need to expose your IBM i to the internet to get IBM i content delivered to the internet! Performance is another big one for us as we only run small systems, but the new Zend/IBM announcements may reduce that somewhat if they actually deliver on their promises.

At the conference we will be sporting our new HA4i product logo which we have been working on for sometime. We feel it shows our commitment to the IBM i very well and doesn’t take a lot of interpretation for anyone to understand what the product is all about. Let us know what you think, I have put a copy of the logo’s below and I will be wearing the HA4i one proudly throughout the week. So if you see me make sure you pull me over for a chat about the product and what we have to offer.

Here is the new HA4i Logo, make sure you keep your eyes open for it.

HA4i ~ affordable Availability for the IBM i

HA4i Logo

This is the new DR4i logo, we won’t be sporting it at the event but look for it in the months to come.

DR4i ~ availability without complexity

DR4i Logo

We haven’t been posting much lately mainly because we are developing our own journal apply process, not that the IBM apply process is bad but we have found a couple of unique situations where it doesn’t fit the application environment too well. Not only that, but when we find anything that does need attention we have a lot of work to do with IBM to convince them a change would be to the benefit of everyone and as everyone knows that can sometimes be an uphill trudge. The basic technology for applying journal entries already exists for DB files because we developed it for the RAP product to apply the updates to the job data files. Now we have to cater for a lot more journal entries and as per usual it comes with a lot of quirks to work around such as IFS based entries where IBM doesn’t always store the object path but instead uses an Object ID which can differ between systems! We have the core functionality developed, all we have to do now is build the checks and balances for when things go wrong and make sure we have sufficient error checking to ensure it keeps running when errors occur.

The new Apply process should be available for the next major release which we hope to be announcing before the end of the year. Testing will probably take up most of that time! Other enhancements are available in recent PTFs which are available for download from the website. HA4i is developing fast and continues to provide an affordable High Availability solution for the IBM i market. If you are looking at Availability make sure you add HA4i to your list of products to look at, you may be surprised at just how affordable it can be.

If you are at COMMON make sure you say hello! I look forward to meeting new people and discussing what we can do for you. You never know, you might even be fortunate enough to catch me at the bar and manage to drag a free beer out of me!

Chris…

Jan 31

UK Presence

We have finally bit the bullet and set up a UK presence. The UK company will be responsible for all European sales and support for our products plus a focus on integration and management of the Microsoft line of products. It is early days but we feel it is important that our European customers are able to receive a local service and support our Business Partners in the area.

As soon as the company details are finalized will will provide details.

Chris…

Nov 02

Build your own DR solution.


If you are interested in building your own DR solution check out the SystemiNetwork magazine out this month. The magazine is loaded with information about High Availability and Disaster Recovery with an article written by yours truly..

You can view the article here Systemi Digital Edition

There is plenty of great information in the magazine this month for those who are considering High Availability. If it peaks your interest and you want to discuss what we have done with our new HA4i product drop us a line or gives us a call, we will be happy to respond.. You have seen the rest now look at the best…

Chris…

Oct 19

HA4i Ready for prime time with plenty of new features


HA4i Version 6.1 is now packaged and ready to ship! We had hoped to get the packaging complete about a month ago but a number of client requests had to be added so it put us back a number of weeks while we developed the new features and put the product back through testing. This will be the first release of HA4i which is a replacement for our existing RAP V4R1 product. We have made a lot of changes to the product which are all aimed at making HA4i a simpler and easier to manage High Availability Product for the SMB market.

While some of the features have been removed because they just added clutter and provided little use to the majority of our users we have added many new features which make this a very attractive High Availability solution for those customers who felt they could not afford one previously.

One of the most important aspects of this release is the simplification of the product, we have removed many of the sub menu’s and created intelligent start up processes to reduce the opportunity for error when controlling the product. We have also added some new features which provide a more granular approach to the apply process while ensuring we did not add complexity for the user in the start up process. As part of the new interface we have created a PHP based interface for the product which we can install if the customer needs it, if you have been following the blog for sometime you will have seen some screen shots from this interface. As usual we have not stopped and will continue to add features to the PHP interface as we move forward which will enhance the users experience when using the product. Here is the latest version of the main monitoring interface.

MainMonitor

Main Monitor Screen

Another area we took a good look at was the role swap process. When the user carries out a role swap there can be a number of problems which occur due to the availability of some information when systems are down or when a role swap is carried out with all of the processes up and running. We do request that the users end all activity before running the request on both systems but we have found a few just ignore that request and then complain bitterly when everything gets confused about what stage it should be in. So we have added more checking and data verification as part of the role swap process including the changing of the journal receivers and ending remote journal links automatically once the user has been asked for permission to carry it out. This has made the role swap process a lot more robust even when the rules are ignored… As with all programming tasks I am sure this will not be the end, I am sure there are some actions we have not considered and some user will prove just how stupid we can be…

Auditing has been included in the product from the beginning but as usual we are constantly trying to improve our processes to make them pick up more discrepancies and provide better checking of the objects. One area we just didn’t consider was the auditing of the profiles on the system, as the replication is totally automatic we had never seen any issues with profiles not being in sync. As usual a customer wanted to run audits against the profiles because he had been changing the profiles on the target by mistake and needed to bring everything back into line. The profile replication process only reacts to change notifications so unless he went through every profile and changed them we would not pick up the change. His request was quite simple, he wanted all of the profiles to be checked on the source and if they differ the differences noted to allow recovery at some later stage. As they have over 800 profiles on the system the thought of going through every profile manually did not please him..
So this release now has a profile audit function which will check the profile on each system logging any differences it finds. We did have to add a couple of exclusion such as the system profiles and the option to ignore the UID/GID settings which reduces the errors returned which have little bearing on the profile state.

Granularity was another concern we needed to address, in the previous version every receiver change was passed through a single apply processor. This version has added some granularity by allowing each remote journal to be controlled by an individual apply processor. Now you can have multiple journal receivers being applied at the same time which will also adds some improvements in the role swap times in those environments where multiple journals are configured between the systems. As you can see from the above monitoring screen we do allow the individual apply processes to be controlled via the PHP interface as well.

The replication of source files has been a problem for sometime, if you use the IBM journalling function to journal the files to your user journal and you have an active development environment with lots of code changes being worked on regularly the user journals can become very bloated very quickly. Every time you change a member even if its only a single line every line in the member will be added as a change in the user journal. RAP always provided the ability to replicate these objects at the object (FILE) level through the use of the tools we provided but it never had a trigger mechanism which would allow this to occur automatically. This release now uses the audit journal to capture the member changes and replicates the individual member on change. While this seems a bit similar to the bloating of the user journals it does offer a benefit in that the user journals are only applied occasionally, we restore the objects immediately which provides a smaller foot print for the DASD used to hold these changes on the target and the source. A couple of other objects have also been added to the support object list such as USRIDX and SAVF, as users ask for more objects we will continue to add them.

If you are interested in a demo of the product and its capabilities or would like to know more about it let us know, we could save you a lot of money on your existing installed HA product or surprise you at just how affordable HA really is.

Chris…

Sep 10

New siteurl running

We have finally made the move from shield.on.ca to shieldadvanced.ca! The new domain has been in effect for sometime but was being used for another business which we have taken the decision to move to a new domain altogether and have the shieldadvanced.ca domain as the primary domain for all Shield Advanced Solutions activities.

What do you need to do, basically nothing. We have parked the shield.on.ca domain and redirected everything to the new domain. Google and the search engines will obviously have a fit because they will find the re-directs but the amount of business we get from the web doesn’t cause us any worries by that. Eventually the webbots will scour the new site and put the search targets back in but until that time the re-directs should keep people coming back.

Chris…

Aug 31

HA4i latest PHP interface now ready.


The PHP interface for HA4i is now complete. We have a little bit of tidying up to do to ensure the code is as bug free as possible but in the main the PHP coding is finished.

The latest screens have the requested control functions built in using either button controls or links, a few of these require JavaScript but we have kept that to an absolute minimum to ensure the main functionality is available without it.

We have added many new controls to be able you to start, stop, suspend or resume the processes where applicable. Another nice feature we have added is the ability to remove or retry errors directly from the PHP screens, previously you had to sign onto the Green Screen menus to get at this functionality. We have also added more information to a number of the screens to allow you to better understand what is going on.

The next step is to develop a configuration facility for the PHP scripts and an install process to allow the EasyCom Server to be installed and configured on each of the servers involved. We are going to recommend the use of the EasyCom Server even if the Zend Server install is present because we need to be able to access both systems using PHP, configuring a single Zend Server instance can be a struggle for some so having to create 2 could be a real problem. The EasyCom server will be installed by the product and it will be managed within the HA4i environment. The HTTP server can then be installed on any IBM i/Windows?Linux system you wish.

Here is a glimpse of the latest main screen.

Latest Main monitoring Screen

Monitor Screen HA4i

We are hoping the GA version of HA4i will be available for shipment by the end of October this year or earlier if we can get enough testing done beforehand.

If you are interested in looking at HA4i for High Availability or want to replace your existing HA product let us know and we will be happy to provide costings and a demo, you may very surprised at just how affordable the solution will be!

Chris…

Jun 04

5733SC1 Back online for download (for now!)


After some discussions we have managed to get the 5733SC1 CD images back online for download. BUT we would ask that you limit the number of times you download the images to a single download or even consider creating your own download image for others to use. If you would be happy to do this we can set up a mirror link which can direct people to your download site.

If we find that people start abusing the system again we will have to think of an alternative, we love to support the IBM i community but the support cannot drain our resources… We hope that you use this facility with respect and don’t cause us to reconsider our decision. I don’t know why IBM is not providing this capability? Seems like this is what you pay your software subscriptions for.

Chris…