Friday, June 26, 2009

Delivering – Probe SAP

I acted as a midwife assisting to bring ‘Innovation’ mother’s baby – ‘Probe SAP’ to the world. I was the delivery coach and saw every step of the gestation period and how much the mother takes care to bring the baby to the world. It was an uphill task but as with all of our mothers, ‘Innovation’ pulled it through. Kudos to mother Innovation.
Now the midwife’s view. I had the privilege to introduce the baby to the world… What a big expectation it was from different corners for this baby! Fortunately in this case, it was possible to tailor make the baby as per the world’s demand. Even with that flexibility, it was very difficult to meet the expectations. With the privilege also comes the responsibility to take the criticism… ‘I thought the baby would look like Shahrukh Khan, I thought the baby can fly like Superman, I thought the baby would run like Carl Lewis on the first day’ etc. these were the kind of expectations thrown at me during the baby introduction but I am happy the way, we as delivery team worked with expectations and explained to the public what the baby can do.
What the baby can do anyway …
It can analyze any SAP environment and list down all the customizations and come up with the impact of upgrade. The customizations could be anything, any type of objects – Probe recognizes 54 types of objects. The baby has two type of personalities. Inventizer – the uncommitted guy who does not look into the details but interested in getting an overall idea about the person he deals with. Inventizer will give a complete picture of an environment to give anyone an idea on what it takes to maintain or upgrade the environment. The other split personality is Analyzer – the finicky girl who wants to go into every detail and find fault in every little thing. Analyzer goes into the level of identifying the line number where the incompatible element exist to carry out the upgrade. With these, the baby has for sure taken the big leap into the world. Now it requires constant nurturing to turn it into a grown up person to tackle anything in the real world of SAP upgrade and maintenance.
Head mother of Hexaware’s Innovation team, Innovation lead Immanuel has done a great work in directing the team in this delivery. But for his passion and focus in the demanding environment with limited resources, it would be even more difficult child bearing. I do not want to mention any names fearing I will definitely miss out someone. Job well done to the whole innovation team of mothers involved in this.
The baby has taken the first step to run as Carl Lewis!

Thursday, June 18, 2009

Drools for Airlines

Enterprise Applications embraces a lot of business rules. These business rules are often critical areas in decision making processes that attribute to changes in the behavior of an enterprise transaction. While these business rules should be an integral part of the Enterprise Solution transactions, they should be easy to use, easily adaptable to modifications, should be segregated from the programming logics so as to be easily maintainable.

Most often, one of the architectural mistakes that we do is to embed these business rules as a part of the software application code. This methodology poses some severe disadvantages.
  • When new rules are enforced, it becomes all the more difficult to add them. The software program has to be modified to add this rule thereby causing a downtime of the application.
  • Embedding business rules with software program affords less maintainability.
  • Access to these critical business rules for business experts is minimal since they are bundled with the core application logic.
  • Efficient use of a business rules engine or a management system is inherently over looked.
  • Reliability of IT departments on the business rule modification.
  • Reduced or no usage of efficient algorithms for automated business decision process.
There are quite a number of business rule engines (management systems) available in the market. One of those that is prominent and noteworthy is the Drools (aka) JBoss Rules ™ that provides efficient way to handle business rules within an enterprise transaction. There are quite a number of advantages of Drools that makes it attractive to the others such as but not limited to:
  • Drools cater to many programming languages such as Java, Python, and Groovy etc.
  • Drools can run on .NET
  • Drools are Declarative in nature allowing programmers to use it at ease.
  • Drools are flexible enough to be used by means of Domain Specific Language (DSL) to address the semantics of problem domain.
  • Drools can be configured via decision tables (excel tables)
  • Drools is based on forward chaining inference mechanism, which means that changes to inference during rule executions dynamically change the output behavior. What this means is that the data is iterated through until the pre defined goal is reached unlike the backward chaining approach.
Drools employ the famous pattern matching RETE algorithm. When known facts are asserted into the knowledge base, the implementation fires the rules (defined by the rule set) in a sequenced manner until the end of the rule is reached and then looping back to the first if necessary.

