Thursday, 13 July 2017

Stanford CS department updates introductory courses: Java is Gone

Stanford has decided to move away from Java in their intro courses. Surprisingly, they have decided to move to JavaScript.  Philip Guo showed that most top CS departments are moving to Python.  The Stanford Daily article linked below doesn’t address any other languages considered.
The SIGCSE-Members list recently polled all of their members to talk about what they’re currently teaching.  The final spreadsheet of results is here.  Python appears 60 times, C++ 54 times, Java 84 times, and JavaScript 28 times.  I was surprised to see how common C++ is, and if Java is dying (or “showing its age,” as Eric Roberts is quoted below), it’s going out as the reigning champ.
When Java came out in 1995, the computer science faculty was excited to transition to the new language. Roberts wrote the textbooks, worked with other faculty members to restructure the course and assignments and introduced Java at Stanford in 2002. “Java had stabilized,” Roberts said. “It was clear that many universities were going in that direction. It’s 2017 now, and Java is showing its age.” According to Roberts, Java was intended early on as “the language of the Internet”. But now, more than a decade after the transition to Java, Javascript has taken its place as a web language.
Source: CS department updates introductory courses | Stanford Daily
ADDENDUM: As you see from Nick Parlante’s comment below, the JavaScript version is only an experiment.  From people I’ve talked to at Stanford, and from how I read the article quoted above (“more than a decade after the transition to Java, Javascript has taken its place”), I believe that Stanford is ending Java in CS106.  I’m leaving the title as-is for now. I’ve offered to Marty Stepp that if CS106 is still predominantly Java in one year, I will post a new blog post admitting that I was wrong.  Someone remind me in April 2018, please.
Java Training in Chennai , Java Training Institute in Chennai , Best Java Training Course in Chennai

Thursday, 6 July 2017

Handling Alerts using Java Web Developer Platforms

I was recently asked on my Facebook page, “How do I become a Java internet Developer?” there's very no easy account this question. There area unit several sides to changing into a Java internet developer. I’ve encountered Java developers World Health Organization were smart front developers, or smart backend developers. By ‘front end’, I mean a lot of of the browser aspect technologies – markup language, CSS, Javascript and so Java templating technologies like Thymeleaf, Sitemesh, or simply smart recent JSPs. Backend developers area unit about to have stronger skills with Java, databases (SQL and NoSQL), electronic messaging (JMS/AQMP), and internet services (SOAP / REST).

You also have what's called a “full stack” Java developer. this can be my personal talent set. A full stack developer is equally consummate as a front developer and as a backside developer. this can be most likely the foremost troublesome track to follow, simply because of the variety of technologies concerned. One at some point you may be debugging one thing in JQuery, and therefore the next you’re performance standardization Associate in Nursing Oracle info question. It takes time and skill to become a full stack Java developer.

Where to Start?
For aspiring developers, the technology landscape can be overwhelming. The technology landscape is always evolving too. Do you risk learning something that will soon be obsolete?

Client Side Technologies
My advice to new developers is to start with the basics. HTML, CSS, and Javascript. These technologies are core to web development. These technologies are also generic in the sense that it does not matter if you’re a Java web developer, or a Ruby web developer.

HTML
HTML – Hypertext Markup Language. This is what makes a web page. You need to have a solid understanding of HTML. Back in the beginning of the World Wide Web HTML was traditionally a file that was served by a web server to the browser. This worked great for static content. Stuff that never changed. But this is becoming rare. People want dynamic content. Thus, the HTML is no longer a static file, the HTML is generated on demand. As a Java internet Developer you’re about to be writing code that generates the markup language document for the net browser. you'll got to have a solid understanding of the structure of Associate in Nursing markup language document.

CSS
CSS – Cascading vogue Sheets. this can be what designs a page. It controls the fonts, the colors, the layout. whereas markup language defines the content of an internet page, CSS defines however it's once conferred during a browser. for instance, you will use one set of CSS rules for a desktop internet application, and a special set of CSS rules for a mobile application. Same HTML, however 2 fully totally different appearance once rendered by the browser.

Javascript
Javascript – Do stuff on the net page. don't confuse Javascript with Java. whereas there area unit some syntax similarities, these area unit 2 fully totally different programming languages. Javascript is what very drives internet a pair of.0 applications. Through the employment of Javascript, you'll dynamically amendment the HTML/CSS supported user actions, giving the net page a a lot of application like pity the user.

HTTP
Hypertext Transfer Protocol – The communication between the client and the web server. I see too many web developers who do not understand HTTP. This is absolutely critical for you to understand. Especially as you get into working with AJAX. You need to know the difference between a POST and a GET. You should have memorized the meanings of HTTP status codes 200, 301, and 404 – and more. As a Java internet developer you will work with HTTP everyday.

Server Side Technologies
Java
Java – The question is how to become a Java web developer. So, of course you are going to need to know the Java programming language.In addition to just Java itself, you should be familiar with the Java Servlet API. There’s a number of Java web frameworks, which obscure the usage of the Java Servlet API. When things go wrong, you’re going to need to know what’s happening under the covers.

