Fight or flight :) but from my perspective you don't have to be the victim of other people.
Tank has:
- Positive Intent: Get the task done.
- Characteristics: Controlling, Assertive, Aggressive, and confrontational, and has short attention spans.
Aggressive people require assertive responses; your behavior must send a clear signal that you are strong, capable and anything less is an invitation for future attacks. The strength of character that you reveal will ultimately determine the tank’s perception of you and future behavior toward you.
Your emotions can be greatest point of vulnerability, so first try hard to avoid the following three emotional responses to an attacking tank:
1- In a burst of angry, you may be tempted to counterattack :
An advice, you should avoid engaging in tank-to-tank warfare, unfortunately he always will win.
2- You might attempt to defend, explain or justify your position:
Tank has no hearing your explanations, but it could be antagonize the tank :(.
3- You could shut down and become a nothing person:
The Fear is a sure-fire signal to the tank that the attack is justified and you are somehow deserving of the pounding.
Note:
Tanks simply do not attack people they respect so your goal must be to command respect.
So check below the required action plan to treat with tanks :) :
1- Hold your ground.
Do not change your position, you do not have to go on the offensive or the defensive. Instead, silently look the tank in the eyes, and shift your attention to your breathing.
2- Tactfully interrupt the attack.
The best ways is repeating their name over and again until you have their full attention. But be careful once you have begun this action, backing off may be worse than never having done anything at all. Prepare what you want to say but with assertive way.
3- Quickly backtrack the main point.
Once you have the tanks attention backtrack the main accusation because backtracking sets a good example for listening with respect and it convey the tank that you have heard him.
4- Aim for the bottom line and fire.
Redirect the Tank by showing how you share a common goal of getting the task done.
5- Maintain peace and earn Tank’ respect by assigning a time and conditions for following up on the issue once she has cooled down.
Very wonderful example “Mary,Mary,Mary. I hear that you are having a problem with the ways this is being done. But I am not willing to discuss it ,if this is how you are going to talk to me. When you are ready to speak to me with respect, I will take all the time you want to discuss this” ;)
But what is the tank’s accusation are true, and you are in the wrong?
1- Please admit to you mistake.
2- State briefly what you have learned from your experience.
3- And finally State what you will do differently in the future to prevent it from happening again.
Good Luck with your tanks :D :D :D :D
Wednesday, November 17, 2010
Saturday, October 2, 2010
Dealing with People you can't stand ((1))
“Dealing with people you cannot stand” is really spectacular book and it should be read. It helps you to learn:
1- How to use communications techniques that enable you to work with difficult personalities.
2- How to use specific tactics to counteract negative behavior.
3- How to use the telephone to build relationships.
It starts by identifying the top 10 unwanted Characteristics then give you some skillful communication to let you survive during communication with whomever from unwanted list, then takes you in tour to find how you can bring out the best in everyone in unwanted list at their worst.
From my perspective, it is so effective and learnable strategies for dealing with most problem behaviors and it could change all your life because it limit your angry. Instead of getting angry all the times from the behaviors of people who around you , you begin to get in deep in characteristics and begin to analysis what their thinking ways ,what they care about now and what they do not. And I think with time you will reach to professional way to communicate with people successfully whatever they are.
Now I just wanted to go forward with the same book contents so let’s go to identify who are the top 10 unwanted list :D :D , and just I want to high light perhaps you noticed that ,when your intentions are thwarted/randomly , you occasionally become some of these people too so do not be pessimistic the essential point is that these behaviors are observable and changeable and the results of your dealing with people at their worst is , in large measure ,up to you.
1- The TANK:
Pushy and ruthless, loud and forceful, or with the quiet intensity and surgical precision of a laser, the end justifies the means. Expect no mercy from the Tank.
2- The YES Person:
Quick to agree, slow to deliver, the Yes Person leaves a trail of un kept commitments and broken promises. Though it pleases no one, Yes-people over commit in order to please!
3- The SNIPER:
This covert operator identifies your weaknesses and uses them against you, through sabotage behind your back or well-aimed put-downs in front of the crowd.
4- The KNOW-IT-ALL:
This person knows 98% of anything. Just ask! The Know-It-All will tell you what they know for hours at a time, but won’t take a second to listen to your clearly inferior ideas.
5- The THINK-THEY-KNOW-ITALL:
This character doesn’t know much, but doesn’t let that get in the way. Exaggerating, bragging, misleading and distracting, this legend-in-their own mind pulls you off track.
6- The GRENADE:
When they blow their top, they’re unable to stop, and shrapnel hits everyone in range. Then the smoke clears, the dust settles, and the cycle begins building to critical mass again.
7- The MAYBE person:
When faced with a crucial decision, they keep putting it off until it’s too late. But there comes a point when the decision makes itself. Then it’s nobody’s default but their own.
8- The NOTHING Person:
You won’t know what’s going on because they tell you ‘Nothing!’ No verbal feedback. No non-verbal feedback. They seal their mouths and stare past you as if you're not there.
9- The NO Person:
They say that “What goes up must come down.” And what comes down must never be allowed to get back up again. Doleful and discouraging, they drive others to despair.
10- The WHINER:
There’s a plan for their life, but they’re not in it. Instead, they wallow in their woe, whine incessantly, and carry the weight of the world on their shoulders.
http://books.google.com.eg/books?id=EWJA2K011mEC&dq=dealing+with+people+you+can't+stand+pdf&printsec=frontcover&source=bn&hl=en&ei=N3-nTOj9DsyNjAej6cy7DA&sa=X&oi=book_result&ct=result&resnum=5&ved=0CCYQ6AEwBA#v=onepage&q=dealing%20with%20people%20you%20can't%20stand%20pdf&f=false
http://www.dealingwithrelatives.com/media/ftp/PopQuiz.pdf
1- How to use communications techniques that enable you to work with difficult personalities.
2- How to use specific tactics to counteract negative behavior.
3- How to use the telephone to build relationships.
It starts by identifying the top 10 unwanted Characteristics then give you some skillful communication to let you survive during communication with whomever from unwanted list, then takes you in tour to find how you can bring out the best in everyone in unwanted list at their worst.
From my perspective, it is so effective and learnable strategies for dealing with most problem behaviors and it could change all your life because it limit your angry. Instead of getting angry all the times from the behaviors of people who around you , you begin to get in deep in characteristics and begin to analysis what their thinking ways ,what they care about now and what they do not. And I think with time you will reach to professional way to communicate with people successfully whatever they are.
Now I just wanted to go forward with the same book contents so let’s go to identify who are the top 10 unwanted list :D :D , and just I want to high light perhaps you noticed that ,when your intentions are thwarted/randomly , you occasionally become some of these people too so do not be pessimistic the essential point is that these behaviors are observable and changeable and the results of your dealing with people at their worst is , in large measure ,up to you.
1- The TANK:
Pushy and ruthless, loud and forceful, or with the quiet intensity and surgical precision of a laser, the end justifies the means. Expect no mercy from the Tank.
2- The YES Person:
Quick to agree, slow to deliver, the Yes Person leaves a trail of un kept commitments and broken promises. Though it pleases no one, Yes-people over commit in order to please!
3- The SNIPER:
This covert operator identifies your weaknesses and uses them against you, through sabotage behind your back or well-aimed put-downs in front of the crowd.
4- The KNOW-IT-ALL:
This person knows 98% of anything. Just ask! The Know-It-All will tell you what they know for hours at a time, but won’t take a second to listen to your clearly inferior ideas.
5- The THINK-THEY-KNOW-ITALL:
This character doesn’t know much, but doesn’t let that get in the way. Exaggerating, bragging, misleading and distracting, this legend-in-their own mind pulls you off track.
6- The GRENADE:
When they blow their top, they’re unable to stop, and shrapnel hits everyone in range. Then the smoke clears, the dust settles, and the cycle begins building to critical mass again.
7- The MAYBE person:
When faced with a crucial decision, they keep putting it off until it’s too late. But there comes a point when the decision makes itself. Then it’s nobody’s default but their own.
8- The NOTHING Person:
You won’t know what’s going on because they tell you ‘Nothing!’ No verbal feedback. No non-verbal feedback. They seal their mouths and stare past you as if you're not there.
9- The NO Person:
They say that “What goes up must come down.” And what comes down must never be allowed to get back up again. Doleful and discouraging, they drive others to despair.
10- The WHINER:
There’s a plan for their life, but they’re not in it. Instead, they wallow in their woe, whine incessantly, and carry the weight of the world on their shoulders.
http://books.google.com.eg/books?id=EWJA2K011mEC&dq=dealing+with+people+you+can't+stand+pdf&printsec=frontcover&source=bn&hl=en&ei=N3-nTOj9DsyNjAej6cy7DA&sa=X&oi=book_result&ct=result&resnum=5&ved=0CCYQ6AEwBA#v=onepage&q=dealing%20with%20people%20you%20can't%20stand%20pdf&f=false
http://www.dealingwithrelatives.com/media/ftp/PopQuiz.pdf
Thursday, May 13, 2010
مقيـاس الحقيقـة
لا تقاس الطيبة ببشاشة الوجه
فهناك قلوب تصطنع البياض
فهناك من يجيد تصنع الطيبة
ويخبئ بين زواياه خبثاً وريبة
لا يقاس الجمال بالمظهر
ومن الخطأ الاعتماد عليه فقط ...
فقد يكون خلف جمال المظهر قبح جوهر
لا تقاس حلاوة الإنسان بحلاوة اللسان
فكم من كلمات لطاف حسان
يكمن بين حروفها سم ثعبان
فنحن في زمن اختلط الحابل بالنابل ...
في زمن صرنا نخاف الصدق
ونصعد على أكتاف الكذب
لا يقاس الحنان بالأحضان
هناك من يضمك بين أحضانه
ويطعنك من الخلف بخنجر الخيانة
والفرق شاسع ومدفون
بين المعلن والمكنون
لا تقاس السعادة بكثرة الضحك
هناك من يلبس قناع الابتسامة
وتحت القناع حزن دفين وغصات ألم وأنين
لا تقاس الحياة بنبض القلوب
فهناك من قلبه تعفن داخل أضلعه
وهناك من مات ضميره وودعه
وعلى الضفة الأخرى آخر كتمت أنفاسه
وثالث قتل إحساسه مقبرته
في عينيه شاهد حزن عليه
لا يقاس البياض بالنقاء ولا السواد بالخبث
فالكفن أبيض والكحل لونه أسود
وبينهما يسكن الفرق
لا تقاس العقول بالأعمار
فكم من صغير عقله بارع
وكم من كبير عقله خاوي فارغ
فهناك قلوب تصطنع البياض
فهناك من يجيد تصنع الطيبة
ويخبئ بين زواياه خبثاً وريبة
لا يقاس الجمال بالمظهر
ومن الخطأ الاعتماد عليه فقط ...
فقد يكون خلف جمال المظهر قبح جوهر
لا تقاس حلاوة الإنسان بحلاوة اللسان
فكم من كلمات لطاف حسان
يكمن بين حروفها سم ثعبان
فنحن في زمن اختلط الحابل بالنابل ...
في زمن صرنا نخاف الصدق
ونصعد على أكتاف الكذب
لا يقاس الحنان بالأحضان
هناك من يضمك بين أحضانه
ويطعنك من الخلف بخنجر الخيانة
والفرق شاسع ومدفون
بين المعلن والمكنون
لا تقاس السعادة بكثرة الضحك
هناك من يلبس قناع الابتسامة
وتحت القناع حزن دفين وغصات ألم وأنين
لا تقاس الحياة بنبض القلوب
فهناك من قلبه تعفن داخل أضلعه
وهناك من مات ضميره وودعه
وعلى الضفة الأخرى آخر كتمت أنفاسه
وثالث قتل إحساسه مقبرته
في عينيه شاهد حزن عليه
لا يقاس البياض بالنقاء ولا السواد بالخبث
فالكفن أبيض والكحل لونه أسود
وبينهما يسكن الفرق
لا تقاس العقول بالأعمار
فكم من صغير عقله بارع
وكم من كبير عقله خاوي فارغ
Sunday, March 7, 2010
If I had opportunity to get significant position in Egypt
First of all, let us agree that Egypt had been playing essentially starring role in world development for several decades and Egypt is the basic brilliant source for civilization.
Unfortunately, Egypt faces nowadays some fundamental problems in several terms especially regarding human rights. These problems will not be solved in an overnight sensation, definitely not. Egypt requires a long term strategy which is hard to be defined.
So sometimes I ask myself what is this strategy and if someday I had opportunity to get significant position in Egypt what would I do. From my personal perspective, I think that it is time we turned the major of our focus and concentration to education and health.
The education is important because every society needs people to contribute effectively in a variety of ways to the future health and wellbeing of communities and development, in other words education is really the soul of any civilization. So I strongly wish we could improve it because it unfortunately became in a mess especially the secondary education system. If I were minister of education, I would change it and change the used inept approach for joining the colleges. Entering colleges according to the student grades is inept approach and it should no longer exist.
The health of our citizen is important because they are our resource for development but unfortunately as usual we do not use it effectively. Every day there is plenty of people who dies and give us clear evidence how much we have lack treatment and not equivalent offering for our medical services who can pay can get. If I were minster of health,I would try to provide free health care program – medical services- or at least with humble fees. I wish all the hospitals have the same medical services -not one hospital for rich and other for poor.
Saturday, March 6, 2010
Women Work Dilemma
Nowadays, the women work is really significant dilemma especially in our society. It is certainly true it has positive impact in our development but at the same moment there are surveys which clarify how women work affects negatively our society. So Many people nowadays vote against it and not only men who vote against it but also some women vote against themselves because they believe they are inferior and only fit for household chores.
The work for woman is as her identity because women who work are independent. This means that they do not have to depend on others like before – they stand on their own feet. Working women also obtain respect and freedom by the society. And definitely money by the working women and men enters the house, bringing more wealth, luxury, comfort and leisure.
And according to statistic, there is no difference between the standards and quality of work done by men and women who do the same work. Further women sometimes are more productive than men, despite being paid less. Women are responsible, devoted and have more loyalty more than men.
On the other hand the societies, religion or tradition can be used as a barrier for women work. Plenty of people still say that women should not work; in other words, a woman’s place is in the home. Mothers have full time to devote to her children, teaching them the care and protection. Indeed, these points are crucial factors in the good development of children – factors that may not be present in women who work for their consequence of the stress due to work and lack of time.
But for me I totally agree with woman work if and only if her work will not affect what she is created for. Women should no longer be considered the inferior sex, they should stand side by side with men and define their roles in society, choose to work outside or stay at home and in which they will have more time to develop their own interests. The wife of a powerful businessman or politician or successful person is no less responsible for the success than the man because the Success is a result of cooperation, assistance, coincidence and supporting.
Saturday, January 30, 2010
Reading Groups
Yesterday when I was studying, I read good article about reading group and it excited me so I decided to publish the idea because really I see it useful especially for read lovers who do not find enough space time to spend with their books after all the daily life load.
The Idea could not be simpler , just group of members agree to read a certain book, and then, a few weeks later meet up to exchange opinion over tea , coffee …etc . You can meet in people’s homes, but also in clubs, cafes …etc.
Definitely, it is so recommended that the group should have kind of homogeneity. The group members could be friends, neighbors, cousins, colleagues…etc whatever the combination but they should have good abilities to meet together and share together the interested topics to read.
The Idea could not be simpler , just group of members agree to read a certain book, and then, a few weeks later meet up to exchange opinion over tea , coffee …etc . You can meet in people’s homes, but also in clubs, cafes …etc.
Definitely, it is so recommended that the group should have kind of homogeneity. The group members could be friends, neighbors, cousins, colleagues…etc whatever the combination but they should have good abilities to meet together and share together the interested topics to read.
From my opinion, this idea will help us to have commitment to read the books faster as we can because we are going to have a date to discuss what we got. Get more from the book because you will get it from different perspectives, furthermore at the same moment this idea may be one of the getting together style to broaden our social life.
Despite the idea is simple, it can be more useful if we could summarize what we read then publish it as kind of knowledge transfer. Imagine getting two books during read one and read the summary of the other :) … it will be amazing.
Wednesday, January 20, 2010
Thursday, June 11, 2009
Quality Quotes
1- Quality is never an accident; it is always the result of high intention, sincere effort, intelligent direction and skillful execution; it represents the wise choice of many alternatives.
2- The Quality of an organization can never exceed the quality of the minds that make it up.
3- If standard of living is your major objective, quality of life almost never improves, but if quality of life is your number one objective, your standard of living almost always improves.
4- Quality begins on the inside... and then works its way out.
5- If you don’t have time to solve problems, how come you always have time to do it wrong again?!
6- Results come better from doing the things right than from doing the right thing.
7- There’s only one corner of the universe you can be certain of improving, and that’s your own self.
8- Everything can be improved.
9- A country can be judged by the quality of its proverbs.
10- Associate yourself with men of good quality if you esteem your own reputation. It is better be alone than in bad company.
2- The Quality of an organization can never exceed the quality of the minds that make it up.
3- If standard of living is your major objective, quality of life almost never improves, but if quality of life is your number one objective, your standard of living almost always improves.
4- Quality begins on the inside... and then works its way out.
5- If you don’t have time to solve problems, how come you always have time to do it wrong again?!
6- Results come better from doing the things right than from doing the right thing.
7- There’s only one corner of the universe you can be certain of improving, and that’s your own self.
8- Everything can be improved.
9- A country can be judged by the quality of its proverbs.
10- Associate yourself with men of good quality if you esteem your own reputation. It is better be alone than in bad company.
Thursday, February 19, 2009
JMS ( Java Message Service)
1. Introduction
MOM unlike RPC and object-orientation it is an asynchronous form of communication, i.e. the sender does not block waiting for the recipient to participate in the exchange. If the message service offers persistence and reliability then the receiver need not be up and running when the message is sent.
2.1 JMS messaging models
JMS supports two models: point-to-point (PTP) and publish/subscribe (pub-and-sub).
2.1.1 Point to Point [queue] Messaging model:
- It is intended for one-to-one delivery of messages through a virtual channel called [Queue]
- It is a pull- or polling-based model, where messages are requested by consumer from the queue instead of being pushed to the client automatically.
- The message is read just once by a consumer although There may be more than one potential consumer to queue, however once a message has been read by one consumer it cannot be read by any of the remaining consumers.
- A sender and a receiver of a message have no timing dependencies. The receiver can fetch the message whether or not it was running when the client sent the message.
- In PTP it is preferred that the Sender program should be established before the consumer (very important note).
- In PTP After the message is read it is deleted from the queue.

