Kotlin Multiplatform Concept - iOS, MacOS, WatchOS (SwiftUI), Android (phone and Wear OS), JVM Web Server - Alpha Capture
KInsight Alpha Capture is a proof of concept project currently being developed for our annual CodeWeek event (where you pitch business or technology ideas). Alpha Capture app is intended for Sales to create and distribute trade ideas to our institutional clients. The app will track the performance of each idea relative to the performance of the benchmark, and alert users when the idea has reached the price objective or stop loss value so that the user can then close the idea. This is proof of concept only, and as such will have the following limitations: 1) there will be only limited live market data availability (when creating an idea, current stock price - for this we use https://iexcloud.io/docs/api/ - if you clone this project, make sure to get your own api key - it's free!); b) there will be no permanent storage for newly created ideas, they will be stored in memory on the server until the next server reload. However, there will be a number of “prefabricated” ideas along with their historical (mocked) performance. As we cannot control the market (alas), some market data manipulation is in order. The server will provide an API to update prices for ideas so that an alert can be triggered. These price updates will flow into the app via websockets, updating UI in real time and triggering notification alerts when price objective or stop loss thresholds are met.
Part 1 |
---|
Part 2 |
---|
Part 3 |
---|
IPhone | Android |
---|---|
Wear OS | Watch OS |
---|---|
https://github.com/dmitrish/kinsight-multiplatform/blob/master/wearos-alpha.mp4
Switching server between thee possible builds: google app angine, netty, and netty with fatjar - settings.gradle:
If you want to run the google appengine locally, remember to change the engine path to your path!
To run appengine locally, execute this gradle task
Note - if you want websockets enabled, you need to run one of the netty builds (regular netty or fatjar netty). Change settings.gradle as described above and execute this gradle task for the regular netty build:
To run the fatjar build, first build with this build task:
Then navigate to the libs folder in the terminal and execute: libs % java -jar server-all.jar
Prerequisite install Google Cloud SDK and Docker(optional)
Create Google Project:
Create Docker Image and Run:
Other Docker Commands: docker images docker ps docker stop instance_id docker rmi image_name
Uploading Docker Image to Google Cloud Registry:
Next follow below to deploy Docker image into Google Kubernetes Engine: https://cloud.google.com/kubernetes-engine/docs/quickstart