Showing posts with label Software Development. Show all posts
Showing posts with label Software Development. Show all posts

Thursday 26 December 2019

Hadoop - Understanding Hadoop Architecture


Hadoop is an open source framework written in java that allows distributed processing of large datasets across clusters of computers.
Hadoop is designed to scale up from single server to thousands of machines and each have local-computation and storage.

Hadoop Architecture have 4 modules.

Understanding Hadoop Architecture
  1. Hadoop Common: These are Java libraries which provides filesystem and OS level abstractions which are required to start Hadoop.
  2. Hadoop YARN: This is used for job scheduling and cluster resource management.
  3. Hadoop Distributed File System: It provides high throughput access to application data and is suitable for applications that have large data sets.
  4. Hadoop MapReduce: This is YARN-based system for parallel processing of large data sets.

Question: What is MapReduce?
MapReduce is a software framework for easily writing applications which process big amounts of data in-parallel on large clusters. It consits of master JobTracker and slave TaskTracker per cluster. The JobTracker is responsible for resource management and schedule the task. TaskTracker is responsibel for execute the task.




Question: How Does HadoopwWork at very basic level?
  1. Job Submission by client to Hadoop.
  2. Input and output files are in "distributed file system" and with use of "Hadoop Common files" Initialization the hadoop.
  3. Execute of map and reduce functions.
  4. Scheduling the task by TaskTracker.
  5. Execution the task by JobTracker.

Monday 16 December 2019

What is CPU Usage and Memory Usage?

What is CPU Usage and Memory Usage

CPU Usage- It is the "amount of time" a CPU was used for processing the given instructions.


Memory Usage- It is the "amount of RAM" was used for processing the given instructions

Entry Processes- It is number of scripts are running at a single time. One entry process take fraction of a second to complete. So in 10 entry process you can have 10-30 visitors.

Number of Processes- It is number of process(script) can run in one time. One process take time till the execution of script.

I/O Usage- It is speed of data transfer between the hard disk and the RAM.



Question: Is high CPU usage bad?
If the CPU usage is around 100%, this means that your computer is trying to do more work than it has the capacity. Always CPU usage must be less than 90%, If so increase the CPU.




Monday 29 January 2018

phpmailer gmail - PHP MAILER setting to send email through Gmail

PHP MAILER setting to send email through Gmail

Step 1:
Download a recent version of PHPMailer.

Step 1:
Use Following code to send an email from Gmail Account.

 
// Import PHPMailer classes into the global namespace
use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;

//Load composer's autoloader
require 'vendor/autoload.php';

$mail = new PHPMailer(true);                              // Passing `true` enables exceptions
try {
    //Server settings
    $mail->SMTPDebug = 2;                                 // Enable verbose debug output
    $mail->isSMTP();                                      // Set mailer to use SMTP
    $mail->Host = 'smtp1.example.com;smtp2.example.com';  // Specify main and backup SMTP servers
    $mail->SMTPAuth = true;                               // Enable SMTP authentication
    $mail->Username = 'user@example.com';                 // SMTP username
    $mail->Password = 'secret';                           // SMTP password
    $mail->SMTPSecure = 'tls';                            // Enable TLS encryption, `ssl` also accepted
    $mail->Port = 587;                                    // TCP port to connect to

    //Email Sender
    $mail->setFrom('from@example.com', 'Mailer');

    //Recipients
    $mail->addAddress('joe@example.net', 'Joe User');     // Add a recipient
    $mail->addAddress('ellen@example.com');               // Name is optional
    $mail->addReplyTo('info@example.com', 'Information');
    $mail->addCC('cc@example.com');
    $mail->addBCC('bcc@example.com');

    //Attachments (IF there is attachment then only include)
    $mail->addAttachment('/var/tmp/file.tar.gz');         // Add attachments
    $mail->addAttachment('/tmp/image.jpg', 'new.jpg');    // Optional name

    //Content
    $mail->isHTML(true);                                  // Set email format to HTML (true) 
    $mail->Subject = 'Here is the subject';
    $mail->Body    = 'This is the HTML message body';
    $mail->AltBody = 'This is the body in plain text for non-HTML mail clients';

    $mail->send();
    echo 'Message has been sent';
} catch (Exception $e) {
    echo 'Message could not be sent. Mailer Error: ', $mail->ErrorInfo;
}