JPA
JPA – Java Persistence API – Using the database. JPA is the standard for working with traditional relational databases in Java. Hibernate is the most standard JPA implementation in use nowadays. As a Java web developer, you’re about to be operating with databases. You’ll get obtaining content from the info to show on an internet page, or receiving content from the user to store within the info. Java internet Developers got to acumen to use JPA.

Java Application Servers
Java Application Servers – The runtime instrumentality for Java internet applications. Tomcat is, by far, the foremost standard Java application server. there's a Java normal for an internet Application Archive file – aka WAR file. These area unit deployed to Application servers like Felis catus to produce the runtime setting for your internet application. A decade past, the trend was to use a a lot of advanced coupling between your application and therefore the application server. However, this trend is in favor of a looser coupling between your application and therefore the application server.

Java Frameworks
Notice to date, I even have not mentioned something concerning the excess of Java frameworks on the market for you to use? to date, I’ve represented the various technologies you'll use as a Java internet developer. The shopper aspect technologies area unit fully freelance of the server aspect technologies. Firefox doesn’t care if the server is running Java, Python or .NET. New developers typically appear to forget this.

It is potential to try and do Java internet development while not exploitation one in all the Java frameworks. If you do, you'll be writing plenty code to handle things that a framework would pay attention of for you. that is why once developing Java internet applications, you usually can need to use one in all the frameworks.

Spring Framework
The Spring Framework is an impressive assortment of tools for building massive scale internet applications. actual metrics area unit onerous to work out, however I’ve seen some estimates that say Spring is employed in over hour of Java primarily based internet applications. that very isn’t too shocking. you have got the IoC instrumentality and dependency injection from Spring Core. Spring MVC, a mature and versatile MVC primarily based internet framework.
Java Training in Chennai  Spring Security, best in school tool for securing your web site. Spring information to assist with persistence. Spring has different comes which is able to assist you in building massive scale applications.

There very isn't any various to Spring once it involves a holistic framework. There area unit competitory technologies against the varied Spring comes. however there's no single answer that has the depth and breadth of the Spring Framework family of comes. In my Introduction to Spring on-line tutorial, I provide you with an honest summary of the most important Spring Framework comes and the way they're accustomed build enterprise category applications.

Grails
Grails could be a speedy application development framework designed on prime of Spring. You get everything Spring, and so the productivity advantages of Groovy. i prefer to explain Grails as Spring with a cool wrapper. Associate in Nursing oversimplification needless to say, however necessary to recollect, Spring continues to be below the covers.

Grails is seeing a lot of and a lot of use within the enterprise. one in all the strengths of Grails is its outstanding community support.

Spring Roo
Spring Roo is a pure Java framework, which seems to try to do what Grails does, without Groovy. I’m not a fan of Spring Roo, and last time I checked neither was the marketplace. Spring Roo has not been widely adopted.

Play
A Scala based Framework. I have not had a chance to try out Play yet. I hear a lot of good things about Play in the marketplace. I feel Play is an interesting alternative. But it’s just not widely used in the enterprise. Not yet at least. Play is getting some encouraging traction.

JBoss Seam
JBoss Seam is probably the closest thing to an alternative to the Spring Framework. JBoss Seam follows the JEE standard. JBoss Seam is a good alternative, with good support, and adoption in the enterprise. JBoss Seam is often criticised as being slower than Spring in terms of development and performance. Some are much more critical of JBoss Seam.

Conclusion
Becoming a Java web developer is not something you can become overnight. There is no book called “Teach yourself Java Web Development in 21 days.” There are no short cuts to becoming a Java web developer. There are a lot of different technologies you need to learn and master. Each of these take time to learn.

Being a Java web developer can be a very rewarding career. You can get started just focusing on the front end, or just the backend technologies. Larger Java development shops will allow you to specialize in one area of the technologies over another.

If I was starting out as a Java web developer today, I most likely would focus 1st on the shopper aspect technologies. The shopper aspect technologies area unit agnostic to the server aspect technologies. Thus, as you’re beginning out you'll have larger employment choices. Compensation on the shopper aspect technologies is mostly less than the server aspect, however it’s an honest place to start out out. you'll quickly gain the talents to be employable, then shift focus and broaden your talent set and later get higher employment opportunities.
Java Training Institute in Chennai , Java Training Course in Chennai , Best Java Training in Chennai , Best Java Training , Best Java Training in Velachery 

Friday, 23 June 2017

Java Interview Questions You Must Prepare For In 2017




1.What is the purpose of garbage collection in Java? When is it used?
 ANS : The purpose of garbage collection is to identify and discard the objects that are no longer needed by the application to facilitate the resources to be reclaimed and reused.

2.What are the differences between path and classpath variables?
ANS : PATH is an environment variable used by the operating system to locate the executables. This is the reason we need to add the directory location in the PATH variable when we install Java or want any executable to be found by OS.Classpath is specific to Java and used by Java executables to locate class files. We can provide the classpath location while running a Java application and it can be a directory, ZIP file or JAR file.

