October 10th, 2008
ADO.NET brings with it a number of benefits, which fall into the following categories:
Interoperability
The ability to communicate across heterogeneous environments.
ADO.NET addresses the common data-exchange limitation by using XML as its payload data format. Since XML is text-based and simple to parse, it’s a good choice for a common, platform-independent, and transportable data format. Furthermore, because XML is nothing more than structured text, employing XML as the data format on top of the HTTP network protocol minimizes firewall-related problems. With ADO and its XML format, the clients do not have to know COM to de-serialize the packaged data. All they need is an XML parser, which is readily available in many flavors on many different platforms. The data producers and consumers need only adhere to the XML schema to exchange data among themselves
Scalability
The ability to serve a growing number of clients without degrading system performance.
ADO.NET has enhanced its predecessor(ADO) by growing out of the client/server model and into the distributed components model. By using disconnected datasets as the paradigm for data exchange, ADO.NET is much more scalable than its predecessors.
Productivity
The ability to quickly develop robust data access applications using ADO.NET’s rich and extensible component object model.
ADO.NET improves developers’ productivity through its rich and extensible framework classes. Because ADO.NET framework classes are managed code, developers can inherit and extend these classes to their custom needs. If you prefer not to do this low-level legwork, you can use the Visual Studio. NET data-design environment to generate these classes for you.
Performance
An improvement over previous ADO versions due to the disconnected data model.
Because ADO.NET is mainly about disconnected datasets, the system benefits from improved performance and scalability. The database server is no longer a bottleneck when the number of connection requests goes up. Data Providers in ADO.NET also enable implicit connection pooling, which reduces the time required to open a connection.
Tags: ADO, ADO .Net, Database
Posted in Dot Net Technologies | No Comments »
October 10th, 2008
Metadata is machine-readable information about a resource, or “data about data.” Such information might include details on content, format, size, or other characteristics of a data source. In .NET, metadata includes type definitions, version information, external assembly references, and other standardized information.
In order for two systems, components, or objects to interoperate with one another, at least one must know something about the other. In COM, this “something” is an interface specification, which is implemented by a component provider and used by its consumers. The interface specification contains method prototypes with full signatures, including the type definitions for all parameters and return types.
Only C/C++ developers were able to readily modify or use Interface Definition Language (IDL) type definitions—not so for VB or other developers, and more importantly, not for tools or middleware. So Microsoft invented something other than IDL that everyone could use, called a type library. In COM, type libraries allow a development environment or tool to read, reverse engineer, and create wrapper classes that are most appropriate and convenient for the target developer. Type libraries also allow runtime engines, such as the VB, COM, MTS, or COM+ runtime, to inspect types at runtime and provide the necessary plumbing or intermediary support for applications to use them.
Type libraries are extremely rich in COM, but many developers criticize them for their lack of standardization. The .NET team invented a new mechanism for capturing type information. Instead of using the term “type library,” we call such type information metadata in .NET.
Tags: Dot Net Technology, Meta Data
Posted in Dot Net Technologies | No Comments »
October 3rd, 2008
Grid computing is all about using the untapped resources of computers connected to a network. IBM perhaps defines it most succinctly: Grid computing is applying resources from many computers in a network-at the same time-to a single problem.
The development of the World Wide Web revolutionized the way we think about and access information. We really don’t think twice anymore about logging on to the web and pulling up information on almost any topic imaginable. What the Web did for information, Grid computing aims to do for computation. Grid computing is really the next logical evolution of the Internet.
The Internet began with TCP/IP and networking; then came communication with e-mail, followed by information sharing with the World Wide Web. Next will be the advent of grid computing, the sharing of actual computer resources, such as memory, storage, and processing power.
It is almost mind boggling to imagine the types of applications that could be developed if access to distributed supercomputers, mass storage and vast memory were as straightforward as access to the web. So there are several ways of looking at Grid Computing: as a way to connect the computational power of all the big computers together and give access to companies and academia alike; as a way to connect ALL the computers both big and small and derive computational efficiencies (think peer-to-peer networks); as the next logical step in providing a computational platform for Web Services; as a business on demand or computing as a utility model which IBM and others are touting.
All of the above are in effect true. Through a variety of different means and technologies, computers will learn to share each other’s processors, storage and memory, much as they share communications and information today, and applications will take advantage of these resources. While we are far from realizing the full effects that Grid computing will bring, it is upon us and there are both short-term and long-term ramifications for the enterprise.
The actual brains of the computers will be connected, not just the arteries. This means that users will begin to experience the Internet as a seamless computational universe. Software applications, database sessions, and video and audio streams will be reborn as services that live in cyberspace.
Once plugged into the grid, a desktop machine will draw computational power from all the other machines in the grid. The Internet itself will become a computing platform. Grid computing is the next logical step for the Internet to take.
Tags: Grid Computing
Posted in Technology(General) | No Comments »
October 3rd, 2008
What XML is?
- Very easy to use and code. The complete specification document is less than 40 pages long. XML is designed to be easier to code than either HTML or full SGML.
- It is an open standard - XML is a subset of SGML
- a learning curve - XML was designed by people with many years of experience, including members of the governing bodies for both SGML and HTML.
- By its very name - extensible - you have the power to invent and use your own tags and, if you choose, share them with others.
- Very efficient - XML can re-use document elements and fragments, so you only have to transmit them once.
- Ready to use - web browsers can read XML today, just like HTML. You can use hyperlinks and images and multimedia, exactly as you do in HTML.
- Fully international - it has built-in support for texts in the major global alphabets, including a method to signal what language and encoding is being used.
What XML is not?
- It is not a replacement for good old HTML. HTML is an excellent tool for displaying documents across a network. XML is designed for information providers who want to expand the horizons - something HTML is not geared up for.
- It is not a replacement for SGML. To make XML simple, many features of SGML
- It is not constrained to a defined set of tags
- It is not clunky - you can use it secure in the knowledge that it is as efficient as possible.
Tags: HTML, SGML, XML
Posted in Technology(General) | No Comments »
September 26th, 2008
Before you start putting everything in cache, you need to consider the following benefits and risks.
The benefits include
- A reduced number of round trips to the data source, such as the database server, keeping the server resources more available for other operations.
- An increase in the number of users supported, due to a faster response time to each user’s request.
The risks include
- Easily filling a computer’s memory, which is relatively small, if you put a large amount of data in cache. As the memory gets full, the performance starts to decline, eventually leading to an unacceptable response time from the server.
- Problems in a server farm environment, when we cache information in the server’s memory, where various Web pages for the same user session may be served by different Web servers.
- No guarantee of faster performance. It all depends on how effectively you manage objects in memory.
In general, caching is useful when you have a large amount of relatively static information. A prime candidate for caching is product catalog information. There is little value in using SQL to search the database to retrieve the same list of products for each user who visits your Web site. It is a waste of database and network resources (assuming that the database is installed on a separate server than the Web site). You can easily store information like this in data cache. However, before you go wild and put your entire product catalog in one large XML DOM object (or DataSet object), consider this fact: Even though it is easier to get access to an object stored in memory, it is not necessarily faster to search that object.
A prime example of this fact is the DataSet object. The ADO.NET enthusiasts love to glorify this object by focusing on its ability to provide in-memory cache of the database. They often neglect to tell their listeners about the slow performance of its search mechanism.
Tags: Application Cache
Posted in Dot Net Technologies, Technology(General) | No Comments »
September 26th, 2008
Advantages of the String implementation in JAVA.
- Compilation creates unique strings. At compile time, strings are resolved as far as possible. This includes applying the concatenation operator and converting other literals to strings. So “hi7″ and (”hi”+7) both get resolved at compile time to the same string, and are identical objects in the class string pool. Compilers differ in their ability to achieve this resolution. You can always check your compiler (e.g., by decompiling some statements involving concatenation) and change it if needed.
- Because String objects are immutable, a substring operation doesn’t need to copy the entire underlying sequence of characters. Instead, a substring can use the same char array as the original string and simply refer to a different start point and endpoint in the char array. This means that substring operations are efficient, being both fast and conserving of memory; the extra object is just a wrapper on the same underlying char array with different pointers into that array.
- Strings are implemented in the JDK as an internal char array with index offsets (actually a start offset and a character count). This basic structure is extremely unlikely to be changed in any version of Java.
- Strings have strong support for internationalization. It would take a large effort to reproduce the internationalization support for an alternative class.
- The close relationship with StringBuffers allows Strings to reference the same char array used by the StringBuffer. This is a double-edged sword. For typical practice, when you use a StringBuffer to manipulate and append characters and data types, and then convert the final result to a String, this works just fine. The StringBuffer provides efficient mechanisms for growing, inserting, appending, altering, and other types of String manipulation. The resulting String then efficiently references the same char array with no extra character copying. This is very fast and reduces the number of objects being used to a minimum by avoiding intermediate objects. However, if the StringBuffer object is subsequently altered, the char array in that StringBuffer is copied into a new char array that is now referenced by the StringBuffer. The String object retains the reference to the previously shared char array. This means that copying overhead can occur at unexpected points in the application. Instead of the copying occurring at the toString( ) method call, as might be expected, any subsequent alteration of the StringBuffer causes a new char array to be created and an array copy to be performed. To make the copying overhead occur at predictable times, you could explicitly execute some method that makes the copying occur, such as StringBuffer.setLength( ). This allows StringBuffers to be reused with more predictable performance.
The disadvantages of the String implementation are
- Not being able to subclass String means that it is not possible to add behavior to String for your own needs.
- The previous point means that all access must be through the restricted set of currently available String methods, imposing extra overhead.
- The only way to increase the number of methods allowing efficient manipulation of String characters is to copy the characters into your own array and manipulate them directly, in which case String is imposing an extra step and extra objects you may not need.
- Char arrays are faster to process directly.
- The tight coupling with StringBuffer can lead to unexpectedly high memory usage. When StringBuffer.toString( ) creates a String, the current underlying array holds the string, regardless of the size of the array (i.e., the capacity of the StringBuffer). For example, a StringBuffer with a capacity of 10,000 characters can build a string of 10 characters. However, that 10-character String continues to use a 10,000-char array to store the 10 characters. If the StringBuffer is now reused to create another 10-character string, the StringBuffer first creates a new internal 10,000-char array to build the string with; then the new String also uses that 10,000-char array to store the 10 characters. Obviously, this process can continue indefinitely, using vast amounts of memory where not expected.
The advantages of Strings can be summed up as ease of use, internationalization support, and compatibility to existing interfaces. Most methods expect a String object rather than a char array, and String objects are returned by many methods. The disadvantage of Strings boils down to inflexibility. With extra work, most things you can do with String objects can be done faster and with less intermediate object-creation overhead by using your own set of char array manipulation methods.
Tags: Java Strings, String buffer
Posted in Java Technologies | No Comments »
September 19th, 2008
Implementing interoperability between application platforms involves the exchange of data. When implementing a .NET and J2EE interoperability project, you mainly confront the following three data exchange challenges.
- Primitive data type mappings
- Non-existent data types
- Complex data types
All these challenges involve type compatibility and have the potential to hinder or prevent data transfer.
The details of these challenges are
- Primitive data type mappings — You may know that the type “String” exists in both the CLR and in Java. However, this does not mean that java.lang.String in Java maps exactly to System.String in .NET. If your sample exposes java.lang.String, how do you go about mapping this to its equivalent in the CLR?
- Non-existent data types — How do you map data types on one platform that don’t exist in the other? For example, System.Collections.Specialized.HybridDictionary is a documented data type in the CLR, but nothing in Java resembles it in the slightest. Java contains similar examples that are not in .NET, such as Java.util.Vector.
- Complex data types — Your application may expose complex data types, made up of numerous or even nested primitive data types. Here you need to expose the complex data type so that the other platform can use it.
Tags: .Net and Java, Interoperability
Posted in Dot Net Technologies, Java Technologies | No Comments »
September 19th, 2008
There are a variety of techniques that may be used to improve the efficiency of a program. These techniques are usually applied to the intermediate representation. If several optimization techniques are written as transformations of the intermediate representation, then these techniques can be applied over and over until some termination condition is reached.
The following list describes some standard optimizations:
- Common Subexpression Elimination: If a program calculates the same value more than once and the compiler can detect this, then it may be possible to transform the program so that the value is calculated only once and stored for subsequent use.
- Copy Propagation: If a program contains an assignment such as x=y, then it may be possible to change subsequent statements to refer to y instead of to x and to eliminate the assignment.
- Dead-Code Elimination: If some sequence of instructions can never be reached, then it can be eliminated from the program.
- Loop Optimizations: There are several techniques that can be applied to remove instructions from loops. For example, if some expression appears inside a loop but has the same value on each pass through the loop, then the expression can be moved outside the loop.
- In-Lining Function Calls: If a program calls function f, it is possible to substitute the code for f into the place where f is called. This makes the target program more efficient, as the instructions associated with calling a function can be eliminated, but it also increases the size of the program. The most important consequence of in-lining function calls is usually that they allow other optimizations to be performed by removing jumps from the code.
Tags: Code Optimization, Inline functions, loop optimizers
Posted in Technology(General) | No Comments »
September 12th, 2008
RFID has really been set alight by the endorsement of the technology by the retail industry. RFID tags are miniscule microchips, which already have shrunk to half the size of a grain of coffee. RFID tags work by listening for a brief radio signal and then respond with their own, completely unique ID code. The beauty of these devices is that they require no batteries - they are powered by the original radio signal.
Historically, companies, like Wal-Mart, needed a way of capturing accurate, real-time information about the products they make, move and sell. RFID offers that capability and helps companies boost supply chain efficiencies, reduce inventories, limit theft, improve product availability and add convenience for consumers.
Wal-Mart is not alone, Tesco, the biggest retail chain in the UK have also adopted this technology by installing Smart Shelves with networked RFID readers.
The brains behind RFID were driven by the Auto-ID Center, based at MIT, an unusual cooperative effort between academia and global companies to develop the Electronic Product Code (EPC), a system for identifying objects and sharing information about them securely over the Internet.
Proponents of the technology insist that this is not a big brother technology - the range limitations ensure this - once a customer leaves a store the unique identifier code becomes useless. If the RFID tags are used on packaging then once the packaging is discarded there should be no problem.
Tags: Radio frequency, RFIDs
Posted in Technology(General) | No Comments »
September 12th, 2008
A wireless technology that enables short-range wireless data connections between devices. The name came from: Harald Bluetooth, a Viking and king of Denmark from the years 940 to 981, was renown for his ability to help people communicate. During his reign, he united Denmark and Norway.
Bluetooth wireless technology is a worldwide specification for low-cost radio that provides links between mobile computers, mobile phones, other portable handheld devices, and connectivity to the Internet. There is a written specification developed, published and promoted by the Bluetooth Special Interest Group (SIG). This SIG includes Agere, Ericsson, IBM, Intel, Microsoft, Motorola, Nokia and Toshiba, and hundreds of Associate and Adopter member companies. In mid 2002, the Bluetooth SIG established its global headquarters in Overland Park, Kansas, USA.
The Bluetooth wireless technology is essentially designed to replace cables between cell phones, laptops, and other computing and communication devices within a 10-meter range. When Bluetooth wireless technology connects devices to each other, they become paired. An example of such device pairings includes:
- Your wireless headset connecting to the cell phone in your pocket
- Your PDA automatically synchronizes with your computer when you walk into the office.
And this is only the tip of the iceberg. Bluetooth Technology is poised to expand into areas such as industrial automation, gaming and delivery tracking. It is not too far off from when you will use a Bluetooth pen to write on an image board located in a different office.
Bluetooth has already managed to immerse itself into the automotive industry. Your mobile phone headset will be wirelessly connected to the car’s in-built audio system enabling completely hands-free
Tags: Bluetooth, Wireless
Posted in Technology(General) | No Comments »