Five kinds of open source protocols that Java programmers need to know

Source: Internet
Author: User

Comparison of five open source protocols (Bsd,apache,gpl,lgpl,mit).

When a series of giants such as Adobe, Microsoft and Sun begin to show their preference for "open source", the era of "open source" is coming!

There are many open source protocols available today, and there are currently 58 (http://www.opensource.org/licenses/alphabetical) of open source agreements approved by the Open Source Initiative organization. Our common open source protocols such as BSD, GPL, Lgpl,mit, and so on are all protocols approved by OSI. If you want to open source your own code, it is best to choose these approved open source agreements.

Here we look at four of the most common open source protocols and their scope of application for developers/manufacturers who are ready to open source or use open source products.

BSD Open source Protocol (original BSD license, FreeBSD license, original BSD license)

The BSD Open source protocol is an agreement that gives users a lot of freedom. Basically, users can "do whatever they want", can use it freely, modify the source code, or release the modified code as open source or proprietary software.

But the premise of "doing whatever you want" when you publish code that uses the BSD protocol, or if you are developing your own product two times based on BSD protocol code, you need to meet three conditions:

1. If the republished product contains source code, then the BSD protocol in the original code must be included in the source code.

2. If you are releasing only binary class libraries/software, you will need to include the BSD protocol in the original code in the library/software documentation and copyright notices.

3. Can not use the source code of the author/agency name and the original product name to do marketing.

BSD code encourages code sharing, but it needs to respect the rights of the author of the Code. BSD, which allows users to modify and redistribute code, also allows the use or development of commercial software publishing and sales on BSD code, and therefore is a friendly agreement for business integration. Many companies choose the BSD protocol when choosing open source products because they can completely control the code of these third parties and can be modified or developed two times when necessary.

Apache Licence 2.0 (Apache License, version 2.0, Apache License, version 1.1, Apache License, version 1.0)

Apache licence is the name of the non-profit open source organization Apache adopted the Protocol. The protocol, like BSD, also encourages code sharing and respect for the original author's rights, as well as allowing the code to be modified and republished (as open source or commercial software). The conditions to be met are similar to those of BSD:

1. User needs to give the code a copy of Apache Licence

2. If you modify the code, you need to be modified in the file to explain.

3. In the extended code (in the code that is modified and derived from the source code), there is a need to include an agreement in the original code, a trademark, a patent statement, and other instructions that the original author requires.

4. If a notice file is included in the republished product, the Apache Licence is required in the notice file. You can add your own permission to the notice, but you cannot represent changes to the Apache licence.

The Apache licence is also a commercial application friendly license. Users can also modify the code when needed to meet the needs and publish/sell as open source or commercial products.

GPL (GNU general public License)

Linux, which is familiar to us, uses the GPL. The GPL protocol and the BSD, Apache licence, and other licenses that encourage code reuse are very different. The GPL's starting point is open source/free use of code and reference/modification/derivation code for open source/free use, but does not allow modified and derived code to be published and marketed as closed source commercial software. That's why we have free software developed by individuals, organizations, and commercial software companies on a variety of free Linux, including commercial companies ' Linux and Linux.

The main content of the GPL agreement is to use a product in a software that uses the GPL ("use" refers to a class library reference, modified code or derivative code), then the SOFTWARE product must also adopt the GPL protocol, both open source and free. This is the so-called "contagious". The GPL-agreed product is used as a separate product without any problems and can also enjoy the advantage of free.

Because the GPL requires the use of GPL-class library software products must use the GPL protocol, for the use of GPL open source code, commercial software or the code has confidentiality requirements of the Department is not suitable for integration/adoption as a class library and two of the basis for development.

Other details, such as Bsd/apache, need to be accompanied by a GPL-like agreement.

LGPL (GNU Lesser General public License)

LGPL is a GPL-open source protocol designed primarily for use in class libraries. And the GPL requires that any software that uses/modifies/derives a GPL class library must be in a different GPL protocol. LGPL allows commercial software to use the LGPL class library through class library references (link) without the need for Open-source commercial software code. This allows open source code using the LGPL protocol to be referenced and published and sold by commercial software as a class library.

However, if you modify the code or derivation of the LGPL protocol, all modified code, additional code involving the modification, and derived code must adopt the LGPL protocol. Therefore, the open source code for the LGPL protocol is well suited as a Third-party class library to be referenced by commercial software, but it is not suitable for commercial software that is designed to be based on the LGPL protocol code and made two times in a modified and derivative manner.

GPL/LGPL protects the original author's intellectual property and avoids the use of Open-source code to replicate and develop similar products

MIT (MIT)

MIT is the same as the BSD-wide license agreement, the author only wants to retain the copyright, without any other restrictions. In other words, you must include the original license agreement in your release, whether you are in binary or source code.

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.