If you get similar to following Error
Please log in via your web browser and then try again.
5.7.14 Please log in via your web browser and then try again. 5.7.14 Learn more at 5.7.14 https://support.google.com/mail/bin/answer.py?answer=78754 fr13sm3613053pdb.81

If Yes, 
whether you have "turned on 2-Step Verification" OR Google need Verification that you want to use your gmail as SMTP credential.

You can fix this in couple of minutes using below link:
https://support.google.com/mail/answer/78754

If any issue, please comment below in comment box:



Friday 27 October 2017

Zoho terminology

Zoho terminology

Question: What is Zoho?
Zoho is a division of ZOHO Corporation A US-based company that has been creating and selling cutting edge software solutions since 1996.


Question: What do you meant by Zoho CRM?
Zoho CRM is an On-demand Customer Relationship Management (CRM) software for managing your customer relations.
Zoho CRM helps streamline your organization-wide sales, marketing, customer support, and inventory management functions in a single system.


Question: What is a project in Zoho?
Projects is an online project management app that helps you plan your work and keep track of your progress.
It also lets the people in the project communicate easily, discuss ideas, and stay updated.


Question: What is a Zoho Doc?
It Online Document Management System where you can store all your files securely in a centralized location, and access anywhere online.
It is the homepage for all your documents, spreadsheets, presentations, pictures, music, videos, etc.


Question: What is Zoho connect?
Zoho Connect is an enterprise social networking software application that allows people to connect with their colleagues, share ideas, and disseminate information. Users can also post messages, leave comments, share files, and conduct real-time


Question: What is Zoho inventory?
Zoho Inventory is cloud-based inventory management software that helps you create and manage both your sales and purchase orders, and track your inventory. You can integrate it with online sales channels like Amazon, eBay, and Etsy, as well as shopping carts like Shopify and more.


Question: What is a Zoho Sheet?
Zoho Sheet is an online spreadsheet application that lets you create, edit and share spreadsheets.
It can be used to work with large amount of data, functions, formulas and charts.
It is a great online productivity application which businesses find extremely useful for collaboration.


Question: What is the Zoho Show?
Zoho Show is an online-presentation tool that can be used by anyone with a Zoho account.
You can use Zoho Show to create presentations and access them from anywhere using a browser and an Internet connection.


Question: What is Zoho Assist program?
Zoho Assist is an online remote support and access platform for small and mid-sized businesses that can empower every app to become more trustworthy at absolutely no cost.


Question: What is Zoho book?
Zoho Books is an easy-to-use, online accounting software designed for small businesses to manage their finances and stay on top of their cash flow.


Question: What is a project management software?
Project management software is software used for project planning, scheduling, resource allocation and change management.
It allows project managers (PMs), stakeholders and users to control costs and manage budgeting, quality management and documentation and also may be used as an administration system.


Tuesday 5 September 2017

Microdata in HTML5

Microdata in HTML5

Question: What is Microdata in HTML5?
Microdata is a way to provide additional semantics in your web application.


Question: What is use of Microdata?
  1. Define your own customized elements.
  2. Define custom properties.
  3. We use itemscope and itemprop attribute



Question: Give sample URL of Microdata?
    
        <div itemscope="">
Web Site <span itemprop="name">Web technology experts</span>.</div>
<div itemscope="">
Domain URL is <span itemprop="name">http://web-technology-experts-notes.in</span>.</div>




Question: What are different attributes of Microdata?
Attribute Description
itemscope The itemscope attribute is a boolean attribute that tells there are Microdata on this page.
itemtype It is valid URL which defines the item.
itemid Global identifier for the item.
itemprop Property of the item.
itemref List of additional elements to crawl.



Question: What are the importance of microdata in SEO?
Schema is a specific vocabulary of tags (microdata) that you can add to your HTML to improve the way your page is represented in SERPs.


Question: What is full form of SERPs?
A search engine results page (SERP) is the page displayed by a search engine in response.


Question: What does schema org do?
Schema.org is a joint effort, in the spirit of sitemaps.org, to improve the web by creating a structured data markup schema supported by major search engines.


Question: What is Google schema?
Schema.org is the centralized home on the web for the Schema project, a collaboration between Google, Bing and Yahoo! to standardize structured markup.


Question: What is rich snippets in Google?
Rich Snippets is the term to describe structured data markup that site can add to their HTML, which in turn allow search engines to better understand.


Question: What are rich cards Google?
These "rich results" are facilitated by the addition of structured data markup to web pages, either in the form of content items ("such as articles, recipes, or movies") or lists.