For the purpose of learning, I built a server-client smartphone application. This article is a reference article that summarizes the sites that were referred to when implementing. It's 1 screen, 1GetAPI, but there are many things to do and it was a great learning experience.
The Server development environment is Eclipse, which I always use. No comment in particular.
Bootstrap Studio is used as a design tool. I don't think it's for professional designers, When designed by a non-designer like me
These two points are very useful.
It's about 3000 yen shareware, but it's also a permanent license with no additional cost.
This time, front-end development adopted CORDOVA. There are two reasons.
Monaca is an integrated development environment for front-end development and can be executed from implementation to build. There is a free frame. God.
circleci is a build tool like Jenkins etc. There is a free tier. Actually it was planned for Docker & Jenkins, but it died to reduce the server cost burden. This time, only the CI tool of Server was implemented.
I started by running Hello World with Spring Boot and then extended it to Rest API.
The naming convention has become appropriate due to the development by one person, but I think it should have been practiced first.
I used Spock for the test code and Jacoco for coverage measurement. I used the test code and coverage report for the first time, but it is very useful. I was happy and enjoyed the process of the source code and test code becoming more robust to each other.
JUnit chose Spock because it has readability issues, but it was also very easy to handle.
Coverage was an opportunity to think about the range of activity and test cases to be supplemented.
Ask Swagger. It's OK if you write SpringFOX in Gradle and explanatory text in main class.
AWS was ideal, but I decided to rent a monthly CentOS server that was handled due to learning costs.
SpringBoot includes Tomcat and can be executed by jar alone without setting up a Tomcat server.
[Step 1. Try moving it for the time being] ① Transfer the jar to the server (send by WinSCP) (2) Execute the service with java jar (path of the jar sent by hand) ③ Confirm operation at http: // (server IP): 8080 /
[Step 2. Register as a resident service] In the actual service in, the following work is done to make it resident.
If you proceed to this point, implementation will proceed for each server and client. On the other hand, in order to actually combine and communicate, it is necessary to support CORS (Cross-Origin Resource Sharing).
When sending such as POST, it is necessary to be aware of the preflight request.
It seems that Chrome on Android does not allow communication with the API unless it is HTTPS. Since there is no help for it, I set SSL on the Server side to enable HTTPS communication.
I used Let's Encrypt, which is provided free of charge by a non-profit organization in the United States. The Let's Encrypt certificate expires in 3 months, so it's a good idea to add cron.
This time, we will ask nginx to manage it instead of Apache, so please ignore the Apache installation part in the following article.
Even cats can understand! Sakura's VPS Course-The 6th "Let's Encrypt Free SSL Certificate"
The reason I introduced nginx was because I couldn't understand how to incorporate SSL directly into Spring Boot. ..
If you want to submit to the App Store, you need a Mac (Xcode) to build the release version in principle. I used Monaca's build service for Windows users. It will run the release version build for 3300 yen for one application.
You will also be asked to register the device as build information. I bought a used iPhone 6 (B rank) for debugging the actual machine. About 9000 yen. If you're a communicator, get old from your Apple user friends.
To publish the iOS app, you need to pass the review. Even if it is NG, it will politely comment on the chat, so please correct and resubmit according to the instructions.
There is no app review on Google Play, just add the necessary information and submit.
An app that returns Mecab morpheme results and some words with meaning when you enter a classic sentence. I really got the idea that came out when I was watching TV with my wife.
|Construction period||May-October 2019(6 months)|
|Man-hours||About 180 hours(Conducted about 1 hour a day)|
|Server fee||6930 yen(990 yen x 7 months)|
|App Store registration fee||About 10,000 yen|
|Google Dev registration fee||About 3000 yen|
|Monaca paid plan||About 2000 yen|
|Monaca build service||3300 yen|
|Used iPhone 6||About 9000 yen|
|BootStrapStudio||About 3000 yen|
|total||About 37230 yen|
Although it is a single pella in the article, it took a long time to work while stumbling on the first one. I had some money, but (in terms of efficiency) I stopped sticking to no cost and tried to put it out.
That is all for the introduction. Now that I've got it right, I want to make enhancements and new apps again.