Skip to main content

Posts

Why Dozer Framework (Bean Manipulation)

Why Dozer ? Let us think about a situation that you have a source bean which contains lot of fields and the source bean belongs to a different project or module. Now you want to expose the bean to  the outside world as a part of your web service REST service development. It is not advisable to do it. There may be the following reasons. The source bean is not serialized and a final class. The source system does not allow doing it because of security breach. The source bean is very heavy and contains lot of nested beans. The source bean has fields of different types which may not be required for other system. The source bean has lot of fields; some of them are not required. Scenario to use Dozer Suppose You want to make a REST call or web service call to get the minimal account details of a person. But the source system has a bean called “Acc0untBean” which contains many sensitive information like person’s internet banking passw0rd, PAN no or social sec...

Version wise history of JDK

Check this article to known about java history. I am sure it will be interesting for you. JDK Version 1.0 First version released on 23 Jan 1996. Code named as OAK. JDK Version 1.1 Released on 19 Feb 1997. Major features are: JDBC (Java Database Connectivity) Inner classes Java beans RMI (Remote Method Invocation) Reflection (introspection only JDK Version 1.2 Releases on 08 Dec 1998. Code named as  Playground. Java String memory map for constants. Collections Framework Just in Time (JIT) Compiler Jar Signer for signing Java Archive (JAR) files. Policy Tool for granting access to system resources. Java Plug-in Audio support in Applets. Scrollable result sets, BLOB, CLOB, batch update, user-defined types in JDBC. Java Foundation Classes (JFC) which consists of Swing 1.0, Drag and Drop, and Java 2D class libraries. JDK Version 1.3 Releases on 08 May 2000. ...

CATALINA_OPTS vs JAVA_OPTS

JAVA_OPTS may use by Other applications, but only Tomcat will use CATALINA_OPTS. So if you're setting environment variables for use only by Tomcat, you'll be best advised to use CATALINA_OPTS, whereas if you're setting environment variables to be used by other java applications as well, you should put your settings in JAVA_OPTS. What can go in there! You can increase heap memory available to the JVM. You can open remote monitoring ports so that Jconsole on another system can watch how your Tomcat is running. You can add in a -server to switch from the client (quicker start, slower running) JVM to the server (slower starting, quicker running) JVM. You can increase java thread stack size using the -Xss option (same way to specify amount of memory as in -Xms and -Xmx as described in the "increase heap memory" link above. for more visit : http://www.sanjeevrathaur.com/2015/10/javaopts-variable-details.html

JAVA_OPTS Variable Details

Memory Available to the Java JVM Increasing the memory available to the Java JVM JAVA_OPTS="-Xmx1024m -Xms256m" export JAVA_OPT Options description: -Xmx sets the maximum amount of memory that can be allocated to the JVM heap; here it is being set to 1024 megabytes. -Xms sets the initial amount of memory allocated to the JVM heap; here it is being set to 256 megabytes. Run Java JVM in Server Mode The Java JVM can optimize a number of things for server environments. You can explicitly select the Java HotSpot Server VM with the -server option. JAVA_OPTS="-Xmx1024m -Xms256m -server" export JAVA_OPT What the option means: -server instructs the launcher to use the Java HotSpot Server VM. PermGen Memory If you start getting java.lang.OutOfMemoryError: PermGen space error messages. You may want to include a "-XX:MaxPermSize" option in your JAVA_OPTS. JAVA_OPTS="-Xmx1024m -Xms256m -server -XX:MaxPermSize=128m" export...

RESTful Web services: Basics

Representational State Transfer (REST) has gained widespread acceptance across the Web as a simpler alternative to SOAP- and Web Services Description Language (WSDL)-based Web services. Key evidence of this shift in interface design is the adoption of REST by mainstream Web 2.0 service providers—including Yahoo, Google, and Facebook—who have deprecated or passed on SOAP and WSDL-based interfaces in favour of an easier-to-use, resource-oriented model to expose their services. Basics Fundamental REST didn't attract this much attention when it was first introduced in 2000 by Roy Fielding at the University of California, Irvine, in his academic dissertation, "Architectural Styles and the Design of Network-based Software Architectures," which analyzes a set of software architecture principles that use the Web as a platform for distributed computing. When it's attracting this much attention, a concrete implementation of a REST Web service follows four basic design p...

Why NoSql come into the picture ?

We increasingly live in a world where data doesn’t fit nicely into the tidy rows and columns of an RDBMS. Mobile, social, and cloud computing have spawned a massive flood of data. 80 percent of all enterprise data as unstructured. What's more, unstructured data is growing at twice the rate of structured data. As the world changes, data management requirements go beyond the effective scope of traditional relational databases. The first organizations to observe the need for alternative solutions were Web pioneers, government agencies, and companies that specialize in information services. Increasingly now, companies of all stripes are looking to capitalize on the advantage of alternatives like NoSQL and Hadoop: NoSQL to build operational applications that drive their business through systems of engagement, and Hadoop to build applications that analyze their data retrospectively and help deliver powerful insights. Enjoy !!!!!!

How To Choose A NoSQL Database?

How To Choose A NoSQL Database? NoSQL databases are now part of web-scale architecture. The question is when to use what? Below, I try to compare the NoSQL data stores that I have worked with. Hopefully, it would be useful for programmers exploring and deciding the technology for their web-scale application. When to use NoSQL Before deciding on to use NoSQL instead of a SQL technology, you should ask yourself following questions about your use case (includes  ACID  test of your application) : Transactions vs No transactions (Do you need atomicity?) [Most NoSQL databases don’t support transactions] Consistent or eventual consistent (Are you okay with eventual consistency?) [Most support configurable consistency mode. You should test your scale with the consistency mode your application requires. For example, your performance test holds no good when done on “eventual consistency” mode and you decide to use hard consistency for your application.] Vertical...