3.What are the differences between Heap and Stack Memory?
ANS : The major difference between Heap and Stack memory are:

  • Heap memory is used by all the parts of the application whereas stack memory is used only by one thread of execution.
  • When an object is created, it is always stored in the Heap space and stack memory contains the reference to it.
  • Stack memory only contains local primitive variables and reference variables to objects in heap space.
  • Memory management in a stack is done in LIFO manner; it is more complex in Heap memory as it is used globally.

4.What are the differences between String, StringBuffer and StringBuilder?
ANS : 
The string is immutable and final in Java, so a new String is created whenever we do String manipulation. As String manipulations are resource consuming, Java provides two utility classes: StringBuffer and StringBuilder.
  • StringBuffer and StringBuilder are mutable classes. StringBuffer operations are thread-safe and synchronized where StringBuilder operations are not thread-safe.
  • StringBuffer is to be used when multiple threads are working on same String and StringBuilder in the single threaded environment.
  • StringBuilder performance is faster when compared to StringBuffer because of no overhead of synchronizing
5.What is a servlet?
ANS :

  • Java Servlet is server side technologies to extend the capability of web servers by providing support for dynamic response and data persistence.
  • The java.servlet and java.servlet.HTTP packages provide interfaces and classes for writing our own servlets.
  • All servlets must implement the java.servlet.Servlet interface, which defines servlet lifecycle methods. When implementing a generic service, we can extend the GenericServlet class provided with the Java Servlet API. The HttpServlet class provides methods, such as doGet() and doPost(), for handling HTTP-specific services.
  • Most of the times, web applications are accessed using HTTP protocol and that's why we mostly extend HttpServlet class. Servlet API hierarchy is shown in below image.

6.How do cookies work in Servlets?
ANS : Cookies are text data sent by a server to the client and it gets saved to the client local machine.
Servlet API provides cookies support through java.servlet.http.Cookie class that implements Serializable and Cloneable interfaces.
HttpServletRequest getCookies() method is provided to get the array of Cookies from a request since there is no point of adding Cookie to request, there are no methods to set or add the cookie to request.
Similarly, HttpServletResponse addCookie(Cookie c) method is provided to attach cookie in the response header, there are no getter methods for the cookie.


7.What is JDBC Driver?
JDBC Driver is a software component that enables Java application to interact with the database. There are 4 types of JDBC drivers:
  1. JDBC-ODBC bridge driver
  2. Native-API Driver (partially Java driver)
  3. Network Protocol driver (fully Java driver)
  4. Thin driver (fully Java driver)

8.What is JDBC Connection interface?
ANS : The Connection interface maintains a session with the database. It can be used for transaction management. It provides factory methods that return the instance of Statement, PreparedStatement, CallableStatement, and DatabaseMetaData.

9.How to integrate Spring and Hibernate Frameworks?
ANS : We can use Spring ORM module to integrate Spring and Hibernate frameworks if you are using Hibernate 3+ where SessionFactory provides current session, then you should avoid using HibernateTemplate or HibernateDaoSupport classes and better to use DAO pattern with dependency injection for the integration.
Also, Spring ORM provides support for using Spring declarative transaction management, so you should utilize that rather than going for a hibernating boiler-plate code for transaction management.

10.What are the advantages of Hibernate over JDBC?
ANS : 
  1. Hibernate removes a lot of boilerplate code that comes with JDBC API, the code looks cleaner and readable.
  2. Hibernate supports inheritance, associations, and collections. These features are not present with JDBC API.
  3. Hibernate implicitly provides transaction management, in fact, most of the queries can’t be executed outside the transaction. In JDBC API, we need to write code for transaction management using commit and rollback. 
  4. JDBC API throws SQLException that is a checked exception, so we need to write a lot of try-catch block code. Most of the times it’s redundant in every JDBC call and used for transaction management. Hibernate wraps JDBC exceptions and throw JDBCException or HibernateException unchecked exception, so we don’t need to write code to handle it. Hibernate built-in transaction management removes the usage of try-catch blocks.
  5. Hibernate Query Language (HQL) is more object oriented and close to Java programming language. For JDBC, we need to write native SQL queries.
  6. Hibernate supports caching that is better for performance, JDBC queries are not cached hence performance is low.
  7. Hibernate provides the option through which we can create database tables too, for JDBC tables must exist in the database.
  8. Hibernate configuration helps us in using the JDBC-like connection as well as JNDI DataSource for the connection pool. This is the very important feature in enterprise application and completely missing in JDBC API.


If want become Java Training and Development to learn about Java Training in Chennai , Java Training Institute in Chennai , Java Training , Best Java Training in Chennai , Java Training Course in Chennai, Java Training Center in Chennai , Java Training in Chennai with placement , Java Training Institute in Chennai With Placement, Java Training Classes in Chennai , No.1 Java Training Institute in Chennai , Excellent Java Training in Chennai