From the OC4J Home page, select the Administration page, then the Enterprise Messaging Service column, then JMS Destinations and JMS Connection Factories.
4. JMS API Programming Model
After setting the JMS provider environment, it is the time to build JMS Clients (producer or consumer client).
The basic building blocks of a JMS application consist of
1- Access JMS provider
2- Create administered Connection: connection factories and destinations
3- Create Connection
4- Create Session
5- Create Producer and consumer
6- Create Message
7- Send and receive Messages
4.2.1 Connection Factory:
A connection factory is the object a client uses to create a connection with a provider, Each connection factory is an instance of either the QueueConnectionFactory or the TopicConnectionFactory interface.a pair of connection factories come preconfigured with the J2EE SDK and are accessible as soon as you start the service.
QueueConnectionFactory queueConnectionFactory =
(QueueConnectionFactory) ctx.lookup("jms/QueueConnectionFactory");
TopicConnectionFactory topicConnectionFactory =
(TopicConnectionFactory) ctx.lookup("jms/TopicConnectionFactory");
4.2.2 Destination:
A destination is the object a client uses to specify the target of messages it produces and the source of messages it consumes.
Queue myQueue = (Queue) ctx.lookup("jms/MyQueue");
Topic myTopic = (Topic) ctx.lookup("jms/MyTopic");
4.3 Create Connection
A connection encapsulates a virtual connection with a JMS provider. A connection could represent an open TCP/IP socket between a client and a provider service daemon. You use a connection to create one or more sessions.
QueueConnection queueConnection =
queueConnectionFactory.createQueueConnection();
TopicConnection topicConnection =
topicConnectionFactory.createTopicConnection();
Note: When an application completes, you need to close any connections that you have created. Failure to close a connection can cause resources not to be released by the JMS provider. queueConnection.close(); topicConnection.close();
4.4 Create Session
A session is a single-threaded context for producing and consuming messages, A session provides a transactional context with which to group a set of sends and receives into an atomic unit of work.
QueueSession queueSession =
queueConnection.createQueueSession(false, Session.AUTO_ACKNOWLEDGE);
TopicSession topicSession =
topicConnection.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
The first argument means that the session is not transacted; the second means that the session automatically acknowledges messages when they have been received successfully.
4.5 Create Message Producer and consumer
A message producer and consumer are objects which created by a session and are used for sending and receiving messages to a destination.
Producer:
QueueSender queueSender = queueSession.createSender(myQueue);
TopicPublisher topicPublisher = topicSession.createPublisher(myTopic);
Consumer:
QueueReceiver queueReceiver = queueSession.createReceiver(myQueue);
TopicSubscriber topicSubscriber = topicSession.createSubscriber(myTopic);
4.6 Create Message
The JMS API defines five message types [ TextMesssage, MapMessage, BytesMessage, StreamMessage, ObjectMessage, Message] , which allow you to send and to receive data in many different forms and provide compatibility with existing messaging formats and provides some predefined property names that a provider may support. The use of either predefined properties or user-defined properties is optional.
TextMessage message = queueSession.createTextMessage();
message.setText(msg_text); // msg_text is a String
4.7 Sending and receiving Messages
Sending:
QueueSender and TopicPublisher can be used to send the messages.
queueSender.send(message);
topicPublisher.publish(message);
Receiving:
QueueReceiver and a TopicSubscriber can be used to receive the messages at any time after calling start method.
queueConnection.start();
--> To consume a message synchronously you can use receive method as following:
Message m = queueReceiver.receive();
or
Message m = queueReceiver.receive(1000); // time out after a second
if (m instanceof TextMessage) {
TextMessage message = (TextMessage) m;
System.out.println("Reading message: " + message.getText());
} else {
// Handle error
}
--> To consume a message asynchronously you will use message listener where it is an object that acts as an asynchronous event handler for messages. This object implements the MessageListener interface, which contains one method, onMessage. In the onMessage method, you define the actions to be taken when a message arrives.
The message listener will be registered with a specific QueueReceiver or TopicSubscriber by using the setMessageListener method. For example, if you define a class named QueueListener that implements the MessageListener interface, you can register the message listener as follows:
QueueListener queueListener = new queueListener();
queueReceiver.setMessageListener(queueListener);
Important notes:
1- The setmessageListener method will throw Exception if it is running in Web or EJB Container; it should be used under Client container. So to handle the asynchronous consumption in J2EE 1.3 platform you will need to use Message Driven Bean which is a special kind of message listener.
2- If you call start before you register the message listener, you are likely to miss messages.
References:
Java Message Service O'Reilly [Richard Monson-Haefel ,David A. Chappell]
EJB 3 Developer Guide [ Michael Sikora ]
http://java.sun.com/javaee/5/docs/tutorial/doc/bncdq.html
http://download.oracle.com/docs/cd/B14099_19/web.1012/b14012/jms.htm
http://mediasrv.ns.ac.yu/extra/java2/tutorials/jms_tutorial/index.html
The different software applications can communicate with each other using messaging paradigm–exchanging the data in message format where the data contained in a message can be anything Object ,Tex ...etc depending on the business scenario – this paradigm when used in business Systems, are generically referred to as enterprise messaging systems, or Message-Oriented Middleware (MOM).
MOM unlike RPC and object-orientation it is an asynchronous form of communication, i.e. the sender does not block waiting for the recipient to participate in the exchange. If the message service offers persistence and reliability then the receiver need not be up and running when the message is sent.
MOM vendors provide transmitting the messages across a network, ensuring messages distribution, fault tolerance, load balancing, scalability and reliability to exchange large quantities of message. Most of MOM vendors may implement their own networking protocols, routing, and administration facilities but the basic semantics of the developer API provided by different MOMs are the same. This similarity in APIs makes the Java Message Service possible. (MOM == JMS provider)
2. JMS API
JMS (Java message service) is a Java API that allows applications to create, send, receive, and read messages, it is designed to be easily and widely used with many different MOM vendors.
2. JMS API JMS (Java message service) is a Java API that allows applications to create, send, receive, and read messages, it is designed to be easily and widely used with many different MOM vendors.
JMS API enables communication that is not only loosely coupled but also asynchronous and reliable.
1- Loosely coupled :A component sends a message to a destination, and the recipient can retrieve the message from the destination. However, the sender and the receiver do not have to be available at the same time in order to communicate. In fact, the sender does not need to know anything about the receiver; nor does the receiver need to know anything about the sender. The sender and the receiver need to know only which message format and which destination to use.
2- Asynchronous: A JMS provider can deliver messages to a client as they arrive; a client does not have to request messages in order to receive them.
3- Reliable: The JMS API can ensure that a message is delivered once and only once. Lower levels of reliability are available for applications that can afford to miss messages or to receive duplicate messages.
1- Loosely coupled :A component sends a message to a destination, and the recipient can retrieve the message from the destination. However, the sender and the receiver do not have to be available at the same time in order to communicate. In fact, the sender does not need to know anything about the receiver; nor does the receiver need to know anything about the sender. The sender and the receiver need to know only which message format and which destination to use.
2- Asynchronous: A JMS provider can deliver messages to a client as they arrive; a client does not have to request messages in order to receive them.
3- Reliable: The JMS API can ensure that a message is delivered once and only once. Lower levels of reliability are available for applications that can afford to miss messages or to receive duplicate messages.
2.1 JMS messaging models
JMS supports two models: point-to-point (PTP) and publish/subscribe (pub-and-sub).
2.1.1 Point to Point [queue] Messaging model:
- It is intended for one-to-one delivery of messages through a virtual channel called [Queue]
- It is a pull- or polling-based model, where messages are requested by consumer from the queue instead of being pushed to the client automatically.
- The message is read just once by a consumer although There may be more than one potential consumer to queue, however once a message has been read by one consumer it cannot be read by any of the remaining consumers.
- A sender and a receiver of a message have no timing dependencies. The receiver can fetch the message whether or not it was running when the client sent the message.
- In PTP it is preferred that the Sender program should be established before the consumer (very important note).
- In PTP After the message is read it is deleted from the queue.
2.1.2 Publisher and Subscriber [Topic] Messaging model:
- It is intended for a one-to-many broadcast of messages through a virtual channel called [Topic]
- It is a push-based/broadcast model, where messages are automatically broadcast to consumers instead of being pulled.
- In pub-and-sub the receiver should be register to the topic before the sender’ sending to the message – because: the JSM provider should get which consumers are waiting the sent message to the topic.
- Publishers and subscribers of a message have a timing dependency. A client that subscribes to a topic can consume only messages published after the client has created a registration to the topic.
- In pub-and-sub the message remains in the topic until all consumers have read the message.
JMS queues and topics are the JMS Destinations and are bound in the JNDI environment and made available to J2EE applications.
- It is intended for a one-to-many broadcast of messages through a virtual channel called [Topic]
- It is a push-based/broadcast model, where messages are automatically broadcast to consumers instead of being pulled.
- In pub-and-sub the receiver should be register to the topic before the sender’ sending to the message – because: the JSM provider should get which consumers are waiting the sent message to the topic.
- Publishers and subscribers of a message have a timing dependency. A client that subscribes to a topic can consume only messages published after the client has created a registration to the topic.
- In pub-and-sub the message remains in the topic until all consumers have read the message.
JMS queues and topics are the JMS Destinations and are bound in the JNDI environment and made available to J2EE applications.

