Tuesday, 5 March 2013

 

Lifecycle

The software development lifecycle of a Force.com project is much like an on-premise Web application development project, but with less toil. Many moving parts exist in J2EE, .NET, or LAMP projects. Most require a jumble of frameworks to be integrated
and configured properly before one line of code relevant to your project is written.
This section describes areas of Force.com functionality designed to streamline the development lifecycle and focus your time on the value-added activities related to yourapplication. Each of these areas has implicit costs and benefits. On the cost side, there is usually a loss of control and flexibility versus technologies with less abstraction. Evaluatingthese features and judging whether they constitute costs or benefits for your project is up to you.

Integrated Logical Database

Relational databases are still the default choice for business applications, despite the availability of alternatives like NoSQL, XML, and object-oriented databases.The relational
model maps well onto business entities, data integrity is easily enforceable, and implementations scale to hold large datasets while providing efficient retrieval, composition, and transactional modification.
databases introduces an impedance mismatch. Databases organize data in terms of
schemas, tables, and columns. Programs organize data and logic into objects, methods, and
fields. Many ways exist to juggle data between the two, none of them ideal.To make matters
more complicated, many layers of protocol are needed to transport queries, resultsets,
and transactions between the program and the database.
In Force.com, the database tables are called objects.They are somewhat confusingly
named because they do not exhibit object-oriented behavior.The name comes from the
fact that they are logical entities that act as tables when being defined, loaded with data,
queried, updated, and reported on, but are surfaced to programs as typed data structures.
No mismatch exists between the way data is represented in code and the way it’s representedin the database.Your code remains consistent and concise whether you are working with in-memory instances of your custom-defined Apex classes or objects from the
database.This enables compile-time validation of programs, including queries and data
manipulation statements, to ensure that they adhere to the database schema.This one
seemingly simple feature eliminates a whole category of defects that were previously discovered only through unit tests or in production by unfortunate users.
The logical aspect of the database is also significant. Developers have no direct access
to the physical databases running in Salesforce’s data centers.The physical data model is a
meta-model designed for multitenant applications, with layers of caches and fault tolerance,
spanning servers in multiple data centers.When you create an object in Force.com,
no corresponding Oracle database table is created.The metadata describing your new
table is stored and indexed by a series of physical tables, becoming a unified, tenantspecific
vocabulary baked into the platform’s higher-level features.The synergy of
integrated, metadata-aware functionality makes Force.com more than the sum of its
individual features.

Metadata-Derived User Interface

As described previously, the definition of your objects becomes the vocabulary for other
features. Nowhere is this more evident than in the standard Force.com user interface,
commonly referred to as the “native” UI.This is the style pioneered by the Salesforce
Sales and Service Cloud products: lots of tabular displays of data, topped with fat bars of
color with icons of dollar signs and telescopes, and a row of tabs for navigation.
It is worth getting to know the capabilities of native UI even if you have reservations
about its appearance or usability.To some, it is an artifact of an earlier era of Web applications.
To others, it is a clean-cut business application, consistent and safe. Either way, as a
developer, you cannot afford to ignore it.The native UI is where many configuration
tasks are performed, often for features not yet visible to Eclipse and other tools.
If your project’s user interface design is amenable to the native UI, you can build
screens almost as fast as users can describe their requirements. Rapid application prototyping is an excellent addition or alternative to static screen mock-ups. Page layouts are descriptions of which fields appear on a page in the native UI.They are automatically
created when you define an object and configured with a simple drag-and-drop
layout tool.

Simplified Configuration Management

Configuration management is very different from what you might be accustomed to from on-premise development. Setting up a development environment is trivial with Force.com.You can provision a new development environment in a few clicks and deploy your code to it using the familiar Eclipse IDE.

When added to your Eclipse IDE or file system, Force.com code and metadata are ready to be committed to an existing source control system. Custom Ant tasks are available to automate your deployments. Sandboxes can be provisioned for testing against realworld volumes of data and users.They are automatically refreshed from snapshots of production data per your request. Force.com’s packaging feature allows you to partition
your code into logical units of functionality, making it easier to manage and share with others at your company or in the larger community.

Integrated Unit Testing

The ability to write and execute unit tests is a native part of the Apex language and
Force.com development environment.Typically, a test framework is an optional component
that you need to integrate into your development and build process.With the facility
to test aligned closely with code,writing and executing tests becomes a natural part of
the development lifecycle rather than an afterthought.
In fact, unit tests are required by Force.com to deploy code into production.This
applies to all Apex code in the system: user interface logic, triggers, and general business
logic.To achieve the necessary 75% test coverage often requires as much if not more code
than the actual Apex classes.
To make sure you don’t code yourself into a corner without test coverage, a great time
to write tests is while you code. Many development methodologies advocate test-driven
development, and writing tests as you code has benefits well beyond simply meeting the
minimum requirements for production deployment in Force.com. For example, a comprehensive library of tests adds guardrails to refactoring and maintenance tasks, steering you away from destabilizing changes.