Drools for Airline

Airlines reservation system is mission critical system and is characterized by deployment across the world requiring split second response for any input. I am considering a small business rule in the airlines passenger services space to explain the importance of the drools at runtime. A passenger list display for a flight might be queried with different parameters to search for. I am considering that a query has been supplied to match the requested origin and destination and a specific booking status of a passenger to match for display. The rule of thumb is to display only the confirmed passengers on board. Further the rule should check if the segment being queries is open for display.
Below is a snapshot of how the drools file would look like (denoted by *.drl extension)
Drools for Airlines

Well, one might argue that the above rule might be written through a java (or any program in that case) code. The code would not look complex but would not look simple either. The rule explained above is the simplest in its form. Resolving the above simpler logic into an application code itself would amount to redundant iterations, in efficient loops etc. Notice the line where the status of the FlightLeg is being checked for from the list of Flight Legs and the line where the passengers with confirmed status are collected. It is just a single line that does the work! Furthermore any one can infer the outcome of this decision, not mandating that java knowledge is absolutely essential.

There are flexible expression language extensions employed by drools which cannot be programmed efficiently when the business logic is embedded into the application code. Furthermore drools bring in an abstraction to employing the business rules thus keeping the application code more readable and more manageable. Above all the power of drools is realized when there are complex decision making processes during forward chaining inference, especially when a decision outcome should have inherent effect on the other.

The Rule Explained

As can be seen from the above screen shot, the rule file contains a package declaration at the top followed by a list of imports needed for the rule (similar to java environments). The next section is a set of rule definitions. A rule is recognized by a name followed by a set of conditions to check (denoted by the when keyword) and a set of actions to take as the conditions are satisfied (denoted by the then keyword). A rule file can define any number of rules to be fired and optionally a sequence in the firing manner (denoted by the salience keyword). You should probably use this salience attribute if the firing of one rule has a consequence on the other. The no-loop keyword in the second rule as can be seen from the screen shot is used to instruct the rules engine to skip looping.

Drools also provides a set of pre defined enriched functions to work with collections and the like (as can be seen from the above rule snapshot like the collect function), the retract function to evict objects from the working memory when they are no longer needed.

Invoking the rule

Invoking the drools rule file that we defined is simple. To start with,…… the rule we defined has to be built into a form of package. This is achieved by using the KnowledgeBuilder.

KnowledgeBuilder kBuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();

A Knowledge builder in drools is responsible for taking an input rule definition file (the individual rule files, decision tables or the DSL files) and turning them into what is called a KnowledgePackage which the KnowledgeBase can consume. Typically this is achieved in the following way.

kBuilder.add(ResourceFactory.newClassPathResource(“person.drl”), 
ResourceType.DRL);

KnowledgeBuilder can report errors if the input rules definitions or decision tables cannot be compiled to knowledge packages. As a better programming practice it is always good to check if the KnowledgeBuilder has errors before adding resources.

When the Knowledge Packages are built, it is then ready to be consumed by the KnowledgeBase. This is accomplished in the following way,

KnowledgeBase kBase = KnowledgeBaseFactory.newKnowledgeBase();

kBase.addKnowledgePackages(kBuilder.getKnowledgePackages());

StatefulKnowledgeSession session = kBase.newStatefulKnowledgeSession();

//insert the objects that you want the rules to be fired for!
session.insert($object1);

session.insert($object2);

session.insert($object3);

//fire all the rules……
session.fireAllRules();

//dispose of this session since it is stateful.
session.dispose();

Wasn’t it simple? As can be inferred, writing business rules using Drools simplifies the task of embedding the rules into the application code that could otherwise result in redundant iterations, complex logics during dynamic decision inference etc. All of those are done behind the scenes through Drools. All the more Drools employ efficient algorithms for best performance which would otherwise have to be designed (or compromised which is what happens most of the time). Above all the rules can be written as decision tables, XML files which makes it more attractive.
Let us consider a small (rather ‘naïve’ to be precise) example to see how to employ Drools at run time. I am assuming a face book class where a single face book has a collection of persons and each person has an address. I am considering making use of drools for these 2 business rules:
  • No 2 persons in the face book instance can share the same email address.
  • When the address type of the person is not specified it should be defaulted to ‘Residence’