2.2 Messaging Consumption Approaches
A queue or topic consumption can be either synchronous or asynchronous.
Synchronously:
A subscriber or a receiver explicitly fetches the message from the destination by calling the receive method. The receive method can block until a message arrives or can time out if a message does not arrive within a specified time limit.
Asynchronously:
A Subscriber or a receiver can register a message listener with a consumer. A message listener is similar to an event listener. Whenever a message arrives at the destination, the JMS provider delivers the message by calling the listener’s onMessage method without hanging.
A queue or topic consumption can be either synchronous or asynchronous.
Synchronously:
A subscriber or a receiver explicitly fetches the message from the destination by calling the receive method. The receive method can block until a message arrives or can time out if a message does not arrive within a specified time limit.
Asynchronously:
A Subscriber or a receiver can register a message listener with a consumer. A message listener is similar to an event listener. Whenever a message arrives at the destination, the JMS provider delivers the message by calling the listener’s onMessage method without hanging.
3. JMS Provider
There are several JMS Providers like Oracle JMS Provider (Oracle Application Server JMS and Oracle JMS),WebSphere MQ, SonicMQ, and SwiftMQ …etc ; You can choose JMS provider depending on their integration and quality-of-service (QOS) requirements.
There are several JMS Providers like Oracle JMS Provider (Oracle Application Server JMS and Oracle JMS),WebSphere MQ, SonicMQ, and SwiftMQ …etc ; You can choose JMS provider depending on their integration and quality-of-service (QOS) requirements.
Before creating JMS clients, it is required to configure the JMS Ports, the connection factories and destinations (Queue/Topic) for the accessed JMS Provider and this configuration steps will be different from JMS provider to other.
Imp Note: in our article we are covering Oracle Application Server JMS.
3.1.1 Configuring OracleAS JMS Ports
Use the
Oracle Enterprise Manager 10g to configure the port range for OracleAS JMS. The default range is between 3201 and 3300. Use the
From the OC4J Home page, select the Administration page, then the Instance Properties column, then Server Properties. Scroll to the Multiple VM Configuration section.
3.1.2 Configuring Destination Objects in JMS Provider environment
OracleAS JMS Destination –queue or Topic- objects are configured in the
jms.xml file. OracleAS JMS is already installed with OC4J, so the only configuration necessary is for the queues, topics, and their connection factories that your applications use.OracleAS JMS Destination –queue or Topic- objects are configured in the
From the OC4J Home page, select the Administration page, then the Enterprise Messaging Service column, then JMS Destinations and JMS Connection Factories.
Note: The jsm.xml could be configured manually in J2EEHome/OC4JHOME/Config.

