📜 ⬆️ ⬇️

Agile design, development and launch of a high-loaded online store on the 1C-Bitrix platform - in 4 months

Good afternoon, colleagues!
Today I will tell you how in a very short time to design and launch a high-loaded online store with non-standard functionality ... on the 1C-Bitrix platform.

Problematics


If you approach the task of developing a large online store formally, describing every millimeter of a future project, then you will have a TK for several hundred, if not thousands of sheets and dozens of diagrams and screen forms. And you will probably write it for at least six months ... five of us, sleeping at work. But the most “terrible” is ahead - when you finally complete it solemnly and announce it with bulging inflamed eyes, the requirements for the project will change with great probability: market conditions have changed in six months, people, your bosses and subordinates come and go, new ideas and they and you, etc. And it is necessary to urgently hire 10 copyists, and so on to infinity :-)
image
On the other hand, if you write small TK, 10 pages, over the weekend, and all agree on it ... without reading, then you will have to settle in the development team to specify the requirements and answers to the brain-thinning questions with their accuracy: “Please write the discount calculation formula when you pay the product in dollars, taking into account the error of the machine zero. " Most likely, you will not last more than a week and the project will not appear.
So what to do if a month is allotted for designing, three for programming, you do not want to settle in the development team, and someone has already publicly announced the project launch date? :-)

We write the technical task in the macro language


image
First of all, realize that not only programmers have worked for the 1C-Bitrix platform, but also talented system and business analysts and take advantage of their experience! Fortunately for you, the most complex and difficult to understand e-commerce issues have long been chewed, adapted to Russian realities and turned into simple concepts, broken down for ease of perception into modules of the 1C-Bitrix platform: “Online Store” , “Trading Directory” and "Currencies" .
You remain:
1) It is good to understand the internal logic and terminology of these modules. This is a key point. You can spend the weekend, it's worth it.
2) See what small blocks left to add to make a publicly announced online store.
3) Write a short but capacious TZ in the terminology of the 1C-Bitrix platform, containing references to the standard platform documentation and detailed blocks describing the extended / non-standard functionality. Volume - well, a maximum of pages 20-30 and 5-10 diagrams.
4) Prepare the development team for understanding the TK and its quick implementation - for this, colleagues need to be quickly “pumped” on free courses for developers or, if time permits, on more complex commercial trainings .
5) Prepare the project maintenance team - managers, content editors, administrators - also “pumping” them for effective work.
Yes Yes. The important question remains - what if I start developing on the 1C-Bitrix platform, and suddenly a complex functionality appears that cannot be implemented and you have to write everything again on another platform? Believe me, you are not the first to have such a fear - and similar tasks are being solved, for a long time and quite successfully with the following technologies:
1) The constant struggle for simplification and modularity of the platform architecture. The architecture of 1C-Bitrix is ​​so simple and intuitively logical that nothing will interfere with your creative flight of fantasy and business requirements launched from above - doesn’t the air prevent you from moving? Personally, I have never met such business requirements for online stores that would require rewriting the core of the platform. Believe it or not.
2) The standard mechanism for extending the platform business logic is redefinable event handlers and its own modules. Believe it is easier than doing three-story inheritance from a variety of objects.
You can also take the development and support of the project into outsourcing, for example, use the services of our certified partner network , which will significantly reduce the risks of independent organization of the process of developing / maintaining an Internet project. You will only need to collect the requirements and come with them to the developers.

Instruments

You can write TK in Microsoft Word, etc., but I recommend writing it using the effective teamwork tool - wiki . Everyone can edit the text and see who and when did it. If you use our corporate portal , you can write TK in the wiki created for the project working group .
Also, a convenient wiki is available in redmine , trac , confluence products, etc.
')
Table of contents

We will collect and describe the key features of our online store in the TK, pushing off from the expanding standard functionality.

The structure of the catalog of goods and properties of goods

You need to uniquely decide - what is your directory. Sometimes the product catalog is a “tree with apples”, sometimes it’s a flat list with the ability to filter by different parameters (manufacturer, novelty, sale), and sometimes the same goods-apples can be hung on different trees - by giving Buyers various presentation of information. I recommend inserting into this section of the TOR interface prototypes of all pages of your catalog - rough drawing of screen forms helps a lot with the logic of the catalog.
Usually, on the platform 1C-Bitrix, the catalog is placed either entirely in one information block, or a single information block stores a tree structure of goods with general descriptions, and specific price offers (which are often identified by SCU) are stored in another (their) information blocks.
If you or your colleagues understand UML, then it is often useful to reflect the catalog entities on a suitable diagram by putting down logical relations between them.
image
In order to minimize the risks associated with high load in the operation of the project, I recommend experimenting with the directory structure to be carried out on a prototype that can be quickly created by developers on a 1C-Bitrix draft of design (labor costs: a day or two). And make the final decision on the directory architecture only after you fill in the directory with the expected amount of test data (and it is better to exceed it 2 times) and measure the speed and nature of typical queries to them.
Often, for the operation of the catalog, additional references are required - Manufacturers, Colors, Vehicle Types, etc. - all that will be associated with the goods in the catalog. We list them here.
Total:
In this section of the TOR you have thought out and described the structure of the catalog and the properties of the goods of your project, having first made sketches of screen forms, made a technological prototype, and tested the catalog architecture on the amount of test data that is close to real. It would be time - and you could assemble and test a Yandex.Market-style catalog on a prototype - however, 3 months are left before the launch.