A  downloadable source code (a small stand alone example to start with) is provided for reference (as an eclipse project). The source code uses the drools binary distribution  (v5.x, http://www.jboss.org/drools), XStream (another impressive library to convert your java objects to XML without the need for schema definition Xor ML annotations, can be found at http://xstream.codehaus.org) and Apache Log4J http://logging.apache.org)

Wednesday, June 3, 2009

Databases and Marketing


Really exciting times to be in Marketing. Well, personally for me they are (the geek in me just loves how databases and analytics have become so critical to marketing! :) )
It is incredible how central data is becoming to the art and science of marketing. Infact marketing nowadays is so data driven that it is more science than art.
And I am not referring to ROI and marketing measurement data. Usage of that data is to be able to speak the same language as the CFO and CEO; to get a seat at the table in the executive suite. Something that the marketing organization has had to learn to meet the CFO’s standards.
I am referring to a data driven approach that has been driven by the marketing department itself. And this has been driven by the marketing department’s desire to run programs that are not gambles. Campaigns that are designed with the customers and their behaviour in mind and therefore hit the target more often than not. And that has brought us today to a time where databases and analytics are critical for marketing to succeed.
Not being familar with database management and analytics is not an option anymore.

Monday, May 25, 2009

The Power of Now – Paradigm shift in Digital Marketing


For the initiated, and those who have wet their beaks in Digital Marketing, today’s times are really exciting. And yet, there is constant pressure for marketing strategies to evolve constantly. There is a big shift happening in the way information is served and utilized.
Information is now all about “newness” and “nowness”. It is dynamic, constantly reinventing itself to stay in the rat race for attention. It is just not about standalone pages or browsers anymore. It’s more about streaming content, about relevance in constant churn, about adding enhanced value to your user segment, all of these building a conversation for a symbiotic relationship with a user segment.
Streams of Data, Not just static pools
Much water has flown under the internet highway since the advent of Really Simple Syndication (RSS). Social media networks have taken center stage and dynamic information is served and lapped up in myriad ways. The possibilities are endless – A chirpy tweet about an event real-time, a face-off with a corporate ambassador on face book, a stumble upon on your new proprietary IP micro site, a techno-rati-ing of your corporate blog, rank boost on a Wikipedia link etc.
Amid all this noise, it is quite important to make sense of the signals. Especially for B2B marketing which has to make sure that this shift in dynamics is effectively leveraged to generate awareness, drive leads and nurture relationships.
Swimming with the tide of dynamic information
The moot point here is whether this accent on immediacy of information holds intrinsic value for B2B marketing. Yes of course. Ignoring this new shift in information distribution would be a no brainer. The key here is to use these social streams to row people to your site and ensure the site is sticky enough for him to decide in your favor.
Social streams can help build reputation and trust that can help connect with your customers. In lots of ways it gives B2B marketers an easy way to participate in conversations that are about them. It is still early to tell though. Plunging into the stream would be the easy way to find out though.
This paradigm shift has come to stay and technology will be its prime driver. With Twitter going one up on Google on real time search stakes (an earthquake this minute appears faster in twitter than on Google) this information shift could forever change the way even a search result looks.

Monday, May 18, 2009

Digital Media Marketing


The power of digital media (usually referred to online media) has inspired me a lot through these years or rather never ceases to amaze me!
In today’s discriminating and techno-savvy world, with almost every business accomplished through the internet, a company’s presence over the web has become mandatory or should I say ‘a crucial factor’?
Here are some of my observations how online channels are used by businesses today.