4. JMS API Programming Model
After setting the JMS provider environment, it is the time to build JMS Clients (producer or consumer client).
The basic building blocks of a JMS application consist of
1- Access JMS provider
2- Create administered Connection: connection factories and destinations
3- Create Connection
4- Create Session
5- Create Producer and consumer
6- Create Message
7- Send and receive Messages

4.1 Accessing JMS provider
Context ctx = new InitialContext(); ( if lookup in the current vendor)
Or
Hashtable env = new Hashtable();
String initialContextFactory="com.evermind.server.rmi.RMIInitialContextFactory";
String securityPrincipal="userName";
String credentials="userPassword";
env.put( Context.INITIAL_CONTEXT_FACTORY,initialContextFactory );
env.put( Context.SECURITY_PRINCIPAL, securityPrincipal );
env.put( Context.SECURITY_CREDENTIALS, credentials);
ctx = new InitialContext(env);
4.2 Creating administered Connection: connection factories and destinations
4.2.1 Connection Factory:
A connection factory is the object a client uses to create a connection with a provider, Each connection factory is an instance of either the QueueConnectionFactory or the TopicConnectionFactory interface.a pair of connection factories come preconfigured with the J2EE SDK and are accessible as soon as you start the service.
QueueConnectionFactory queueConnectionFactory =
(QueueConnectionFactory) ctx.lookup("jms/QueueConnectionFactory");
TopicConnectionFactory topicConnectionFactory =
(TopicConnectionFactory) ctx.lookup("jms/TopicConnectionFactory");
4.2.2 Destination:
A destination is the object a client uses to specify the target of messages it produces and the source of messages it consumes.
Queue myQueue = (Queue) ctx.lookup("jms/MyQueue");
Topic myTopic = (Topic) ctx.lookup("jms/MyTopic");
4.3 Create Connection
A connection encapsulates a virtual connection with a JMS provider. A connection could represent an open TCP/IP socket between a client and a provider service daemon. You use a connection to create one or more sessions.
QueueConnection queueConnection =
queueConnectionFactory.createQueueConnection();
TopicConnection topicConnection =
topicConnectionFactory.createTopicConnection();
Note: When an application completes, you need to close any connections that you have created. Failure to close a connection can cause resources not to be released by the JMS provider. queueConnection.close(); topicConnection.close();
4.4 Create Session
A session is a single-threaded context for producing and consuming messages, A session provides a transactional context with which to group a set of sends and receives into an atomic unit of work.
QueueSession queueSession =
queueConnection.createQueueSession(false, Session.AUTO_ACKNOWLEDGE);
TopicSession topicSession =
topicConnection.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
The first argument means that the session is not transacted; the second means that the session automatically acknowledges messages when they have been received successfully.
4.5 Create Message Producer and consumer
A message producer and consumer are objects which created by a session and are used for sending and receiving messages to a destination.
Producer:
QueueSender queueSender = queueSession.createSender(myQueue);
TopicPublisher topicPublisher = topicSession.createPublisher(myTopic);
Consumer:
QueueReceiver queueReceiver = queueSession.createReceiver(myQueue);
TopicSubscriber topicSubscriber = topicSession.createSubscriber(myTopic);
4.6 Create Message
The JMS API defines five message types [ TextMesssage, MapMessage, BytesMessage, StreamMessage, ObjectMessage, Message] , which allow you to send and to receive data in many different forms and provide compatibility with existing messaging formats and provides some predefined property names that a provider may support. The use of either predefined properties or user-defined properties is optional.
TextMessage message = queueSession.createTextMessage();
message.setText(msg_text); // msg_text is a String
4.7 Sending and receiving Messages
Sending:
QueueSender and TopicPublisher can be used to send the messages.
queueSender.send(message);
topicPublisher.publish(message);
Receiving:
QueueReceiver and a TopicSubscriber can be used to receive the messages at any time after calling start method.
queueConnection.start();
--> To consume a message synchronously you can use receive method as following:
Message m = queueReceiver.receive();
or
Message m = queueReceiver.receive(1000); // time out after a second
if (m instanceof TextMessage) {
TextMessage message = (TextMessage) m;
System.out.println("Reading message: " + message.getText());
} else {
// Handle error
}
--> To consume a message asynchronously you will use message listener where it is an object that acts as an asynchronous event handler for messages. This object implements the MessageListener interface, which contains one method, onMessage. In the onMessage method, you define the actions to be taken when a message arrives.
The message listener will be registered with a specific QueueReceiver or TopicSubscriber by using the setMessageListener method. For example, if you define a class named QueueListener that implements the MessageListener interface, you can register the message listener as follows:
QueueListener queueListener = new queueListener();
queueReceiver.setMessageListener(queueListener);
Important notes:
1- The setmessageListener method will throw Exception if it is running in Web or EJB Container; it should be used under Client container. So to handle the asynchronous consumption in J2EE 1.3 platform you will need to use Message Driven Bean which is a special kind of message listener.
2- If you call start before you register the message listener, you are likely to miss messages.
References:
Java Message Service O'Reilly [Richard Monson-Haefel ,David A. Chappell]
EJB 3 Developer Guide [ Michael Sikora ]
http://java.sun.com/javaee/5/docs/tutorial/doc/bncdq.html
http://download.oracle.com/docs/cd/B14099_19/web.1012/b14012/jms.htm
http://mediasrv.ns.ac.yu/extra/java2/tutorials/jms_tutorial/index.html
Friday, January 30, 2009
Thursday, December 4, 2008
Democracy in our Workplace
Democracy behavior is rare in our life these days and most of us understand it wrong and miss its usages especially in the workplaces. You can find dictator or may find democratic dictator but no pure democratic, may that is related by our culture or traditions.
Just for your note; it is saying that the democratic dictator behavior is the most successful way in workplaces specific in our societies, for me I am not agree with this saying because the democratic dictator is still dictator J with mask of democratic but I believe that there are situations required from you to be dictator but using smart way to win who around you (use mask of democratic) – Democratic dictator == do what you want but with other agreements.
I read good article about the democracy
"http://www.startupnation.com/series/104/9121/5-advantages-democratic-workplace.htm" and its usage in workplace so I liked to summarize it to you as following:
The democracy helps the workplace/environment/companies to
- be a Talent Magnet
Most of talent people want to work where they feel appreciated and heard because they always have good ideas which are required to be discussed.
- Come Up With Smarter Ideas
As James Surowiecki writes, tap the wisdom of your crowd. Chances are the employees developing your products or services, fielding customer service calls or selling to clients have some great insights for your Next Big Idea – if only someone would listen.
- Work Fast
May the decision-making process, if it involves reaching a consensus, can take time.
But the time and attention paid to everyone’s point of view only makes the execution phase faster once the decision is made because When employees have a say and understand the “why” behind a decision the execution is faster, more efficient and devoid of resistance.
- Have Happier Employees
Being engaged, having a say, and being treated as an intelligent human being makes people happy – and creates a happier place to work as well.
- Boost the Bottom Line
Democracy means a leaner, faster, happier and more innovative company –factors which give the bottom line a boost.
Just for your note; it is saying that the democratic dictator behavior is the most successful way in workplaces specific in our societies, for me I am not agree with this saying because the democratic dictator is still dictator J with mask of democratic but I believe that there are situations required from you to be dictator but using smart way to win who around you (use mask of democratic) – Democratic dictator == do what you want but with other agreements.
I read good article about the democracy
"http://www.startupnation.com/series/104/9121/5-advantages-democratic-workplace.htm" and its usage in workplace so I liked to summarize it to you as following:
The democracy helps the workplace/environment/companies to
- be a Talent Magnet
Most of talent people want to work where they feel appreciated and heard because they always have good ideas which are required to be discussed.
- Come Up With Smarter Ideas
As James Surowiecki writes, tap the wisdom of your crowd. Chances are the employees developing your products or services, fielding customer service calls or selling to clients have some great insights for your Next Big Idea – if only someone would listen.
- Work Fast
May the decision-making process, if it involves reaching a consensus, can take time.
But the time and attention paid to everyone’s point of view only makes the execution phase faster once the decision is made because When employees have a say and understand the “why” behind a decision the execution is faster, more efficient and devoid of resistance.
- Have Happier Employees
Being engaged, having a say, and being treated as an intelligent human being makes people happy – and creates a happier place to work as well.
- Boost the Bottom Line
Democracy means a leaner, faster, happier and more innovative company –factors which give the bottom line a boost.
Thursday, September 4, 2008
Ramadan Kareem 1429
Al Salamo Alikom Wa Rahmat Allah
Dear all,
We wish you all blessed Ramadan and may Allah grant all of you mercy and forgiveness in the holy month :)
For the occasion of Ramadan, sure all of us are trying to do acts of Worship and charities as much as we can, may Allah forgive us Amean.
And one of the most important Acts is the Donation (Sadaka) So we suggest to collect Daily Donation -whatever it is- and for more favors lets work on the Sadaka El Garya so we have intention to get the donations of the first two weeks of Ramadan and put it in building Mosque/Masjed and we already have one which is located at “Abd El-hamid hamdy Street- Ahmed Essmat- Ain-Shams” .
If you want the favors to pour down to you in life or death please we are waiting for your response and your donations.
Our donations sure will do something good but with your donations will do something better.
So If you want to share please contact US
Inside ITS :
Teleco: Maged Emara and his back up is Doaa magd or Mona Gamal
Banking: Ahmed El Banna
HR : Mahmoud Attia
outSide :
you can contact me Isallah
Jazakom Allah Kol 7'ear
Dear all,
We wish you all blessed Ramadan and may Allah grant all of you mercy and forgiveness in the holy month :)
For the occasion of Ramadan, sure all of us are trying to do acts of Worship and charities as much as we can, may Allah forgive us Amean.
And one of the most important Acts is the Donation (Sadaka) So we suggest to collect Daily Donation -whatever it is- and for more favors lets work on the Sadaka El Garya so we have intention to get the donations of the first two weeks of Ramadan and put it in building Mosque/Masjed and we already have one which is located at “Abd El-hamid hamdy Street- Ahmed Essmat- Ain-Shams” .
If you want the favors to pour down to you in life or death please we are waiting for your response and your donations.
Our donations sure will do something good but with your donations will do something better.
So If you want to share please contact US
Inside ITS :
Teleco: Maged Emara and his back up is Doaa magd or Mona Gamal
Banking: Ahmed El Banna
HR : Mahmoud Attia
outSide :
you can contact me Isallah
Jazakom Allah Kol 7'ear
Sunday, July 20, 2008
It is the time to join our ITS-GBS World