Pricing of goods in the catalog, currency

The simplest thing is that the product has one price = tsiferka. It is more difficult when the price changes depending on the type of the Buyer - for ordinary people, the price is one, for partners - another, etc. Even more interesting, when the price can be set in the catalog in different currencies, and must be converted into the currency of the store, depending on where the buyer came from. And it also happens that the price of the goods depends on and on the quantity purchased. And when everything comes together ...
In the trading catalog of the 1C-Bitrix platform, the above functionality, fortunately, is provided (and many more other useful features). However, if you need more complex pricing logic in the catalog, for example, when the price depends on the number of days before the Buyer's birthday * the amount of your orders, you can always solve it ... by overriding event handlers .
In this section TK, formulas often appear. It is useful to write this and the next section of the TOR along with an accountant.
Total:
Most likely, most of the pricing logic and currencies you need, adapted to Russian realities, have already been implemented in the 1C-Bitrix platform. However, you can always add what you need, or change its behavior - through standard platform extension mechanisms, well known to developers.

Order Process for Customer

Describe how a customer can buy a product by drawing screen forms. If in doubt, install the standard online store of the 1C-Bitrix platform or play around in the virtual lab and learn the logic of its operation. Often the product is pre-added to the cart and is carried out by the order master, but sometimes you can also arrange a “quick” purchase in one step - by paying the order, for example, from the customer’s account and placing the data from the customer’s profile in it by default.
Remember that buyers are divided roughly into individuals and legal entities, but sometimes more types are required. Each type of buyer, when placing an order, as a rule, enters different data - for example, legal entities can enter an TIN, etc. This section TK is a good idea to work with a lawyer.
When an order is placed, it is necessary not only to notify the Client about it , but also to save the entered data in the profile for further use during repeated orders. Also, the client must be able to view the generated orders in the personal section, repeat and cancel them.
It is often convenient when Buyers can pay for an order from a personal account that is replenished, for example, from a scratch card.
image
Total:
You have drawn and described the order process. It is useful to use UML activity diagrams for this. Much of what is needed to implement this process already exists in the 1C-Bitrix platform. If you need to expand the business logic of the ordering process, you can always do this using standard platform extension mechanisms.

Order Process for the Manager

The platform has a standard administrative interface for working with the catalog, customer orders, their personal accounts, discounts, taxes, etc. - suitable for the vast majority of online projects. You can not only process orders, but also “empty” them according to business processes adapted for your company, where each employee performs certain operations in relation to the order - one dials to the Client and confirms the order, the other sets the payment status of the order and enters payment details documents, the third interacts with courier services, etc.
Often, back-office business processes related to the processing of store orders are reflected in the state diagram . This allows you to more clearly and formally reflect the complex processes of the company and efficiently transfer knowledge to developers.
image
Total:
You set up the business processes of the online store's back office using the capabilities of the workflow technology of orders — by defining their possible statuses, the rights of employees, and the possibility of transition between statuses. Also through the standard admin panel you manage many other directory and store entities.

Payment systems and delivery services

As a rule, online stores run with a limited set of payment systems and delivery services, then adding them as needed. In 1C-Bitrix there are many built-in objects of this category, and you can always quickly add non-standard payment systems and delivery services .

Specialized administrative sections

Sometimes it happens that the administrative sections built into the platform, for example, admin orders, are not quite suitable for solving very specific tasks. In this case, though at the expense of additional programming costs, you can create your own administrative sections with any functionality you need. In secret - if you need to start in 3 months, try not to create custom admins - better take care of the usability of the part of the site that is accessible to visitors :-)
Total:
Admins specific to your project can be added in any quantity. But often - “with head” is enough for standard admins.

Roles and rights

image
In this section, TK describes who has what rights in the store and what operations can be performed. For example, the content editor adds news and edits pages, and an accountant adds a payment status to orders, etc. It is possible that information from other systems will be automatically uploaded to your directory - create for them a special account / group with permissions only for this operation. It is useful to arrange this information in the form of a chart UseCases .