Realize
Based on my experience in this field (I’m not a techie thoughJ), I have found that very few companies have exploited digital media through their websites. I think every company needs to realize the importance of their presence on the web with the ability to act fast, engage a lot of creativity and utilize resources capable of delivering innovative ideas keeping in mind their budgetary constraints.
Web metrics play a crucial role in determining the type of content that can attract and hold a customer’s interest, make them stay on the same website for a long time and make them come back for more – ideally meeting the user demand. Today, static images and plain text are replaced with streaming media and much more interactive applications providing the customer with a personalized experience. I feel many companies are struggling to develop their web presence in making it into more productive, virtual and a truly aggressive weapon.
Though a company has a string of issues involved in managing their web presence effectively, they also have to emphasize on the digital media’s potential in transforming the entire market scenario thereby ensuring greater ROI.
I would also add that opportunities are in abundance for any company willing to try out on these lines!
React
As I was digging through an article on digital media, a particular sentence caught my attention which in fact is apparently inevitable. It says, ‘A website has 10 seconds to draw a visitor or the person will “go back to Google”’! Well, are we talking here about “Love at first site”? Yes we are!
In this fast changing world, one has to face the reality that none of the above turns into a reality so easily. Companies have to think from the customers’ perspective, analyze and optimize his or her experience on the website by tuning their infrastructure, improve data center capability and effectively manage content delivery, thereby nurturing relationships.
It’s a do-or-die situation where IT organizations especially need to focus and react immediately on enhancing the digital business in line with their business objectives.
Reap
There’s nothing compared to reaping enhanced ROI through comprehensive digital media marketing in today’s world which is going through a major financial recession. Though I might daresay that it would be a silver lining amidst the gloom, a well defined approach with a strategic network, leveraged intelligence and the intent of providing a rich customer experience ensures improved business responsiveness and better cost control.
Well I do want to write more on the other areas of digital media in the forth coming posts. I would honestly need your comments and suggestions.

Monday, May 11, 2009

Informatica Upgrade Challenge –Default SQL Join for a Source Qualifier in 7x vs. 8x


Default SQL Query Generation for a Source Qualifier:

When relational sources are joined in one Source Qualifier transformation, the PowerCenter Server joins the tables based on the related keys in each table. This default join will be an equijoin like below
Source1.column_name = Source2.column_name
For Default joins to work, the columns in the default join must have:
  • A primary key-foreign key relationship
  • Matching data types
In current scenario, Most of the Datawarehouse are designed such a way that the primary key – foreign key relationship are designed in the logic instead of physical tables. In scenarios, where the fact tables are joined with dimension tables, the developer writes the join condition specifically in user defined join property present in source qualifier. This can be also done by default joins by creating relationships between the tables in Informatica instead of creating physically on the tables.
Creating relationships between the tables in Informatica are simple, just by dragging and dropping the column from one source definition to the other in Source Analyzer.

PowerCenter Server and SQL Query Generation

When a session is executed, Powercenter Server has two options
  1. Use the SQL Query typed by the developer if the ‘SQL Query’ property text window has ‘some text’ which is not blank
  2. If the ‘SQL Query’ property is blank then the PowerCenter Server generates a query for each Source Qualifier transformation when it runs the session.
  3. The SQL Query generation process for option 2 is bit different in PowerCenter 7x and 8x.
The Default query from Powercenter 7x is built in the below order
  1. SELECT keyword
  2. Field/Port Names which are linked to the next transformation from Source Qualifier
  3. FROM Keyword
  4. List of table names from the source definitions connected to the Source Qualifier separated by Comma
  5. WHERE Keyword
  6. [Value Present in the “User Defined Join” property ]
  7. [AND Keyword]  combined with Default Join Condition formed by Powercenter based on the relationship (If the User Defined Join is not present)
  8. [AND Keyword]  combined with Value present in the “Source Filter” property
  9. [ORDER BY keyword By Default, It selects the first field which is being selected after the SELECT clause.]
