HI Friends , That is right ..!!!
you can find microsoft jobs at
http://www.linkedin.com/jobs?viewResults=&sik=1208362132712
also you can find it at microsoft website
http://www.microsoft.com/careers/
so trust yourself and experience , and don't hesitate to apply for microsoft jobs
Wednesday, April 16, 2008
Do you want to work @ Google :)
HI Friends , That is right ..!!!
while i search on google search engine about something i find a link for google jobs ,
http://www.google.com/intl/en/jobs/
also you can find jobs at
http://www.linkedin.com/jobs?viewResults=&sik=1208362132712
Don't worry , I got 1st and 2nd interviews there .....
wait my next post to describe what happened ........ :)
so trust yourself and experience , and dont hesitate to apply for Google .
Note : at google jobs , you can create your job cart and finally apply for all positions
Thanks
while i search on google search engine about something i find a link for google jobs ,
http://www.google.com/intl/en/jobs/
also you can find jobs at
http://www.linkedin.com/jobs?viewResults=&sik=1208362132712
Don't worry , I got 1st and 2nd interviews there .....
wait my next post to describe what happened ........ :)
so trust yourself and experience , and dont hesitate to apply for Google .
Note : at google jobs , you can create your job cart and finally apply for all positions
Thanks
Jobs @ Al Fanar Co. KSA
Hi ,
We have the following vacancies at al fanar Co.
1- Dynamics NV Developer /KSA
http://www.amcham.org.eg/hr/recruitment/candidate/job_profile.asp?page=2&JobID=18422&EmployerID=1830
2- Software Development Section head /KSA
http://www.amcham.org.eg/hr/recruitment/candidate/job_profile.asp?page=2&JobID=18420&EmployerID=1830
3- Dynamics AX Consultant / KSA
http://www.amcham.org.eg/hr/recruitment/candidate/job_profile.asp?page=2&JobID=18424&EmployerID=1830
We have the following vacancies at al fanar Co.
1- Dynamics NV Developer /KSA
http://www.amcham.org.eg/hr/recruitment/candidate/job_profile.asp?page=2&JobID=18422&EmployerID=1830
2- Software Development Section head /KSA
http://www.amcham.org.eg/hr/recruitment/candidate/job_profile.asp?page=2&JobID=18420&EmployerID=1830
3- Dynamics AX Consultant / KSA
http://www.amcham.org.eg/hr/recruitment/candidate/job_profile.asp?page=2&JobID=18424&EmployerID=1830
Tuesday, April 15, 2008
Saturday, April 12, 2008
Egypt IT Companies
ITWorxA leading Egyptian software company providing outsourcing services, located in the Nasr City Free Zone.
Raya SoftwareProvides a wide range of enterprise level solutions and software applications.
OTSOrascom Technology Solutions provides a wide range of IT solutions and services.
Nile OnlineProvides Internet connectivity services.
NoorProvides Internet solutions and infrastructure.
Intercom EnterprisesProvides business solutions based on IBM technologies.
OpenCraftAn Egyptian software company providing IT solutions based on open source systems.
MacroCellA software company providing e-business and payment processing solutions.
GNS EgyptProvides e-business solutions.
SANDDevelops information systems.
IT SynergyProvides GIS and other services based on open source technology.
ConnectionDevelops GIS solutions.
quTIPProvides mobile information system solutions.
MSCIProvides consultancy, training, system integration and outsourcing services.
Giza SystemsDevelops information systems.
MicrotechAn Egyptian software company providing ERP solutions.
RITsolProvides ERP solutions.
ITGDevelops financial information systems.
AthearIT services company.
AssetAn Egyptian software company developing Arabic CMS products.
Comsys SoftwareDevelops retail management systems and other information systems.
EME ITProvides system integration solutions.
SICCAn Egyptian IT company providing barcode readers and other automatic data collection solutions.
AsgaTechAn Egyptian software company working in mobile solutions.
InformatiqueAn Egyptian software company providing Education systems and other solutions.
OmegaSoftDesigns and builds industrial ERP systems.
Bayan-TechProvides localization solutions.
RDIDevelops Arabic language technologies and multimedia CDs.
FC&EDDesigns and develops electronics devices and software.
Ebb & TideProvides web and multimedia solutions.
United OFOQDevelops HR software and other information systems.
4SProvides information systems and software development services.
SANAtechDevelops information systems and solutions based on open source technology.
Binary WorksDevelops web-based e-learning solutions.
IKDProvides Internet and wireless solutions.
Nile NetworksProvides network services.
eBSEGProvides e-business solutions.
EgyMarkProvides e-business solutions.
NRGDevelops enterprise solutions and web portals.
Cairo ITDevelops e-learning solutions.
Web Design and Development
GNSProvides web-based solutions for the tourism industry.
ArkanProvides web design, web development and hosting services.
Bit and BitsProvides website design and development services.
InSoftProvides website development services.
GozoorProvides web site design, web development and web hosting services.
Nile CreationsProvides web site design and development services.
MicroaxonProvides web development services.
We AreProvides advertising and web design services.
Design Co-ordinators InteractiveProvides web site desing, CD presentations and tours and Flash animation services.
LojineProvides web marketing and graphic desing services.
MRCO EgyptProvides web design and online marketing services.
Code-CornerProvides web development and web hosting services.
Hardware
IBSImports and assembles computer hardware.
In Alexandria
Online HorizonsProvides web development and web hosting services.
Arwa SoftwareDevelops information system software products.
From Kuwait
SakhrA leading software company with an R&D center in Egypt providing Arabic language technologies and enterprise solutions, located in the Nasr City Free Zone
HarfA software company based in Egypt developing Islamic software.
ITSoftCMMI level 4 certified Software Company located in the Nasr City Free Zone.
From Saudi Arabia
MCRProvides system integration and consulting services.
Arabia ITProvides off-the-shelf software programs and publications.
B9matA Saudi company providing web solutions with a development center in Cairo.
From UAE
Axiom ComputersDevelops information systems based on Oracle and J2EE technologies.
From USA
EDSProvides business and technology solutions.
SanteonA software company with offices in the US and Cairo.
eRevMaxDevelops software solutions for the tourism industry.
PicostationA US based software company with a development center in Egypt developing a mobile phone photo blogging application.
Net Pate GroupProvides web design and development services.
NordixValue added reseller of IT products. Provides network services.
From UK
LogicaCMGProvides system integration services for IT and wireless telecommunications.
From Germany
AMSProvides information systems for the medical sector.
From Australia
IOSAn Australian based software company with a development center in Egypt.
From Canada
NTG ClarityDelives network, telecom, IT and infrastructure solutions to network service providers and medium and large enterprises.
CIT GlobalProvides ecommerce solutions
Raya SoftwareProvides a wide range of enterprise level solutions and software applications.
OTSOrascom Technology Solutions provides a wide range of IT solutions and services.
Nile OnlineProvides Internet connectivity services.
NoorProvides Internet solutions and infrastructure.
Intercom EnterprisesProvides business solutions based on IBM technologies.
OpenCraftAn Egyptian software company providing IT solutions based on open source systems.
MacroCellA software company providing e-business and payment processing solutions.
GNS EgyptProvides e-business solutions.
SANDDevelops information systems.
IT SynergyProvides GIS and other services based on open source technology.
ConnectionDevelops GIS solutions.
quTIPProvides mobile information system solutions.
MSCIProvides consultancy, training, system integration and outsourcing services.
Giza SystemsDevelops information systems.
MicrotechAn Egyptian software company providing ERP solutions.
RITsolProvides ERP solutions.
ITGDevelops financial information systems.
AthearIT services company.
AssetAn Egyptian software company developing Arabic CMS products.
Comsys SoftwareDevelops retail management systems and other information systems.
EME ITProvides system integration solutions.
SICCAn Egyptian IT company providing barcode readers and other automatic data collection solutions.
AsgaTechAn Egyptian software company working in mobile solutions.
InformatiqueAn Egyptian software company providing Education systems and other solutions.
OmegaSoftDesigns and builds industrial ERP systems.
Bayan-TechProvides localization solutions.
RDIDevelops Arabic language technologies and multimedia CDs.
FC&EDDesigns and develops electronics devices and software.
Ebb & TideProvides web and multimedia solutions.
United OFOQDevelops HR software and other information systems.
4SProvides information systems and software development services.
SANAtechDevelops information systems and solutions based on open source technology.
Binary WorksDevelops web-based e-learning solutions.
IKDProvides Internet and wireless solutions.
Nile NetworksProvides network services.
eBSEGProvides e-business solutions.
EgyMarkProvides e-business solutions.
NRGDevelops enterprise solutions and web portals.
Cairo ITDevelops e-learning solutions.
Web Design and Development
GNSProvides web-based solutions for the tourism industry.
ArkanProvides web design, web development and hosting services.
Bit and BitsProvides website design and development services.
InSoftProvides website development services.
GozoorProvides web site design, web development and web hosting services.
Nile CreationsProvides web site design and development services.
MicroaxonProvides web development services.
We AreProvides advertising and web design services.
Design Co-ordinators InteractiveProvides web site desing, CD presentations and tours and Flash animation services.
LojineProvides web marketing and graphic desing services.
MRCO EgyptProvides web design and online marketing services.
Code-CornerProvides web development and web hosting services.
Hardware
IBSImports and assembles computer hardware.
In Alexandria
Online HorizonsProvides web development and web hosting services.
Arwa SoftwareDevelops information system software products.
From Kuwait
SakhrA leading software company with an R&D center in Egypt providing Arabic language technologies and enterprise solutions, located in the Nasr City Free Zone
HarfA software company based in Egypt developing Islamic software.
ITSoftCMMI level 4 certified Software Company located in the Nasr City Free Zone.
From Saudi Arabia
MCRProvides system integration and consulting services.
Arabia ITProvides off-the-shelf software programs and publications.
B9matA Saudi company providing web solutions with a development center in Cairo.
From UAE
Axiom ComputersDevelops information systems based on Oracle and J2EE technologies.
From USA
EDSProvides business and technology solutions.
SanteonA software company with offices in the US and Cairo.
eRevMaxDevelops software solutions for the tourism industry.
PicostationA US based software company with a development center in Egypt developing a mobile phone photo blogging application.
Net Pate GroupProvides web design and development services.
NordixValue added reseller of IT products. Provides network services.
From UK
LogicaCMGProvides system integration services for IT and wireless telecommunications.
From Germany
AMSProvides information systems for the medical sector.
From Australia
IOSAn Australian based software company with a development center in Egypt.
From Canada
NTG ClarityDelives network, telecom, IT and infrastructure solutions to network service providers and medium and large enterprises.
CIT GlobalProvides ecommerce solutions
Microsoft EDC at Cairo International Conference Center-Egypt
Hi Friends ,
Microsoft EDC http://www.edc2008. com EDC 2008 is the biggest Developers Conference of the year in Egypt, and is a critical event for any developer who wants to see the newest as well as the next-generation technology. EDC is full of sessions and activities that help you to learn the current and the future of the Microsoft Platform and get to know people who are as passionate about software as you are.
here is the Agenda of the two days http://www.edc2008. com/Agenda. aspx
it is for 100 L.E. for individual invitation.
Microsoft EDC http://www.edc2008. com EDC 2008 is the biggest Developers Conference of the year in Egypt, and is a critical event for any developer who wants to see the newest as well as the next-generation technology. EDC is full of sessions and activities that help you to learn the current and the future of the Microsoft Platform and get to know people who are as passionate about software as you are.
here is the Agenda of the two days http://www.edc2008. com/Agenda. aspx
it is for 100 L.E. for individual invitation.
Getting Started With AJAX (Videos...)
Hi Web developers friends , nowdays there is a new trend to use AJAX technology for building your business .
ASP.NET AJAX is a free framework for quickly creating efficient and interactive Web applications that work across all popular browsers.
ASP.NET AJAX is built-into ASP.NET 3.5. It is also available as a separate download for ASP.NET 2.0.With ASP.NET AJAX you can:Create next-generation interfaces with reusable AJAX components. Enhance existing pages using powerful AJAX controls with support for all modern browsers. Access remote services and data from the browser without tons of complicated script. Take advantage of the improved efficiency and ease of use in Visual Studio 2008, with its built-in support for ASP.NET AJAX, improved JavaScript support, and a new Web page designer interface
you can getting started from the folowing URL
http://www.asp.net/ajax/
ASP.NET AJAX is a free framework for quickly creating efficient and interactive Web applications that work across all popular browsers.
ASP.NET AJAX is built-into ASP.NET 3.5. It is also available as a separate download for ASP.NET 2.0.With ASP.NET AJAX you can:Create next-generation interfaces with reusable AJAX components. Enhance existing pages using powerful AJAX controls with support for all modern browsers. Access remote services and data from the browser without tons of complicated script. Take advantage of the improved efficiency and ease of use in Visual Studio 2008, with its built-in support for ASP.NET AJAX, improved JavaScript support, and a new Web page designer interface
you can getting started from the folowing URL
http://www.asp.net/ajax/
Getting Started with Silverlight
Microsoft Silverlight is a cross-browser, cross-platform client technology that helps you design, develop, and deliver media-enabled experiences and rich interactive applications on the Web.
Silverlight appeals to both designers and to developers because it provides a powerful platform that makes it easy to develop Web applications with professional-quality graphics, audio, and video for an engaging user experience. Silverlight also offers powerful tools that will improve the productivity of both designers and developers.
you can getting started from this link
http://msdn2.microsoft.com/en-us/library/bb404703.aspx
Silverlight appeals to both designers and to developers because it provides a powerful platform that makes it easy to develop Web applications with professional-quality graphics, audio, and video for an engaging user experience. Silverlight also offers powerful tools that will improve the productivity of both designers and developers.
you can getting started from this link
http://msdn2.microsoft.com/en-us/library/bb404703.aspx
Wednesday, April 9, 2008
What is the difference between shadow and override?
Hi friends , to be ready for technical interview at any corporations you can find alot of questions to any technology like MS.Net , Java , SQL Server , Oracle , Python ....etc at http://www.geekinterview.com
solve this question :
What is the difference between shadow and override ?
find posts there
http://www.geekinterview.com/question_details/31941
solve this question :
What is the difference between shadow and override ?
find posts there
http://www.geekinterview.com/question_details/31941
Download Microsoft SharePoint 2007 VHD and Getting Started
verview
The Microsoft VHD Test Drive Program provides customers with an enhanced server-based software evaluation experience that’s faster, better supported and more flexible. You can now access the entire catalog of pre-configured Microsoft and partner products and solutions in the VHD format and start evaluating and testing today from www.microsoft.com/vhd. This download enables you evaluate Microsoft Office SharePoint Server 2007. Microsoft Office SharePoint Server 2007 is an integrated suite of server capabilities that can help improve organizational effectiveness by providing comprehensive content management and enterprise search, accelerating shared business processes, and facilitating information-sharing across boundaries for better business insight. Office SharePoint Server 2007 supports all intranet, extranet, and Web applications across an enterprise within one integrated platform, instead of relying on separate fragmented systems. Additionally, this collaboration and content management server provides IT professionals and developers with the platform and tools they need for server administration, application extensibility, and interoperability. This fully functional pre-configured VHD provides you a trial software will automatically expire after 30 days. This is a preconfigured virtual machine contained within the Virtual Hard Disk (VHD) format. Virtual Server 2005 R2 is required to run this VHD. Please refer to the system requirements section for more details.
http://www.microsoft.com/downloads/details.aspx?FamilyID=67f93dcb-ada8-4db5-a47b-df17e14b2c74&DisplayLang=en
The Microsoft VHD Test Drive Program provides customers with an enhanced server-based software evaluation experience that’s faster, better supported and more flexible. You can now access the entire catalog of pre-configured Microsoft and partner products and solutions in the VHD format and start evaluating and testing today from www.microsoft.com/vhd. This download enables you evaluate Microsoft Office SharePoint Server 2007. Microsoft Office SharePoint Server 2007 is an integrated suite of server capabilities that can help improve organizational effectiveness by providing comprehensive content management and enterprise search, accelerating shared business processes, and facilitating information-sharing across boundaries for better business insight. Office SharePoint Server 2007 supports all intranet, extranet, and Web applications across an enterprise within one integrated platform, instead of relying on separate fragmented systems. Additionally, this collaboration and content management server provides IT professionals and developers with the platform and tools they need for server administration, application extensibility, and interoperability. This fully functional pre-configured VHD provides you a trial software will automatically expire after 30 days. This is a preconfigured virtual machine contained within the Virtual Hard Disk (VHD) format. Virtual Server 2005 R2 is required to run this VHD. Please refer to the system requirements section for more details.
http://www.microsoft.com/downloads/details.aspx?FamilyID=67f93dcb-ada8-4db5-a47b-df17e14b2c74&DisplayLang=en
docx2doc - convert from docx to docHome000-000-0000
A newbie's guide to .docx
.docx is the default file format in the latest version of Microsoft Word in Office 2007. All docs in the new office family is based upon an open, standardized specification called Office Open XML.
http://www.docx2doc.com/Newbies-Guide-To-docx.aspx
.docx is the default file format in the latest version of Microsoft Word in Office 2007. All docs in the new office family is based upon an open, standardized specification called Office Open XML.
http://www.docx2doc.com/Newbies-Guide-To-docx.aspx
Application Architecture for .NET: Designing Applications and Services
Hi .Net Developers , i found a good article at msdn.com .i think it so helpful for you to deeply understand [Application Architecture for .NET: Designing Applications and Services]
i finished reading it and it so so so helpful for me , so i hope all of you read it carefully
article : http://msdn2.microsoft.com/en-us/library/ms954595.aspx
note : nearly , i will post my service oriented architecture sample using c# according to the App Architecture and SOA
i finished reading it and it so so so helpful for me , so i hope all of you read it carefully
article : http://msdn2.microsoft.com/en-us/library/ms954595.aspx
note : nearly , i will post my service oriented architecture sample using c# according to the App Architecture and SOA
Amazing development on Sharepoint ...!
Amazing development on Sharepoint ...!
By utilizing the capabilities of the NetAdvantage for ASP.NET controls, developers can create highly customized and powerful WebParts for Microsoft Windows Sharepoint (WSS) or Microsoft Office SharePoint collaboration portals and plug them directly into the SharePoint framework. SharePoint is a powerful web-based portal package that organizations are adopting as a means of online communication and collaboration. By presenting a user with a series of WebParts organized onto a single web page, information can be delivered to multiple end users. This allows developers to build interfaces that contain specific information unique to each user.
http://www.infragistics.com/hot/sharepoint.aspx
By utilizing the capabilities of the NetAdvantage for ASP.NET controls, developers can create highly customized and powerful WebParts for Microsoft Windows Sharepoint (WSS) or Microsoft Office SharePoint collaboration portals and plug them directly into the SharePoint framework. SharePoint is a powerful web-based portal package that organizations are adopting as a means of online communication and collaboration. By presenting a user with a series of WebParts organized onto a single web page, information can be delivered to multiple end users. This allows developers to build interfaces that contain specific information unique to each user.
http://www.infragistics.com/hot/sharepoint.aspx
Microsoft .NET Framework SDK QuickStart (ASP.NET,Web Services...)
The QuickStart Tutorials are the fastest way to understand what the .NET Framework technology offers leading-edge developers. Inside you'll find information about the most compelling features of the .NET Framework technology, including how to put them immediately to work for you or your company
http://asp.dotnetheaven.com/
http://asp.dotnetheaven.com/
.NET Matters: Deadlock monitor
Reference : http://msdn2.microsoft.com/en-us/magazine/cc163352.aspx
.NET Matters
Deadlock monitor
Stephen ToubCode download available at: NETMatters2007_10.exe (156 KB) Browse the Code Online [ http://msdn2.microsoft.com/en-us/magazine/cc164433(printer).aspx ]
Q I'm using locks in my application to synchronize work on a bunch of threads. Unfortunately, I'm doing something incorrectly and my threads seem to just stop sometimes. I think I'm running into deadlocks, but I'm not sure how to find them. Is there any way I can do so programmatically? I'd like an exception to be thrown when a deadlock is encountered.
Q I'm using locks in my application to synchronize work on a bunch of threads. Unfortunately, I'm doing something incorrectly and my threads seem to just stop sometimes. I think I'm running into deadlocks, but I'm not sure how to find them. Is there any way I can do so programmatically? I'd like an exception to be thrown when a deadlock is encountered.
A First, it's important to understand what a deadlock among threads is and the conditions that lead to one. Threads deadlock when waiting on each other to release some resources, but by performing that blocking wait, they're not releasing the resources the other threads need in order to unblock. The threads can't make any progress until the resources are released, but because they're not making progress, the resources will never be released, the threads are locked up, and thus "deadlock." Many OS course textbooks will cite the four conditions necessary for a deadlock to occur:
A First, it's important to understand what a deadlock among threads is and the conditions that lead to one. Threads deadlock when waiting on each other to release some resources, but by performing that blocking wait, they're not releasing the resources the other threads need in order to unblock. The threads can't make any progress until the resources are released, but because they're not making progress, the resources will never be released, the threads are locked up, and thus "deadlock." Many OS course textbooks will cite the four conditions necessary for a deadlock to occur:
A limited number of a particular resource. In the case of a monitor in C# (what you use when you employ the lock keyword), this limited number is one, since a monitor is a mutual-exclusion lock (meaning only one thread can own a monitor at a time).
The ability to hold one resource and request another. In C#, this is akin to locking on one object and then locking on another before releasing the first lock, for example:
Copy Codelock(a)
{
lock(b)
{
...
}
}
No preemption capability. In C#, this means that one thread can't force another thread to release a lock.
A circular wait condition. This means that there is a cycle of threads, each of which is waiting for the next to release a resource before it can continue.
If any one of these conditions is not met, deadlock is not possible. The first condition is inherent to what a monitor is, so if you're using monitors, this one is set in stone. The second condition could be avoided by ensuring that you only ever lock one object at a time, but that's frequently not a feasible requirement in a large software project. The third condition could possibly be avoided in the Microsoft® .NET Framework by aborting or interrupting the thread holding the resource your thread requires, but a) that would require knowing which thread owned the resource, and b) that's an inherently dangerous operation (for the many reasons why, see msdn.microsoft.com/msdnmag/issues/05/10/Reliability). Thus, the way to avoid deadlocks is to avoid (or thwart) condition four.
In his article in the April 2006 issue (available at msdn.microsoft.com/msdnmag/issues/06/04/Deadlocks), Joe Duffy discusses several techniques for avoiding and detecting deadlocks, including one known as lock leveling. In lock leveling, locks are assigned numerical values, and threads must only acquire locks that have higher numbers than locks they have already acquired. This prevents the possibility of a cycle. It's also frequently difficult to do well in a typical software application today, and a failure to follow lock leveling on every lock acquisition invites deadlock.
Rather than prevent deadlocks wholesale, many systems attempt to detect them and then eliminate them once found. For example, SQL Server® can detect when deadlocks occur and abort one of the tasks involved in the cycle, thereby removing the deadlock. In his article, Joe builds a common language runtime (CLR) host that is capable of this form of deadlock detection in .NET applications that use monitors, a very cool feat. Unfortunately, using a custom CLR host isn't always practical for many .NET apps, including those that already have a custom host, like ASP.NET applications. As such, it would be beneficial to be able to utilize similar deadlock detection capabilities, without the need for a custom CLR host, such that these types of deadlocks could be detected at run time. This would be beneficial during development and testing phases, to identify coding errors where locks are being used incorrectly. It could also be used in production to detect and eliminate deadlocks as they occur (preventing a thread from causing one by blocking it from attempting the critical wait that would complete a cycle), however typical deadlock detection algorithms are costly and may not be appropriate in production systems for performance reasons. (I'll have a few comments on performance at the end of this column.)
To address this need, I've built a sample wrapper for the .NET System.Threading.Monitor class that includes deadlock detection capabilities. As with Monitor, my DdMonitor class provides Enter and Exit methods, and under the covers it delegates to the equivalent methods on Monitor. However, it also tracks monitor usage and throws exceptions when the attempted acquisition of a lock will complete a cycle, which would result in deadlock. For the rest of this column, I'll detail the implementation of this deadlock monitor class and provide additional information on its usage as well as on the advantages and disadvantages of its deployment.
The outline for the DdMonitor class is shown in Figure 1. From the start, note that DdMonitor does not completely mimic the public interface of System.Threading.Monitor. It provides the same public static TryEnter, Enter, and Exit methods, but it does not provide the Wait, Pulse, and PulseAll static public methods of its counterpart.
Figure 1 DdMonitor Class
Copy Codeclass DdMonitor
{
public static IDisposable Lock(object monitor) { ... }
public static void Enter(object monitor) { ... }
public static bool TryEnter(object monitor) { ... }
public static bool TryEnter(
object monitor, TimeSpan timeout) { ... }
public static bool TryEnter(
object monitor, int millisecondsTimeout) { ... }
public static void Exit(object monitor) { ... }
}
DdMonitor also provides a public static Lock method. Since the C# lock keyword provides a nice abstraction over Monitor, it's beneficial to provide a similar one for DdMonitor. Without the ability to modify the C# language, it's impossible for us to obtain identical syntax, but we can get close:
Copy Code// with Monitor
lock(obj) { ... }
// with DdMonitor
using(DdMonitor.Lock(obj)) { ... }
This syntactical feat is accomplished by implementing Lock, as shown in Figure 2. The Lock method delegates to DdMonitor.Enter to acquire the lock. However, it also instantiates a DdMonitorCookie object that implements IDisposable. This object's Dispose method will call DdMonitor.Exit to release the lock; this enables the developer to wrap DdMonitor.Lock in a C# using statement (Using in Visual Basic® or stack-allocation in C++/CLI) as shown previously.
Figure 2 Implementing the Lock Method
Copy Codepublic static IDisposable Lock(object monitor)
{
if (monitor == null) throw new ArgumentNullException("monitor");
IDisposable cookie = new DdMonitorCookie(monitor);
Enter(monitor);
return cookie;
}
private class DdMonitorCookie : IDisposable
{
private object _monitor;
public DdMonitorCookie(object obj) { _monitor = obj; }
public void Dispose()
{
if (_monitor != null)
{
DdMonitor.Exit(_monitor);
_monitor = null;
}
}
}
The Enter method and two of the three TryEnter methods are simple wrappers for the third TryEnter method, as shown in Figure 3. These implementations are meant to follow the same specification as implemented by Monitor's Enter and TryEnter method. Calling Enter will block until the lock is acquired (we differ slightly by design in that our Enter method will throw an exception if a deadlock is detected, rather than blocking forever), and thus delegates to TryEnter with a Timeout.Infinite timeout. Note that Timeout.In- finite equals -1, which is a special value that signals TryEnter to block until lock acquisition, rather than failing out after the specific time. In contrast, the overload of TryEnter that doesn't accept a time value defaults to using a timeout of 0, meaning that it will return false if the lock cannot be acquired immediately (again, our implementation will also throw an exception if acquiring the lock would cause a deadlock; this decision is a debatable point with TryEnter, however, so you may choose to modify the implementation accordingly). Note that TryEnter will return true if the lock was acquired or false otherwise. The second overload of TryEnter simply converts the supplied TimeSpan timeout value into a number of milliseconds, validates the argument, and delegates to the final TryEnter overload, which is where all the real work happens.
Figure 3 Implementing Enter
Copy Codepublic static void Enter(object monitor)
{
TryEnter(monitor, Timeout.Infinite);
}
public static bool TryEnter(object monitor)
{
return TryEnter(monitor, 0);
}
public static bool TryEnter(object monitor, TimeSpan timeout)
{
long totalMilliseconds = (long)timeout.TotalMilliseconds;
if (totalMilliseconds < -1
totalMilliseconds > Int32.MaxValue)
throw new ArgumentOutOfRangeException("timeout");
return TryEnter(monitor, (int)totalMilliseconds);
}
Our design is relatively straightforward, though it does involve a few interesting implementation details. The implementation begins by validating the supplied parameters, ensuring that an object was actually supplied on which to be locked and that a valid timeout was supplied (meaning either -1 or a non-zero number of milliseconds).
At this point, DdMonitor needs to access some shared state. Since there's no supported way for DdMonitor to interrogate the CLR for information about a monitor (including which thread may own it and which threads may be waiting on it), DdMonitor has to track this information manually. It does this by storing a static table of data structures that contain all of the relevant information about acquired monitors in the system, and every time an Enter or Exit operation is performed on a monitor, it updates this shared state.
Note that this has a few implications. First, while we'll see that DdMonitor does end up delegating to Monitor with the same monitor object that was supplied by the user, DdMonitor knows nothing about direct calls to Monitor's methods, and thus it's not able to update its internal state information based on any such calls that are made. This means that deadlock detection will not function properly if you mix usage of DdMonitor and Monitor (or the lock keyword) in your app, causing false negatives and possibly not preventing some deadlocks.
Another implication of this implementation is that this static table is AppDomain-specific. This shouldn't be a problem, since objects you lock on should also only live in one AppDomain. However, there are several special kinds of objects (such as Type and String) that are able to cross AppDomain boundaries, and if you lock on one of these domain-agile objects with DdMonitor from multiple domains, the static table maintained by DdMonitor in each domain will only contain a subset of the relevant information, again possibly leading to false negatives.
A third issue with this approach has to do with reliability. A lock statement in C# expands to a call to Monitor.Enter followed immediately by a try block, whose body is equivalent to the body of the lock statement and whose finally block releases the monitor. The CLR, through a bit of JIT hackery, ensures that the try block is entered if the call to Monitor.Enter succeeds; this ensures that the finally block will also be executed if Monitor.Enter succeeds, which is important in the face of asynchronous exceptions that could otherwise occur between the call to Monitor.Enter and entering the try block (for more information, see msdn.microsoft.com/msdnmag/issues/05/10/Reliability and www.bluebytesoftware.com/blog/2007/01/30/MonitorEnterThreadAbortsAndOrphanedLocks.aspx). As you'll see in our DdMonitor implementation, however, there is code that comes after the actual underlying call to Monitor.Enter and before the try block that comes after the call to DdMonitor.Enter; as such, these reliability guarantees are lost with our implementation.
You should keep all of these issues in mind in case any is dangerous to your scenarios.
Back to our implementation of TryEnter, which is shown in Figure 4; it continues by obtaining its internal lock for this shared state. Once acquired, it accesses the dictionary to find any previous data on the monitor being entered. If no such data exists, that means that no threads currently own or are waiting on the monitor. In such a case, TryEnter initializes a new MonitorState object to track this monitor and puts it back into the table.
Figure 4 Implementing TryEnter
Copy Codeprivate static Dictionary
.NET Matters
Deadlock monitor
Stephen ToubCode download available at: NETMatters2007_10.exe (156 KB) Browse the Code Online [ http://msdn2.microsoft.com/en-us/magazine/cc164433(printer).aspx ]
Q I'm using locks in my application to synchronize work on a bunch of threads. Unfortunately, I'm doing something incorrectly and my threads seem to just stop sometimes. I think I'm running into deadlocks, but I'm not sure how to find them. Is there any way I can do so programmatically? I'd like an exception to be thrown when a deadlock is encountered.
Q I'm using locks in my application to synchronize work on a bunch of threads. Unfortunately, I'm doing something incorrectly and my threads seem to just stop sometimes. I think I'm running into deadlocks, but I'm not sure how to find them. Is there any way I can do so programmatically? I'd like an exception to be thrown when a deadlock is encountered.
A First, it's important to understand what a deadlock among threads is and the conditions that lead to one. Threads deadlock when waiting on each other to release some resources, but by performing that blocking wait, they're not releasing the resources the other threads need in order to unblock. The threads can't make any progress until the resources are released, but because they're not making progress, the resources will never be released, the threads are locked up, and thus "deadlock." Many OS course textbooks will cite the four conditions necessary for a deadlock to occur:
A First, it's important to understand what a deadlock among threads is and the conditions that lead to one. Threads deadlock when waiting on each other to release some resources, but by performing that blocking wait, they're not releasing the resources the other threads need in order to unblock. The threads can't make any progress until the resources are released, but because they're not making progress, the resources will never be released, the threads are locked up, and thus "deadlock." Many OS course textbooks will cite the four conditions necessary for a deadlock to occur:
A limited number of a particular resource. In the case of a monitor in C# (what you use when you employ the lock keyword), this limited number is one, since a monitor is a mutual-exclusion lock (meaning only one thread can own a monitor at a time).
The ability to hold one resource and request another. In C#, this is akin to locking on one object and then locking on another before releasing the first lock, for example:
Copy Codelock(a)
{
lock(b)
{
...
}
}
No preemption capability. In C#, this means that one thread can't force another thread to release a lock.
A circular wait condition. This means that there is a cycle of threads, each of which is waiting for the next to release a resource before it can continue.
If any one of these conditions is not met, deadlock is not possible. The first condition is inherent to what a monitor is, so if you're using monitors, this one is set in stone. The second condition could be avoided by ensuring that you only ever lock one object at a time, but that's frequently not a feasible requirement in a large software project. The third condition could possibly be avoided in the Microsoft® .NET Framework by aborting or interrupting the thread holding the resource your thread requires, but a) that would require knowing which thread owned the resource, and b) that's an inherently dangerous operation (for the many reasons why, see msdn.microsoft.com/msdnmag/issues/05/10/Reliability). Thus, the way to avoid deadlocks is to avoid (or thwart) condition four.
In his article in the April 2006 issue (available at msdn.microsoft.com/msdnmag/issues/06/04/Deadlocks), Joe Duffy discusses several techniques for avoiding and detecting deadlocks, including one known as lock leveling. In lock leveling, locks are assigned numerical values, and threads must only acquire locks that have higher numbers than locks they have already acquired. This prevents the possibility of a cycle. It's also frequently difficult to do well in a typical software application today, and a failure to follow lock leveling on every lock acquisition invites deadlock.
Rather than prevent deadlocks wholesale, many systems attempt to detect them and then eliminate them once found. For example, SQL Server® can detect when deadlocks occur and abort one of the tasks involved in the cycle, thereby removing the deadlock. In his article, Joe builds a common language runtime (CLR) host that is capable of this form of deadlock detection in .NET applications that use monitors, a very cool feat. Unfortunately, using a custom CLR host isn't always practical for many .NET apps, including those that already have a custom host, like ASP.NET applications. As such, it would be beneficial to be able to utilize similar deadlock detection capabilities, without the need for a custom CLR host, such that these types of deadlocks could be detected at run time. This would be beneficial during development and testing phases, to identify coding errors where locks are being used incorrectly. It could also be used in production to detect and eliminate deadlocks as they occur (preventing a thread from causing one by blocking it from attempting the critical wait that would complete a cycle), however typical deadlock detection algorithms are costly and may not be appropriate in production systems for performance reasons. (I'll have a few comments on performance at the end of this column.)
To address this need, I've built a sample wrapper for the .NET System.Threading.Monitor class that includes deadlock detection capabilities. As with Monitor, my DdMonitor class provides Enter and Exit methods, and under the covers it delegates to the equivalent methods on Monitor. However, it also tracks monitor usage and throws exceptions when the attempted acquisition of a lock will complete a cycle, which would result in deadlock. For the rest of this column, I'll detail the implementation of this deadlock monitor class and provide additional information on its usage as well as on the advantages and disadvantages of its deployment.
The outline for the DdMonitor class is shown in Figure 1. From the start, note that DdMonitor does not completely mimic the public interface of System.Threading.Monitor. It provides the same public static TryEnter, Enter, and Exit methods, but it does not provide the Wait, Pulse, and PulseAll static public methods of its counterpart.
Figure 1 DdMonitor Class
Copy Codeclass DdMonitor
{
public static IDisposable Lock(object monitor) { ... }
public static void Enter(object monitor) { ... }
public static bool TryEnter(object monitor) { ... }
public static bool TryEnter(
object monitor, TimeSpan timeout) { ... }
public static bool TryEnter(
object monitor, int millisecondsTimeout) { ... }
public static void Exit(object monitor) { ... }
}
DdMonitor also provides a public static Lock method. Since the C# lock keyword provides a nice abstraction over Monitor, it's beneficial to provide a similar one for DdMonitor. Without the ability to modify the C# language, it's impossible for us to obtain identical syntax, but we can get close:
Copy Code// with Monitor
lock(obj) { ... }
// with DdMonitor
using(DdMonitor.Lock(obj)) { ... }
This syntactical feat is accomplished by implementing Lock, as shown in Figure 2. The Lock method delegates to DdMonitor.Enter to acquire the lock. However, it also instantiates a DdMonitorCookie object that implements IDisposable. This object's Dispose method will call DdMonitor.Exit to release the lock; this enables the developer to wrap DdMonitor.Lock in a C# using statement (Using in Visual Basic® or stack-allocation in C++/CLI) as shown previously.
Figure 2 Implementing the Lock Method
Copy Codepublic static IDisposable Lock(object monitor)
{
if (monitor == null) throw new ArgumentNullException("monitor");
IDisposable cookie = new DdMonitorCookie(monitor);
Enter(monitor);
return cookie;
}
private class DdMonitorCookie : IDisposable
{
private object _monitor;
public DdMonitorCookie(object obj) { _monitor = obj; }
public void Dispose()
{
if (_monitor != null)
{
DdMonitor.Exit(_monitor);
_monitor = null;
}
}
}
The Enter method and two of the three TryEnter methods are simple wrappers for the third TryEnter method, as shown in Figure 3. These implementations are meant to follow the same specification as implemented by Monitor's Enter and TryEnter method. Calling Enter will block until the lock is acquired (we differ slightly by design in that our Enter method will throw an exception if a deadlock is detected, rather than blocking forever), and thus delegates to TryEnter with a Timeout.Infinite timeout. Note that Timeout.In- finite equals -1, which is a special value that signals TryEnter to block until lock acquisition, rather than failing out after the specific time. In contrast, the overload of TryEnter that doesn't accept a time value defaults to using a timeout of 0, meaning that it will return false if the lock cannot be acquired immediately (again, our implementation will also throw an exception if acquiring the lock would cause a deadlock; this decision is a debatable point with TryEnter, however, so you may choose to modify the implementation accordingly). Note that TryEnter will return true if the lock was acquired or false otherwise. The second overload of TryEnter simply converts the supplied TimeSpan timeout value into a number of milliseconds, validates the argument, and delegates to the final TryEnter overload, which is where all the real work happens.
Figure 3 Implementing Enter
Copy Codepublic static void Enter(object monitor)
{
TryEnter(monitor, Timeout.Infinite);
}
public static bool TryEnter(object monitor)
{
return TryEnter(monitor, 0);
}
public static bool TryEnter(object monitor, TimeSpan timeout)
{
long totalMilliseconds = (long)timeout.TotalMilliseconds;
if (totalMilliseconds < -1
totalMilliseconds > Int32.MaxValue)
throw new ArgumentOutOfRangeException("timeout");
return TryEnter(monitor, (int)totalMilliseconds);
}
Our design is relatively straightforward, though it does involve a few interesting implementation details. The implementation begins by validating the supplied parameters, ensuring that an object was actually supplied on which to be locked and that a valid timeout was supplied (meaning either -1 or a non-zero number of milliseconds).
At this point, DdMonitor needs to access some shared state. Since there's no supported way for DdMonitor to interrogate the CLR for information about a monitor (including which thread may own it and which threads may be waiting on it), DdMonitor has to track this information manually. It does this by storing a static table of data structures that contain all of the relevant information about acquired monitors in the system, and every time an Enter or Exit operation is performed on a monitor, it updates this shared state.
Note that this has a few implications. First, while we'll see that DdMonitor does end up delegating to Monitor with the same monitor object that was supplied by the user, DdMonitor knows nothing about direct calls to Monitor's methods, and thus it's not able to update its internal state information based on any such calls that are made. This means that deadlock detection will not function properly if you mix usage of DdMonitor and Monitor (or the lock keyword) in your app, causing false negatives and possibly not preventing some deadlocks.
Another implication of this implementation is that this static table is AppDomain-specific. This shouldn't be a problem, since objects you lock on should also only live in one AppDomain. However, there are several special kinds of objects (such as Type and String) that are able to cross AppDomain boundaries, and if you lock on one of these domain-agile objects with DdMonitor from multiple domains, the static table maintained by DdMonitor in each domain will only contain a subset of the relevant information, again possibly leading to false negatives.
A third issue with this approach has to do with reliability. A lock statement in C# expands to a call to Monitor.Enter followed immediately by a try block, whose body is equivalent to the body of the lock statement and whose finally block releases the monitor. The CLR, through a bit of JIT hackery, ensures that the try block is entered if the call to Monitor.Enter succeeds; this ensures that the finally block will also be executed if Monitor.Enter succeeds, which is important in the face of asynchronous exceptions that could otherwise occur between the call to Monitor.Enter and entering the try block (for more information, see msdn.microsoft.com/msdnmag/issues/05/10/Reliability and www.bluebytesoftware.com/blog/2007/01/30/MonitorEnterThreadAbortsAndOrphanedLocks.aspx). As you'll see in our DdMonitor implementation, however, there is code that comes after the actual underlying call to Monitor.Enter and before the try block that comes after the call to DdMonitor.Enter; as such, these reliability guarantees are lost with our implementation.
You should keep all of these issues in mind in case any is dangerous to your scenarios.
Back to our implementation of TryEnter, which is shown in Figure 4; it continues by obtaining its internal lock for this shared state. Once acquired, it accesses the dictionary to find any previous data on the monitor being entered. If no such data exists, that means that no threads currently own or are waiting on the monitor. In such a case, TryEnter initializes a new MonitorState object to track this monitor and puts it back into the table.
Figure 4 Implementing TryEnter
Copy Codeprivate static Dictionary
Tuesday, April 8, 2008
Axapta Version Control Management System
Hi Axapat friends , according to controlling source code of applications to be easily reused and maintained during the implementation phase , so i were to use the version control managment system with microsoft dynamics axapta . This article describes how to set up the Version Control Management System (VCMS) for Microsoft Dynamics AX 4.0 using Visual Studio 2005 SourceSafe (VSS) as the version control system.
References :
- Version Control System Setup [White Paper]
- Inside Microsoft Dynamics™ AX 4.0 Book
- http://msdn2.microsoft.com/
- http://channel9.msdn.com/ShowPost.aspx?PostID=367463
it’s a pleasure to help you up on your comments , Thanks
Monday, April 7, 2008
About blog Contents
All of contents of this blog are about computer science , information tech. topics and others .
about some of contents of this blog , are linked from other sites like microsoft , google , youtube .....etc . so am not responsible of these sites' contents
ThanksAhmed Eid
about some of contents of this blog , are linked from other sites like microsoft , google , youtube .....etc . so am not responsible of these sites' contents
ThanksAhmed Eid
Subscribe to:
Posts (Atom)