Load resilience

image
In this section, the TOR describes the methodology for conducting stress tests of an online store, if there is time for this, and target indicators. For example:
1) Test data are poured into the system in a volume close to the expected. For example, 1,000,000 orders, 200,000 items in a directory, 2,000,000 users.
2) Emulates the load on an Internet project, for example using jmeter , etc.
3) The load tool records information on each hit.
The system is required to withstand 1,000,000 hits per day, with an average page retrieval time of 0.5 seconds and an error rate (50 *), say, less than 1% (the system administrator should strive to reduce the number of errors to 0).

As a result, you have a short and effective TZ, in which, on the one hand, there will be many links to detailed online documentation for the 1C-Bitrix platform, and on the other hand, detailed tasks specific to your Internet project. Additionally, you immediately determine the target indicators of the solution to be achieved during the implementation by selecting and adjusting the equipment, optimizing the code, and caching. TK contains only the specifics of your project, based on a huge technical documentation for the platform.

Evaluation and Development


image
The implementation of the project on 1C-Bitrix usually follows this scenario:
1) Platform installation - minutes
2) Integration of templates, setting up multi-site - usually, if there is layout, day
3) Integration of standard elements - news, site map, menu, site search, etc. - usually done in a day or two
The TK prepared above is divided, better with the involvement of a team of developers or experts (try PlanningPoker ), into components . A typical project - dozens of components. Often, it's faster not to write your own component for a project, but to refine the standard one (there are hundreds of ready-made components in the platform distribution kit).
image
For the components to work, you need to set up information blocks — an abstraction of the 1C-Bitrix platform over the database. It usually takes about a day.
4) Components are evaluated. It is better to collect programmers and spend on evaluation and discussion a day or two. At this stage, it is checked whether you understand what you want to get - or you will confidently answer all the developers' questions and get adequate estimates that can be voiced, or the developers, especially not understanding the tasks (if you don’t understand them), will give marks ( perhaps under pressure :-)) "from the lantern" and most likely you will not start on time.
5) Development of components. As a rule, this is the longest phase in the life cycle of the first release of the project. The component of average complexity is done by one developer roughly a day. Components can, as a rule, be made in parallel by several developers.
image
6) Setting rights. Users and roles are created, their rights are checked in the system and project.
7) Functional and acceptance testing. Testers and users check the functionality, “clicking” the project. Bugs are fixed. Want unit tests - write, but most likely they will not have time.
8) Preparing and conducting load testing. If the project is highly loaded, then it is recommended to configure the web cluster . From experience, it is better to develop and test on the weakest hardware possible — on powerful hardware, you may not immediately appreciate the poor quality of the development.

Filling content


Because At the previous stage, roles and rights were set up; content editors can begin to fill the system with information. Directories and catalogs are also imported. It is better to first send the employees involved in filling the content to the above courses - otherwise they will fill you with questions at best, and at worst they will say that the platform is buggy, because they have nothing.

Choosing a hosting project deployment


It is recommended to choose a certified hosting based on the requirements obtained during the load testing in section 8. For high-load projects created on the web cluster , you should pay attention to the increasingly popular cloud providers. If you have strong admins - take a dedicated server, if not - order external administration.

Project maintenance


After putting the project into operation, make sure that the core of the system is regularly updated (sometimes during development our requirements for high-quality integration are violated and the kernel is modified - which causes the project to malfunction after updating, so advice is to update the project every day), and the project itself will be proactive system administrators learned about possible problems before the site visitors :-)

Conclusion


To implement a high-loaded online store for several months, it is not at all necessary to write a huge TK per 1000 pages with a hundred diagrams. It is often enough for the project manager to study the capabilities of the Online Store and Trading Catalog modules of the 1C-Bitrix platform and to reflect only specific and non-standard tasks in the TOR, completing the remaining sections in the spirit of “see the standard 1C-Bitrix documentation”. As a rule, in most cases, to change the standard functionality of an online store of a platform, it is sufficient to use the technology of redefining event handlers and it is extremely rare to create your own modules, although this is done simply. To reduce the risks of project performance degradation under load, it is recommended to conduct load testing in advance on the amount of data close to “combat”.

You are not the first to be tormented by the question: “What if I start developing on the 1C-Bitrix platform, and suddenly there will be a complex functionality that cannot be implemented and will have to write everything again on another platform?”. As I tried to show in the article, tasks of this class have been successfully solved for a long time - there is no need to be afraid .

Good luck!

The head of the quality control of integration and implementation of 1C-Bitrix - Alexander Serbul

Source: https://habr.com/ru/post/124225/


All Articles