Eclipse RCP performance issues and solutions

Source: Internet
Author: User
Tags object serialization serialization

Starting in 2004, I started to let research and development teams develop common management software based on Eclipse plug-in technology (a recent product is integrated enterprise management software crm+oa+dss+ invoicing E-system)

Choose RCP way to develop management software, our original intention is to make the user interface rich and easy to operate, can make full use of eclipse itself rich swt/jface/gef/emf technology to perfect our interface performance, it should be said that eclipse RCP does live up to our expectations.

In four years of Eclipse RCP development experience, there are a lot of bumpy and insurmountable obstacles, and one of the problems that is still bothering us is the Eclipse RCP performance problem, it mainly has the following problems:

1. How to handle the data transfer between server and client in high performance?

2, because our software-oriented users are the general market, the user's machine environment is mixed (from the latest four core processors to 10 years ago P3 machine are used, memory from 256M to 2G have)? How to overcome the high performance requirements of Eclipse RCP for client applications (the old machine uses eclipse development to know that the export Eclipse rcp long wait for the taste, 2 hours, really live as death! )? and to maximize the processing capacity of the machine?

In this regard I have tried a number of ways that can be used to improve these two issues:

1, choose the most appropriate data delivery methods, RMI, Web-service, hessian, TCP client/server do the comparison, I think how you need to pass the data if the coupling level is relatively low, the business relation is simple actually can simulate the HTTP way completely, Use your own Request/response object for delivery. That Rmi/web-service is a good choice. But if the coupling between the data is tight, the business relationship is complex (my current system has 312 Pojo, they all have a tight or dense relationship, and the view is not able to define the form at design time because I allow the customer to customize it View and Action object) it is obviously not possible to use Web-service (Web-service supports only the most primitive types of data), and the method of passing object serialization directly is also not available (because Pojo objects are associated, The object that is directly serialized is almost the content of the entire database, because the form is not sure and cannot construct the corresponding action object to complete delivery. Struggled for a long time, finally using a compromise method, data transfer mining value copy serialization mode (but the default copy only two layers, that refers to the object contains only the original property, no longer include the object/collection properties it references), The contract parameters in the request object are customized to indicate the delivery level when the special needs are applied to the Multi-layer object cascade data delivery. The transmission mode uses the custom TCP Client/server way, chooses this way mainly is to reduce the data transmission size (Web-service in the garbage too many), the detail certainly many (for example how to automatically supplement the request object to transmit the data, How the server-side Hibernate object copies Pojo proxy objects into value objects ... Every question is a history of our blood and tears, hey ....

2, eclipse of the system hardware high requirements of the Earth people know, how to minimize it? My principle is to try not to use non-essential plug-ins, rcp each load a plug-in will naturally consume more. There is also a very important way is to turn off the perspective,nnd, when the system just out of the street, soon there are customer complaints in the morning to open the system quickly, noon on the slow as a snail, a scolding! Of course, it can not be used with the open, that eclipse to the Sui-loaded dry what, the same customer curse (how I will go out every point of the mouse smoke?) , no account, had to write a counter, from the customer login began to record the use of each perspective, put out of range (according to the customer's memory selection, I think there is no more than 5 256M memory, 512M memory can be 15, 1G above can not turn off the perspective, keep the highest use rate of perspective can be opened with the point.

BTW: Remember to add the running parameters to eclipse RCP (if the customer is rich you can also increase it in the Setup program, my program is the default value is this), otherwise the memory is eaten by it, listen to customers crazy call you customer service phone!

-vmargs
-xverify:none
-xx:+useparallelgc
-xx:permsize=20m
-xx:maxpermsize=128m
-xms64m
-xmx128m

Eclipse rcp There is very little information on the application of management software methodologies, welcome fellow people to communicate with each other!

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.