Please place unbridled praise, wechat search [Silent King ii] concern about this programmer in luoyang, the ancient capital of nine dynasties. This article has been included in GitHub github.com/itwanger, which also contains the interview questions I carefully prepared for you.
Strictly speaking, third-party services for all software can be developed themselves, but going from zero to one costs time and money. Just like our chip research and development, invested a huge cost, but still did not achieve ideal results, some things are not overnight, opportunistic can be completed.
Java back-end development often involves many third-party services, so what are the mature solutions for getting started?
1) IaaS
IaaS is Infrastructure as a Service, which provides IT Infrastructure as a Service over the network and charges users based on the actual resource usage. IaaS can quickly scale vertically based on demand, eliminating the need for users to purchase and manage their own physical servers and other data center infrastructures, thereby avoiding the expense and complexity associated with such operations.
Typical things a user can do with IaaS include:
- Testing and development.
- Web hosting.
- Storage, backup, and restore.
- Web applications.
- High performance computing.
- Big data analysis.
Basically, all cloud service providers provide IaaS services. Aliyun is the most powerful cloud service provider in China.
2) PaaS
PaaS is Platform as a Service. You only need to submit code to a specified runtime environment. The Platform implements code packaging, deployment, and IP binding.
In contrast to IaaS, users do not need to manage and control cloud infrastructure (including networks, servers, operating systems, or storage), but need to control the upper-layer application deployment and application hosting environment.
3) SaaS
SaaS is Software as a Service. In this mode, users can use Software over the network without going through the traditional installation steps. The main feature of SaaS is that the software itself is not downloaded to the user’s hard drive, but stored in the provider’s cloud or server.
How do YOU distinguish between IaaS, PaaS and SaaS? Take a look at the picture below.
If we are developing a website, the traditional way is to buy a professional server, install the server software on it, and then deploy the written website.
If IaaS is used, you do not need to purchase your own server. You can install the server software and deploy the website on a rented cloud server.
If the PaaS service is used, there is no need to purchase a server or install server software, just deploy a website.
If the use of SaaS services, the site does not need to develop their own, direct use of service providers to develop a good website, late upgrade, maintenance by service providers to be responsible for.
Ruan yifeng’s blog explains the relationship between the three. If you want to start a pizza business, there are three options.
Scheme 1: IaaS.
Someone else provides the kitchen, the stove, the gas, and you use that infrastructure to bake your pizza.
Plan two, PaaS.
In addition to the infrastructure, others provide pizza crust. All you have to do is sprinkle your own toppings on the crust, and whether it’s beef or Orleans wings is up to you.
Plan 3: SaaS.
When someone else makes a pizza, you get it. All you have to do is sell the pizza, preferably with your Logo on it.
4) the domain name
Once you have an app that can serve you, you need a memorable domain name, preferably as simple as possible. In the case of Wikipedia, Wikipedia.org is a domain name that corresponds to the IP address 208.80.152.2. Users can access Wikipedia.org directly instead of an IP address, which the Domain Name System (DNS) converts into an IP address that is easy for machines to recognize.
For a period of time, the domain name is very bad, just like the real estate speculation. One of my college friends had lots of domain names, but none of them sold.
Xiaomi co-founder Li Wanqiang previously confirmed on his Weibo account that the transaction price for the Mi.com domain name was $3.6 million. Lei Jun call “thief expensive”!
I bought the domain name through Tencent cloud.
www.itwanger.com/
It means information technology, and wanger is the pinyin of “wanger” in “silent king er”. But really, regret to buy.com, the annual fee is a bit expensive, should be changed into a cold domain name, for example. Top, too poor me.
5) the CDN
The full name of CDN is Content Delivery Network. It is a computer Network system connected to each other through the Internet. It uses the server closest to each user to deliver music, pictures, movies, applications and other files to users faster and more reliably. To provide high performance, scalability and low cost delivery of web content to users.
Well-known CDN service providers include:
-
Cloudflare, which offers a free version of its solution, is enough to protect small websites from DDoS attacks, as well as hide a website’s real IP address. Excellent response speed overseas, not at home.
-
Tencent cloud, resource reserves all over the world 50+ countries and regions, the whole network bandwidth 120Tbps+. 1100+ acceleration nodes in China, covering mobile, China Unicom, China Telecom and dozens of small and medium-sized operators.
-
Ali Cloud, global 2800+ nodes, 130T bandwidth capacity, coverage of six continents, domestic mainstream operators support.
-
Seven Niuyun, global 2000 nodes, 20+ operators coverage, access speed up 80%, application scenarios include audio and video on demand, large file download, Web acceleration services, etc.
-
Clap cloud, global 1100+ nodes, 10Tbps bandwidth reserve, domestic mainstream operators support.
Personally, I like to use BootCDN to speed up CSS and JavaScript when MAKING websites. In my memory, the brief introduction says that Bootstrap and Bootstrap Chinese are cooperating, but now it looks like Cat Cloud — I don’t know what happened.
6) Email sending
Basically, every application cannot do without email, and the most commonly used mail servers are Tencent Mailbox and netease Mailbox. Common email protocols include SMTP, POP3, and IMAP. However, SMTP is the only protocol used to create and send emails.
Java provides a Java class library that encapsulates the email protocol, JavaMail, but is not included in the standard JDK. The GitHub address is:
javaee.github.io/javamail/
I remember receiving a request before that the email should not be sent to the spam mailbox, which was quite difficult to do. Because mail servers, such as Tencent and netease, have made mail filters to identify some messages and automatically put them into spam.
7) SMS sending
Using text messages to send captcha codes is an essential part of almost every app, as if the phone number represents a person, so losing your phone is a very dangerous thing — it needs to be reported immediately.
SMS requires the support of the carrier, so you basically need to rely on third-party agents. There are many SMS gateway agents on the market, Ali Cloud communication is a more commonly used one, formerly called Ali greater than.
The price of Ali Cloud communication is 0.036 yuan per SMS, there are some other service providers on the market, some of the price is lower, but I have not tested the stability. Hidden in my technical communication group is the merchant personnel that many do short message.
Application access to Ali Cloud communication is not complicated, I have shared a blog on CSDN before, very detailed, illustrated, also with source code example, if you need a friend can go to watch.
Qingmiaogu.blog.csdn.net/article/det…
8) Message push
Message Push refers to the active message Push carried out by operation personnel to users’ mobile devices through their own products or third-party tools. Users can see push notifications on the mobile device lock screen and in the notification bar, which can be clicked to evoke the APP and lead to the corresponding page.
Push has become a standard feature on mobile apps.
IOS connects to the Apple Push Notification Service (APNs) Server at the system level. Applications register interested messages with the iOS system in observer mode. After receiving the messages from the APNs Server, the iOS system forwards the messages to corresponding applications.
Android Cloud to Device Messaging (C2DM) adopts a mechanism similar to iOS, which supports message push at the system level. However, since Google’s services cannot be accessed stably in China, This scheme is basically unusable for domestic users.
In view of the unavailability of C2DM push on Android platform, a large number of third-party push service providers have emerged in China. Currently, the most widely used third-party push service providers include Getui, Aurora, Umeng, Xiaomi, Huawei, BAT, etc. I used Getui to make a small program push Demo. The API is easy to call and feels quite usable.
Notifications can be annoying, especially with apps, which are constantly being pushed, so my notifications are basically turned off on my phone — and the world has been quiet ever since.
9) Open platform
Through the open platform, OAuth and other protocols can be used to obtain user information on the third-party platform to achieve third-party platform login. For example, if A user wants to log in to website A, website A requires the user to provide data of third-party websites to prove his or her identity. OAuth authorization is required to obtain identity data from third-party websites.
Domestic Microblog, wechat and QQ are the most common third-party login methods. Ali-based products can be authorized to log in through Alipay, and some websites are bound to GitHub login.
Here’s a GitHub OAuth third-party login tutorial on Ruan’s blog:
www.ruanyifeng.com/blog/2019/0…
10) Payment interface
At present, alipay and wechat are the most connected payment interfaces.
Alipay provides payment interfaces such as face to face payment, APP payment, mobile phone website payment and computer website payment.
Documentation is complete, as well as Java, PHP,.NET and other versions of the Demo.
opendocs.alipay.com/open/270
For wechat payment, I recommend using the open source tool library WxJava:
Github.com/Wechat-Grou…
Our company’s website is used for this, supporting back-end development including wechat payment, open platform, small program, enterprise wechat/enterprise number and public number, etc., very complete.
Above, hope to help friends, we will see you next time.
Second liver for two days and two nights, “programmers indispensable soft power” the first edition of a strong hit, pure hand knock, essence, a full 200000 words ran through my programming career for more than a decade, involved in all aspects of the life and work, if you are a lost of college students, or just hired, trust my personal experience, I can give you bring some thinking, Thus set up the correct outlook on life and values.
So how do I get this PDF?
Link: pan.baidu.com/s/1TA3txLvH… Password: ps7z
Finally, I sincerely hope that this PDF can be of substantial help to you, and I will continue to improve this e-book in the future, please look forward to it.
And, of course, ask for a “like” every day!