Integrated Model-View-Controller (MVC) Pattern

The goal of the MVC pattern is maintainable user interface code. It dictates the separation
of data, visual elements that represent data and actions to the user, and logic that
mediates between the two. If these three areas are allowed to collide and the codebase
grows large enough, the cost to fix bugs and add features becomes prohibitive.
Visualforce adopts MVC by design. For example, its view components do not allow
the expression of business logic and vice versa. Like other best practices made mandatory
by the platform, this can be inconvenient when you just want to do something quick and
dirty. But it is there to help. After all, quick-and-dirty demos have an uncanny tendency
to morph into production applications.

Integrated Interoperability

Force.com provides Web services support to your applications without code.You can designate an Apex method as a Web service.WSDL is automatically generated to reflect the
method signature.Your logic is now accessible to any program that is capable of calling a Web service, given valid credentials for an authorized user in your organization.You can also restrict access by IP address or open up your service to guests.
As in other languages,Apex provides you with a WSDL-to-Apex tool.This tool generates Apex stubs from WSDL, enabling you to integrate with SOAP-enabled business processes existing outside of Force.com. Lower-level Apex libraries are also available for
raw HTTP and XML processing.

End of Life

Retiring a production application requires a few clicks from the system administrator.Users can also be quickly removed or repurposed for other applications.Applications can
be readily consolidated because they share the same infrastructure. For example, you might keep an old user interface online while a new one is being run in parallel, both
writing to the same set of objects.Although these things are possible with other technologies,Force.com removes a sizable chunk of infrastructure complexity, preserving more intellectual bandwidth to devote to tackling the hard problems specific to your business.


Monday, 25 February 2013

Team selection  required for any  project get developed in salesforce

The best people to staff on Force.com projects might already work at your company. Projects do not require brand-new teams staffed with Force.com experts.With the majority of the platform based in mature technology such as relational databases and Web-development,adapting existing teams can be a straightforward task.

Here are some examples of traditional software development roles and how they can
contribute to a Force.com project:
 

 Business Analyst

Substantial Force.com applications can be built entirely by configuration, no computer
science background or coding skills required. Salesforce refers to this as
“clicks, not code.” Business analysts who are proficient with Microsoft Excel and its
macro language, or small-scale databases like Microsoft Access and FileMaker Pro,
can get hands-on with the Force.com data model, validation rules,workflows,
approval rules, and page layouts
.

Data Modeler

A data model forms the core of a Force.com application. Data modelers can use
their existing Entity-Relationship tools and techniques to design the data layer,
with some deltas to account for Force.com-specific idiosyncrasies. Rather than
scripts of DDL statements, their work output is Force.com’s metadata XML or
manual configuration of the data objects. Data modelers can also design reports and
report types, which define data domains available to business users to build their
own reports.

Database Administrator

Many traditional DBA tasks are obsolete in Force.com because there is no physical
database to build, monitor, and tune. But a DBA still has plenty of work to do in
planning and implementing the Force.com object model.There are objects to
define or permissions to configure, and the challenges of data transformation and
migration are still as relevant in Force.com as in any database-backed system. Database Developer
The design of Force.com’s programming language,Apex, has clearly been inspired
by stored procedure languages like T-SQL and PL/SQL. Existing database developers
can adapt their skills to writing Apex code, particularly when it requires detailed
work on the data like triggers.

 Object-Oriented Analysis and Design Specialist

Force.com includes an object-oriented language, and persistent data is represented
as objects.With all of these objects floating around, people with skills in traditional
techniques like Unified Modeling Language (UML) are valuable to have on your
project team. Larger applications benefit from a well-designed object model, and as
in any language, designing before writing Apex code can be a real timesaver.

 User Interface Designer

Force.com supports modernWeb standards for creating usable, flexible, and maintainable
UIs. UI designers can help by building screen mock-ups, page layouts, and
the static portions ofVisualforce pages to serve as templates and assets for developers.

Web Developer

Developers who have built Web applications can quickly learn enough Apex and
Visualforce and build similar applications on Force.com, typically with much less
effort. Skills in HTML, CSS, JavaScript, or Adobe Flex are needed to build custom
Force.com user interfaces.

4GL Developer

Developers proficient in fourth-generation languages such as Java, C#.NET, and
PHP usually have no problem picking up Apex code. It has the same core syntax as
Java, without the Java-specific libraries and frameworks. 

