13 Mistakes Java veteran should beware of _java

Source: Internet
Author: User
Tags jboss application server oracle database

The problems that arise in the production process are gradually getting the attention of middle-level and top management. Whether you are a developer or an architect, the following issues should be paid enough attention to to avoid the embarrassment of being stuck in the future. You can also use it as a sticky note to troubleshoot problems.

#1, is not a property file or an XML file that is a foreign configuration property. For example, the number of threads used by the batch is not set to be configurable in the properties file. Your batch program, whether in the DEV environment, or UAT (User acceptance test) environment, you can run smoothly, but once deployed on the PROD, as a multithreaded program to handle a larger dataset, it will throw the IOException, because the JDBC driver version may be different, It may also be a problem discussed in the discussion. If the number of threads can be configured in a property file, it becomes very easy to make it a single-threaded application. We no longer need to deploy and test applications over and over again to solve problems. This approach also applies to configuring URLs, servers, and port numbers.

#2, the data set used in the test is not the right size. For example, a typical scenario in the production process is to use only 1 to 3 accounts for testing, which should have been 1000 to 2000. When performing a performance test, the data used must be true and not cropped. Performance testing that is not close to the real world can lead to unpredictable performance, expansion, and multithreading issues. It is only possible to test an application with a larger dataset to ensure that it runs correctly and satisfies the SLAs (Service level standard) of non-functional properties.

#3 and naïve to think that the external and internal services invoked in the application are reliable and always available. Service invocation Timeouts and retries are not allowed, which adversely affect the stability and performance of the application. An appropriate service interrupt test is required. This is important because today's applications are distributed and service-oriented, requiring a large number of network services. Unlimited requests for unavailable services can damage the application. The load balancer also needs to be tested to ensure that it works properly and that each node is balanced.

#4, not complying with the minimum security requirements. as mentioned above, Web services can be seen everywhere, making it easy for hackers to use it for denial of service attacks. Therefore, when using a Secure Sockets Layer, you must complete the basic validation and use tools such as Google skipfish for penetration testing. Unsafe applications not only threaten their own stability, but may also adversely affect the company's reputation because of data integrity issues, such as the case where customer "A" can browse customer "B" data.

#5, no cross-browser compatibility tests. today's Web applications are rich single-page applications that use JavaScript programming languages and frameworks such as angular JS. In order for you to build a Web site to run smoothly between different devices and browsers, you must implement the corresponding design. So in order to ensure that your application can be applied to all devices and browsers, it must be tested for compatibility.

#6, there is no business rule that may change frequently. such as tax law, government or industry-related requirements, classification law, etc. You can use an engine such as Drools to handle business rules that help you to get out of these business rules by storing them in a database or Excel form. By mastering these business rules, companies can quickly respond to tax laws or related requirements with minimal change and testing.

#7, the following documents are not available

    1. Write a unit test document and have good code coverage.
    2. Integration testing.
    3. A comprehensive or encyclopedic page lists all the software artifacts, such as classes, scripts, configuration files, and so on, which are either modified or newly created.
    4. A high-level concept map describes all components, interactions, and structures.
    5. The underlying document tells the developer "How to build a development environment with the details of the data source."

In addition to the COS (satisfying conditions) This form created by Mindmap, there are 1 and 2 of the main document forms in Agile development .

#8, no appropriate disaster recovery plans, and system monitoring and archiving policies. as the project deadline approaches, these issues are often missed because of the rush to deploy the project. Failure to establish appropriate system monitoring mechanisms through Nagios and Splunk not only threatens application stability, but also hinders current diagnostics and future improvements.

#9, columns that are not easily collated for database tables , such as Created_datetm, Update_datetm, created_by, updated_by, and timestamps, do not provide a structured deletion of record columns, such as ' Y ' or ' N ' ' deleted ' column or the ' record_status ' column that can take ' Active ' or ' Inactive '.

#10, there is no appropriate withdrawal plan. There is no way to restore the system to a stable state prior to deployment in the event of a system failure. This plan needs to be hashed and signed by the relevant team. The plan includes, returns to the previous version of the software, removes all data inserted into the database, and all entries of the property file.

#11, no capacity plan was developed prior to the commencement of the project. nowadays, when it comes to the requirements of the platform, it is not enough to simply say "a Unix computer, an Oracle database server, an JBoss application server" is not sufficient. Your request must be precise.

    • A specific version of the operating system, JVM, and so on.
    • How much memory (including physical memory, JVM heap memory, JVM stack memory, and the JVM's permanent generation space).
    • CPU (number of cores).
    • Load balancer, the number of nodes required, the type of node, such as active/active type or active/passive type, and clustering requirements.
    • File system requirements, for example, your application might collect generated reports and save them for a year before archiving. In this case, you will need to have enough hard disk space. Some applications require the production of data extraction files and temporarily store them for use by other system processes or data warehouse systems for multidimensional Analysis reports. Some data files are based on secure file transfer protocols, either from internal systems or from external systems, and need to be saved for 12-36 months before archiving.

The following #12 from "David DeCesare" from "Java.dzone" comments,

#12, "Use the best tools when you are not working". in many cases, developers use a language or a tool in a production system that they want to learn. Usually this is not the best choice. For example, use the NoSQL database for data that is already in fact a relational type. Keep in mind that no matter what tool you use, you will need to maintain your product over the next 3-5 years (or even longer).

#13, there is a lack of adequate knowledge stocks in 16 key technical areas. these areas include identifying and repairing 1 "concurrency issues", 2 transaction issues, and 3 performance issues. In many interviews, I got a new contract with the knowledge of these 3 aspects.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.