Where as in the Powercenter 8x, the default query is built in the below order
  1. SELECT keyword
  2. Field/Port Names which are linked to the next transformation from Source Qualifier
  3. FROM Keyword
  4. List of table names from the source definitions connected to the Source Qualifier separated by Comma
  5. WHERE Keyword
  6. [Value Present in the “User Defined Join” property ]
  7. [AND Keyword]  combined with Value present in the “Source Filter” property
  8. [AND Keyword]  combined with Default Join Condition formed by Powercenter based on the relationship (If the User Defined Join is not present)
  9. [ORDER BY keyword By Default, It selects the first field which is being selected after the SELECT clause.]
The Default join condition in 8x is appended next to the Source Filter where as in 7x the default join is appended before the source filter.

I came across an issue in a recent upgrade project because of this difference in behavior. The mapping that ran properly in 7x which extracted the required data from the source, actually ran into problem 8x. The upgraded mapping in 8x created a Cartesian SQL join. When analyzed found that the source filter had the last line commented with ‘—‘. This made the default join condition to also get commented in 8x which resulted in Cartesian product of the source tables.

So the key is to determine how many of the Informatica mappings/sessions have Source Filter property set with a comment ‘—‘, this could help identify this issue much earlier in the upgrade.

Thanks for reading, share any other upgrade challenge that you have faced.

To know more about Informatica Upgrade Challenge

Wednesday, May 6, 2009

Don’t Let the Economic Slowdown Stall Your IT Projects


Right now, the primary issue on everyone’s mind is the slowdown of the global economy. Corporations of all sizes are estimating its short-term and long-term effects on the health of businesses, and organizational spending — especially IT spending — is coming under heightened scrutiny.
However, because IT is a critical enabler of business, Companies cannot simply eliminate IT spending. Instead, they are re-evaluating and redefining their strategies and IT investments, looking to demonstrate improvement in efficiency and to achieve tangible results. CIOs are now asking, “How can IT deliver more with less? And what will put us on a fast track during this slowdown?”
Accomplishing these goals rests on the basics of outsourcing — that is, creating a long-term IT Optimization strategy and picking the right partner to help execute this strategy. For example, one international bank was able to enhance the quality of its customer interactions while increasing operational efficiency and lowering costs. And it was the bank’s partnership with Hexaware that helped it reach its optimization goals.
A Beneficial Partnership in Action
The bank in our example wanted to accomplish seamless integration and communication with the accounts payable system of both its corporate and retail customers. To do so, the bank selected SAP NetWeaver Exchange Infrastructure (SAP NetWeaver XI) as the platform of choice to address business challenges and create a robust application roadmap. The key features of SAP NetWeaver XI include:
  • Synchronous, real-time transmission of data with immediate message delivery notices
  • The ability to “push” messages at delivery time or at a scheduled interval, from customer to bank or vice versa
And with SAP’s solid partner ecosystem, the bank had many options for finding a partner that would be able to implement this solution for it. In this case, what the bank sought specifically was an SAP-certified outsourcing partner to:
  • Provide a holistic virtual integration between the bank and its customers
  • Provide a seamless link from customers’ ERP systems to its own
  • Enforce strong security at the communication, transport, and data levels, in accordance with accepted industry standards
  • Ease the implementation, while minimizing disruption
  • Integrate message channels and formats to further secure communication channels
The bank chose Hexaware for its implementation expertise and its ability to create optimization strategies. Hexaware is also a premier SAP gold partner that has helped with more than 500 implementation, upgrade, and support engagements.
Following Hexaware’s nearshore-offshore model, the bank was able to achieve 30% cost savings. Hexaware’s implementation of SAP NetWeaver XI was seamless and efficient, and it demonstrated tangible business results, including an improved customer approval rating. In addition, the implementation was successful on both the IT and business levels, reaping continuous solution benefits for the bank.
Learn More
Hexaware provides global rollout, implementation, upgrade, testing, and support services to industries worldwide. Our SAP-specialized teams ensure service delivery excellence and deliver innovative strategies for clients. Hexaware also generates value through a range of solution accelerators and tools.