Join ITS-GBS World and let us grow Together :)
Note:
if you have a lot of Questions about ITS
and you want to know why Join ITS,
Then you can contact me - may I can help- or check www.its.ws
Wednesday, July 16, 2008
The Woman engineer is Ideal Volunteer
The woman is four times better than men in volunteer work but the woman engineer is Idea volunteer to serve her society because
The Natural of Woman Is
– Able to multi-task
– Emotional: Feel for others
– Patient
– Willing to devote more personal time to serve her society
And characteristic of the engineer:
– Creative
– Smart Problem Solver
– Systematic Thinker
The only challenges for volunteer
– Time Availability
– Work commitments and family commitments
"You make a living by what you get... But you make a life by what you give." Winston Churchill
Characteristics of successful and powerful Manager
The managers are the main part of your support team. The right manager can lead you to new levels of success in your career, however choosing the wrong one can be fatal to your growing career so we tried to summarize the main characteristics for successful Manager as following
The successful and powerful manager must be
1- A very organized person: Should know how many tasks there to accomplish and keep up with and how hard it can be. Without organization you will open the door for the career to become a mess.
2- A responsible Person: Should not oversee only everything you are doing, but also everything supports you and your work.
3- A multi-tasker Person: should organize, support, keep you happy and ease up life and career stress off of you so you can do what you do best.
4- A leader: should be Strong and wealthy technical leader over you to satisfy your need. If your manager is a weak leader your career is going to be headed for disaster.
5- A well-connected person: should have good communication skills, While many times none connected individuals have been able to lead careers to superstardom.
6- An ever-alert conscience: should be a far-removed from self-interest, nepotism and bias toward any group or party and not self-opinionated and should not utter coarse words or severe looks to grant rights to those who deserve them.
Finally good manager can take you far while bad management can lead your career into the ground as employee or employer. So give it great thought and consider all of these thoughts the next time you evaluate, hire and treat with Manager .
References:
http://www.syntelinc.com/syntelligence/index.aspx?id=287 http://wiki.answers.com/Q/What_are_the_necessary_characteristics_for_a_manager http://musicindustry.suite101.com/article.cfm/choosing_a_music_manager http://yementimes.com/article.shtml?i=906&p=opinion&a=2
Friday, June 27, 2008
The Trust Value in Workplace
Saturday, January 26, 2008
The real reason of success "Teamwork"
Teamwork is Cooperative effort by the members of a group or team to achieve a common goal or missions and as we all know that it is not used just in work but we can find it in all the needs of life.
Nowadays most of projects require that people work together, so teamwork has become an important concept everywhere. Effective teams are an intermediary goal towards getting good, sustainable results.
It is so deep field and I can got everything about it but there is two questions took my attention
How we apply the teamwork concept?
1- Listen to other people's ideas. When people are allowed to freely express their ideas, these initial ideas will produce other ideas.
2- Ask questions, interact, and discuss the objectives of the team.
3- Treat others with respect and to support their ideas.
4- All the members should trust each other.
5- Help one's coworkers, which is the general theme of teamwork.
6- Share with the team to create an environment of teamwork.
7- For a team to work effectively it is essential team members acquire communication skills and use effective communication channels between one another.
8- Be diplomat and tolerant.
There is a wonderful saying says "A Teamworker is the oil that keeps the machine running...the yeast that helps the dough rise. They are good listeners , diplomats, talented at smoothing over conflicts , help parties and understand each other without becoming confrontational" and unfortunately it is rarely in our society these days.
What are the laws of successful teamwork?
1- The Significance: One Is Too Small a Number to Achieve Greatness
2- The Big Picture: The Goal is More Important Than the Role
3- The Niche: All members Have a Place Where They Add the Most Value
4- The Great Challenge: As the Challenge Escalates, the Need for Teamwork Elevates
5- The Chain: The Strength of the Team Is Impacted by Its Weakest Link
6- The Bad Apple: Rotten Attitudes Ruin a Team
7- The Countability: Team-mates Must Be Able to Count on Each Other When It Counts
8- The Identity: Shared Values Define the Team
9- The Communication: Interaction Fuels Action
Amazing things could be accomplished today if we could get members and leaders to trust and commit to the teamwork process of joint problem solving, consensus decision making and shared leadership.
The lack of teamwork’ is blamed for such a wide variety of everyday business dilemmas -- dilemmas like late delivery, poor quality, a blown budget or poor customer management. That because the people in businesses do not understand the real meaning of teamwork concept.
Nowadays most of projects require that people work together, so teamwork has become an important concept everywhere. Effective teams are an intermediary goal towards getting good, sustainable results.
It is so deep field and I can got everything about it but there is two questions took my attention
How we apply the teamwork concept?
1- Listen to other people's ideas. When people are allowed to freely express their ideas, these initial ideas will produce other ideas.
2- Ask questions, interact, and discuss the objectives of the team.
3- Treat others with respect and to support their ideas.
4- All the members should trust each other.
5- Help one's coworkers, which is the general theme of teamwork.
6- Share with the team to create an environment of teamwork.
7- For a team to work effectively it is essential team members acquire communication skills and use effective communication channels between one another.
8- Be diplomat and tolerant.
There is a wonderful saying says "A Teamworker is the oil that keeps the machine running...the yeast that helps the dough rise. They are good listeners , diplomats, talented at smoothing over conflicts , help parties and understand each other without becoming confrontational" and unfortunately it is rarely in our society these days.
What are the laws of successful teamwork?
1- The Significance: One Is Too Small a Number to Achieve Greatness
2- The Big Picture: The Goal is More Important Than the Role
3- The Niche: All members Have a Place Where They Add the Most Value
4- The Great Challenge: As the Challenge Escalates, the Need for Teamwork Elevates
5- The Chain: The Strength of the Team Is Impacted by Its Weakest Link
6- The Bad Apple: Rotten Attitudes Ruin a Team
7- The Countability: Team-mates Must Be Able to Count on Each Other When It Counts
8- The Identity: Shared Values Define the Team
9- The Communication: Interaction Fuels Action
Amazing things could be accomplished today if we could get members and leaders to trust and commit to the teamwork process of joint problem solving, consensus decision making and shared leadership.
The lack of teamwork’ is blamed for such a wide variety of everyday business dilemmas -- dilemmas like late delivery, poor quality, a blown budget or poor customer management. That because the people in businesses do not understand the real meaning of teamwork concept.
Saturday, November 17, 2007
LDAP Structure
LDAP directory servers store their data hierarchically.
Why break things up into a hierarchy? It is easier in relationships understanding , You may wish to grant permissions to a group of individuals based on the directory structure and Combined with replication, you can tailor the layout of your directory structure to minimize WAN bandwidth utilization.
DN (Distinguish Name) it is The top level of the LDAP directory tree is the base, referred to as the "base DN." A base DN usually takes one of the three forms listed here.
Let's assume I work at a US electronic commerce company called FooBar which is on the Internet at foobar.com
1- o="FooBar, Inc.", c=US (base DN in X.500 format)
O refers to the organization, C refers to company headquarters.
this was the preferred method of specifying your base DN but these days, most companies are (or plan to be) on the Internet. And what with Internet globalization, using a country code in the base DN probably made things more confusing in the end. In time, the X.500 format evolved into the other formats listed below.
Why break things up into a hierarchy? It is easier in relationships understanding , You may wish to grant permissions to a group of individuals based on the directory structure and Combined with replication, you can tailor the layout of your directory structure to minimize WAN bandwidth utilization.
DN (Distinguish Name) it is The top level of the LDAP directory tree is the base, referred to as the "base DN." A base DN usually takes one of the three forms listed here.
Let's assume I work at a US electronic commerce company called FooBar which is on the Internet at foobar.com
1- o="FooBar, Inc.", c=US (base DN in X.500 format)
O refers to the organization, C refers to company headquarters.
this was the preferred method of specifying your base DN but these days, most companies are (or plan to be) on the Internet. And what with Internet globalization, using a country code in the base DN probably made things more confusing in the end. In time, the X.500 format evolved into the other formats listed below.
2- o=foobar.com (base DN derived from the company's Internet presence)
This format is fairly straightforward, using the company's Internet domain name as the base.
3- dc=foobar, dc=com (base DN derived from the company's DNS domain components)
this format is split into DC(domain components): foobar.com becomes dc=foobar, dc=com.
In theory, this could be slightly more versatile, though it's a little harder for end users to remember. And it is the most recommended format.
Underneath your directory's base, you'll want to create containers that logically separate your data. most LDAP directories set these logical separations up as OU entries. OU stands for "Organizational Unit," which in X.500 was used to indicate the functional organization within a company.
LDAP directory tree (not including individual entries) might look like this:
dc=foobar, dc=com
ou=customers
ou=asia
ou=europe
ou=usa
ou=employees
ou=rooms
ou=groups
ou=assets-mgmt
ou=nisgroups
ou=recipes
Individual LDAP records
All entries stored in an LDAP directory have a unique "Distinguished Name" or DN.
* The DN for each LDAP entry is composed of two parts: the Relative Distinguished Name (RDN) and the location within the LDAP directory where the record resides.
The RDN is the portion of your DN that is not related to the directory tree structure. Most items that you'll store in an LDAP directory will have a name, and the name is frequently stored in the cn (Common Name) attribute.
Since nearly everything has a name, most objects you'll store in LDAP will use their cn value as the basis for their RDN.
Friday, November 16, 2007
Information Directory and LDAP Chitchat
The LDAP can enable almost any application, running on almost any computer platform, to obtain information from your LDAP directory. And that directory can be used to store a broad range of data: email address and mail routing information, HR data, public security keys, contact lists, and much more.
What is the directory (information Directory)?
A directory is a way of organizing information so that you can find it easily. It lists Objects .for example, people, books in a library, merchandise in a department store—and gives details about each one.
A directory is a specialized database that stores collections of information about objects. These collections of information are called entries, and they make up the individual building blocks of the directory. A directory might contain entries about, for example, employees, their job titles and salaries.
While a directory is a type of database, it is designed very differently from a relational database. For example,
1- Typical use of a directory involves a relatively small number of data updates, and a potentially very large number of data retrievals. By contrast, typical use of a relational database involves continuous recording of transactions, but retrievals are done relatively infrequently, when, for example, an employee needs to generate a monthly report. In short, a directory is designed to be primarily read-focused, in contrast to a relational database that is primarily write-focused.
2- Directories also differ from relational databases in that they use relatively simple transactions to store and retrieve relatively small units of data—for example, an e-mail address, a telephone number, or a digital portrait. By contrast, a relational database is designed to handle large and diverse transactions using large data items and many operations so LDAP directories are not well suited for storing data where changes are frequent.
3- In a directory, each entry is associated with a unique distinguished name that identifies it across multiple servers and administrative regions. Because they are inherently global, directories can provide users and applications with “location independence,” making identical information transparently available throughout the system.
4- Directory allows you to securely delegate read and modification authority based on your specific needs using ACIs (collectively, an ACL, or Access Control List). For example, your facilities group might be given access to change an employee's location, cube, or office number, but not be allowed to modify entries for any other fields.
Notes:
- Don’t even think of using it as a database back end for your high-volume e-commerce site .
- LDAP is used to access this Directory information by easily and standard way and The directory is known as an LDAP directory.
What is the LDAP?
LDAP (Lightweight Directory Access Protocol) is based on the X.500 standard, but significantly simpler and more readily adapted to meet custom needs. LDAP is especially suited for deployment with Internet-centric because it support TCP/IP, "thin-client" applications.
So LDAP isn't a database at all, but a protocol used to access information stored in an information directory ( LDAP directory).
The LDAP protocol is both cross-platform and standards-based, so applications needn't worry about the type of server hosting the directory.
Note:
Oracle Internet Directory implements (OID) Version 3 of LDAP, which was approved as a proposed Internet Standard by the Internet Engineering Task Force (IETF).where that the OID is directory service implemented as an application on Oracle Database to enable retrieval of information about dispersed users and network resources.
When should you use LDAP to store your data?
If the answer to each of the following questions is Yes, then storing your data in LDAP is a good idea.
1- Would you like your data to be available cross-platform?
2- Do you need to access this data from a number of computers or applications?
3- Do the individual records you're storing change a few times a day or less, on average?
4- Does it make sense to store this type of data in a flat database instead of a relational database? That is, could you effectively store all the data for a given item in a single record?
Reference:
Summarized from an Introduction to LDAP - Michael Donnelly
http://www.ldapman.org/articles/intro_to_ldap.html
What is the directory (information Directory)?
A directory is a way of organizing information so that you can find it easily. It lists Objects .for example, people, books in a library, merchandise in a department store—and gives details about each one.
A directory is a specialized database that stores collections of information about objects. These collections of information are called entries, and they make up the individual building blocks of the directory. A directory might contain entries about, for example, employees, their job titles and salaries.
While a directory is a type of database, it is designed very differently from a relational database. For example,
1- Typical use of a directory involves a relatively small number of data updates, and a potentially very large number of data retrievals. By contrast, typical use of a relational database involves continuous recording of transactions, but retrievals are done relatively infrequently, when, for example, an employee needs to generate a monthly report. In short, a directory is designed to be primarily read-focused, in contrast to a relational database that is primarily write-focused.
2- Directories also differ from relational databases in that they use relatively simple transactions to store and retrieve relatively small units of data—for example, an e-mail address, a telephone number, or a digital portrait. By contrast, a relational database is designed to handle large and diverse transactions using large data items and many operations so LDAP directories are not well suited for storing data where changes are frequent.
3- In a directory, each entry is associated with a unique distinguished name that identifies it across multiple servers and administrative regions. Because they are inherently global, directories can provide users and applications with “location independence,” making identical information transparently available throughout the system.
4- Directory allows you to securely delegate read and modification authority based on your specific needs using ACIs (collectively, an ACL, or Access Control List). For example, your facilities group might be given access to change an employee's location, cube, or office number, but not be allowed to modify entries for any other fields.
Notes:
- Don’t even think of using it as a database back end for your high-volume e-commerce site .
- LDAP is used to access this Directory information by easily and standard way and The directory is known as an LDAP directory.
What is the LDAP?
LDAP (Lightweight Directory Access Protocol) is based on the X.500 standard, but significantly simpler and more readily adapted to meet custom needs. LDAP is especially suited for deployment with Internet-centric because it support TCP/IP, "thin-client" applications.
So LDAP isn't a database at all, but a protocol used to access information stored in an information directory ( LDAP directory).
The LDAP protocol is both cross-platform and standards-based, so applications needn't worry about the type of server hosting the directory.
Note:
Oracle Internet Directory implements (OID) Version 3 of LDAP, which was approved as a proposed Internet Standard by the Internet Engineering Task Force (IETF).where that the OID is directory service implemented as an application on Oracle Database to enable retrieval of information about dispersed users and network resources.
When should you use LDAP to store your data?
If the answer to each of the following questions is Yes, then storing your data in LDAP is a good idea.
1- Would you like your data to be available cross-platform?
2- Do you need to access this data from a number of computers or applications?
3- Do the individual records you're storing change a few times a day or less, on average?
4- Does it make sense to store this type of data in a flat database instead of a relational database? That is, could you effectively store all the data for a given item in a single record?
Reference:
Summarized from an Introduction to LDAP - Michael Donnelly
http://www.ldapman.org/articles/intro_to_ldap.html
Wednesday, April 11, 2007
Oracle BPEL Process Manager Client API
We did not find direct WebCenter way to access the BPEL process, but we found API “Oracle BPEL Process Manager Client API”.
This API support invoking the BPEL Process programmatically via a Java Code. The API is slightly different depending on whether you are invoking a two-way operation (which has both input and output messages) Synchronous proces or a one-way operation (which just has an input message and returns no result) Asynchronous process .
So this API provides to us two services Post Service and Request Service where its using depends on the type of BPEL process.
Asynchronous BPEL Process:
It provides only initiate operation which has input without output so we use post function to access this Operation.
Synchronous BPEL Process:
It provides only also Process operation which has input and out put so we use request function to access this operation.
**********************************************************************
How we use this API?
1- Setting the configuration for connecting to Oracle BPEL Process Manger.
Hashtable jndi = new Hashtable ();
jndi.put (Context.PROVIDER_URL, "opmn:ormi://10.10.2.141:6003/orabpel");
jndi.put (Context.INITIAL_CONTEXT_FACTORY, "com.evermind.server.rmi.RMIInitialContextFactory");
jndi.put (Context.SECURITY_PRINCIPAL,”oc4jadmin”); // username of Bpel Manager
jndi.put (Context.SECURITY_CREDENTIALS,”welcome1”); //password of BPEL Manager
jndi.put ("dedicated.connection",”true”);
Locator = new Locator (“default”,”welcome1”); // default is the domain Name and welcome1 is the
Password of the domain.
deliveryService = (IDeliveryService) locator.lookupService (IDeliveryService.SERVICE_NAME);
Locator class: used to connect to the domain on the BPEL Process Manager and fetch a list of BPEL processes deployed on that server. In this case, we use the Locator class to return a handle to an IDeliveryService instance.
IDeliveryService Interface: used to invoke/initiate BPEL processes deployed on a BPEL Process Manager.
2- Passing XML messages via Java.
String SchemaInputXML = "" +
"ererer " +
"dgfdggdg " +
" ";
nm = new NormalizedMessage ();
nm.addPart ("payload", SchemaInputXML);
NormalizedMessage class: construct an XML message, construct an input message for request or construct an Output Message for response.
3- Invoking the operation.
Invoking Synchronous Process:
It call process operation which return output message and need input message
So we use the IDeliveryService.request () methods to access this process.
NormalizedMessage res = deliveryService.request ("userBPEL", "process", nm);
// userBPEL is Process Name and process is operation method name and nm is the input message.
Invoking Asynchronous Process:
It call initiate operation which need input message and does not return output so
We use IDEliveryService.post () method to access this process.
deliveryService.post (“userBPEL”,”initiate”, nm);
**********************************************************************
How to retrieve the Result?
Synchronous process:
It is easy to retrieve the result using normalizedMessage object as we saw in the synchronous invoking.
Asynchronous process:
It is not easy to get the result but we can inform the user of the process by making the Process send JMS Message or email (I did not try it ...I just read it) Or using conversation ID to identify the process instance before posting and after that use this ID to identify a specific instance and retrieve status information from it .
String convId = GUIDGenerator.generateGUID();
nm.setProperty(NormalizedMessage.CONVERSATION_ID, convId);
deliveryService.post(processID,operationName, nm);
IInstanceHandle fg = (IInstanceHandle)locator.lookupInstanceByConversationId(convId);
**********************************************************************
What we need to use this API?
oc4jclient.jar, Orabpel-common.jar and Orabpel.jar
This API support invoking the BPEL Process programmatically via a Java Code. The API is slightly different depending on whether you are invoking a two-way operation (which has both input and output messages) Synchronous proces or a one-way operation (which just has an input message and returns no result) Asynchronous process .
So this API provides to us two services Post Service and Request Service where its using depends on the type of BPEL process.
Asynchronous BPEL Process:
It provides only initiate operation which has input without output so we use post function to access this Operation.
Synchronous BPEL Process:
It provides only also Process operation which has input and out put so we use request function to access this operation.
**********************************************************************
How we use this API?
1- Setting the configuration for connecting to Oracle BPEL Process Manger.
Hashtable jndi = new Hashtable ();
jndi.put (Context.PROVIDER_URL, "opmn:ormi://10.10.2.141:6003/orabpel");
jndi.put (Context.INITIAL_CONTEXT_FACTORY, "com.evermind.server.rmi.RMIInitialContextFactory");
jndi.put (Context.SECURITY_PRINCIPAL,”oc4jadmin”); // username of Bpel Manager
jndi.put (Context.SECURITY_CREDENTIALS,”welcome1”); //password of BPEL Manager
jndi.put ("dedicated.connection",”true”);
Locator = new Locator (“default”,”welcome1”); // default is the domain Name and welcome1 is the
Password of the domain.
deliveryService = (IDeliveryService) locator.lookupService (IDeliveryService.SERVICE_NAME);
Locator class: used to connect to the domain on the BPEL Process Manager and fetch a list of BPEL processes deployed on that server. In this case, we use the Locator class to return a handle to an IDeliveryService instance.
IDeliveryService Interface: used to invoke/initiate BPEL processes deployed on a BPEL Process Manager.
2- Passing XML messages via Java.
String SchemaInputXML = "
"
"
"
nm = new NormalizedMessage ();
nm.addPart ("payload", SchemaInputXML);
NormalizedMessage class: construct an XML message, construct an input message for request or construct an Output Message for response.
3- Invoking the operation.
Invoking Synchronous Process:
It call process operation which return output message and need input message
So we use the IDeliveryService.request () methods to access this process.
NormalizedMessage res = deliveryService.request ("userBPEL", "process", nm);
// userBPEL is Process Name and process is operation method name and nm is the input message.
Invoking Asynchronous Process:
It call initiate operation which need input message and does not return output so
We use IDEliveryService.post () method to access this process.
deliveryService.post (“userBPEL”,”initiate”, nm);
**********************************************************************
How to retrieve the Result?
Synchronous process:
It is easy to retrieve the result using normalizedMessage object as we saw in the synchronous invoking.
Asynchronous process:
It is not easy to get the result but we can inform the user of the process by making the Process send JMS Message or email (I did not try it ...I just read it) Or using conversation ID to identify the process instance before posting and after that use this ID to identify a specific instance and retrieve status information from it .
String convId = GUIDGenerator.generateGUID();
nm.setProperty(NormalizedMessage.CONVERSATION_ID, convId);
deliveryService.post(processID,operationName, nm);
IInstanceHandle fg = (IInstanceHandle)locator.lookupInstanceByConversationId(convId);
**********************************************************************
What we need to use this API?
oc4jclient.jar, Orabpel-common.jar and Orabpel.jar
Subscribe to:
Posts (Atom)