Integration Specialist

Force.com is a producer and consumer of Web services and supports REST as well
as any integration strategy based on HTTP.An integration expert can design the
interaction between systems, define the remote operations, and implement them
using Force.com or a specialized integration product.

 Quality Assurance Engineer

Testing is a critical part of any software project, and on Force.com testing is mandatory
before code is deployed to production.A QA engineer can write automated
unit tests in Apex and test plans for security and integration testing. Standard tools
like Selenium can be used to automate UI testing.

 Operations Specialist

Although there are no servers or operating systems to manage, larger deployments
of Force.com can involve integration with on-premise systems. Single Sign-On
(SSO) integration and data migration are two common examples. Operations
experts can help in this area, as well as with application deployment and Force.com
administration tasks such as user maintenance.






Validation for Alphanumeric

<apex:inputField value="{!XXX}"  onkeypress="return checkInput(this);"       />



function checkInput(txt) {
    if (/\W/test(txt.value)) {
        alert("Please enter alphanumerics only");
        return false;
    }
        return true;
    }

   

Workflows:

Each workflow rule consists of:
  • Criteria that determine when Salesforce executes the workflow rule. Any change that causes a record to match this criteria can trigger the workflow rule—even changes to hidden fields.
  • Immediate actions to take when the workflow rule executes. For example, Salesforce can automatically send an email that notifies the opportunity team when a new high-value opportunity is created.
  • Time-dependent actions that Salesforce queues when the workflow rule executes. For example, Salesforce can automatically send an email reminder to the account team if a high-value opportunity is still open ten days before the specified close date. When Salesforcetriggers a workflow rule that has time-dependent actions, you can use the workflow queue to monitor and cancel pending actions.

Which Type Of Project can be developed In Force.com platform

The project is data-centered, requiring the storage and retrieval of structured data.

Structured data is the most important point. Implementing a YouTube-like application
on Force.com is not the best idea, because it primarily works with unstructured
data in the form of video streams. Force.com supports binary data, so a
video-sharing Web site is certainly possible to build. But handling large amounts of
binary data is not a focus or core competency of Force.com.A hotel reservation
system is an example of a more natural fit.

The user interface is composed primarily of wizards, grids, forms, and reports.

Force.com does not restrict you to these user interface patterns.You can implement
any type of user interface, including “rich” clients that run using Flash in the
browser, and even full desktop applications that integrate with Force.com via its
Apex Web Services API. But to capture the most benefit from the platform, stick
with structured, data-driven user interfaces that use standard Web technologies such
as HTML, CSS, and JavaScript.


The underlying business processes involve email, spreadsheets, threaded discussions,
 and hierarchies of people who participate in a distributed, asynchronous workflow.
Standard Force.com features such as Chatter,workflow, approvals, and email services
add a lot of value to these applications.They can be configured by business analysts
or controlled in-depth by developers.



 The rules around data sharing and security are fine-grained and based on organizational roles
 and user identity
User identity management and security are deep subjects and typically require high
effort to implement in a custom system.With Force.com, they are standard, highly
configurable components that you can leverage without coding.You can then spend
more time thinking through the “who can see what” scenarios rather than coding
the infrastructure to make them possible.



 The project requires integration with other systems.
Force.com is built from the ground up to interoperate with other systems at all its
layers: data, business logic, and user interface.The infrastructure is taken care of, so
you can focus on the integration design. Exchange a million rows of data between
your SQL Server database and Force.com. Call your Apex services from a legacy
J2EE application or vice versa.Add an event to a Google calendar from within
yourVisualforce user interface.These scenarios and more are fully supported by the
platform.

Sunday, 24 February 2013

In Salesforce custom tables containing up to 800 fields each

Database

Force.com is built around a relational database. It allows the definition of custom tables
containing up to 800 fields each. Fields contain strongly typed data using any of the standard
relational database data types, plus rich types such as currency values, picklists, formatted
text, and phone numbers. Fields can contain validation rules to ensure data is
clean before being committed, and formulas to derive values, like cells in a spreadsheet.
Field history tracking provides an audit log of changes to chosen fields.

Custom tables can be related to each other, allowing the definition of complex data
schemas.Tables, rows, and columns can be configured with security constraints. Data and
metadata is protected against accidental deletion through a “recycling bin” metaphor.The
database schema is often modifiable instantly, without manual migration. Data is imported
from files or other sources with free tools, and APIs are provided for custom data-loading
solutions.

Data is queried via a SQL-like language called SOQL (Salesforce Object Query Language).
Full-text search is available through SOSL (Salesforce Object Search Language).
www.it-