Overview

About

Kiit is a Kotlin Tool-Kit, a simple, light-weight, modular framework to build Apps, APIs, CLIs, Jobs, and more for Start-ups, Personal projects, and SMBs ( small-medium sized businesses ). These libraries can be used for both Server and Android and there are modules for the server that abstract infrastructure ( Queues, Files, SMS, Emails, Alerts ) with integrations for AWS ( SQS, S3 ), Twilio ( SMS ), SendGrid ( Email ), Slack ( Alerts ) and more. Multi-platform support is planned as a future state.



Goals

The Kiit framework was originally designed for and extracted from a sizable and sophisticated production Mobile Startup with a Server backend. Kiit is a Kotlin first framework architected with the explicit goals and purposes below in mind:

SimpleDesigned with simplicity in mind, modular and very light-weight.
Kotlin100% Kotlin, emphasis on functional, immutable code (pragmatic: without pure FP, no category-theory)
SharedFull-Stack for Android and Server, resonably light-weight and suitable for both.
PlatformsLong-term goals of making this support Kotlin Multi-Platform ( Javascript, iOS )
CostsReducing costs with rapid development, full-stack / sharable code for both Server and Android.
GuidesEasy to follow docs, examples, guides, and blogs and videos coming soon
PortableReasonable abstractions of Cloud components for portability between cloud providers ( currently only AWS )

Back to top



Uses

Kiit can be used to quickly build well structured and scalable architecture and applications for different target groups.

Mobile Set up the back-end for your mobile apps. Use Kotlin code and libraries for both Server and Android
PersonalLearn Kotlin, functional programming, for self-improvement or side projects
Startups Start with a strong base architecture to quickly build high-quality MVPs (Minimum Viable Products) that can scale
SMBFor small to medium sized businesses, build backend applications with pre-built application/service templates/components
Enterprise*There are several components in Kiit that can currently be used in the Enterprise, such as the App, Utilities, CLI. However, Kiit is simpler and thus less comprehensive in some areas than enterprise offerings such as Spring.io, Vertx.io, Micronaut.io, all of which are very solid solutions and recommendations for the enterprise.

Back to top



Tech

Kiit is built for the JVM using 100% Kotlin so that many modules can be used for both Server and Android ( and soon Multi-Platofrm). There are also thin abstractions over some infrastructure services such as Files, queues, docs. Currently, only AWS implementations are available for the infrastructure abstractions. However, in the future, support for Google and Azure cloud services may be implemented. Other services are used directly.

Infrastructure - Usage Provider
Files Abstracted AWS S3 ( see files )
Queues Abstracted AWS SQS ( see queues )
Documents Abstracted AWS Dynamo ( see docs )
Entities Abstracted Support for MySql ( see data docs )PostGres & Mongo coming soon
APIs Direct Usage Ktor ( from JetBrains ) - used as the Http server using our Universal API approach
Http Client Partially Abstracted OkHttp
Metrics Partially Abstracted Micrometer.io ( see tracking )
Logs Abstracted Logback ( see logger )
SMS Abstracted Twilio ( see sms )
Email Abstracted SendGrid ( see email )
Alerts Abstracted Slack Web Hooks ( see alerts )
Dates Aliased ThreeTen BP is used for Full-Stack / Android alignment

Back to top



Modules

These are the main architecture components available in Kiit.

Component Docs Version Target Status License About
Foundations: Libraries used by most projects
Results Android / Server Stable Successes / Failure Modeling
Utilities Android / Server Stable Utility Components
Context Android / Server Stable Stores Common Dependencies
Actors Android / Server Stable Micro Actor Library
Applications: Runnable apps and services
App Server Stable Runnable App Template
CLI Server Stable Command Line Interface
Server Server Stable Http Server ( using Ktor ) and our Universal APIs
API Server / Console Stable Universal APIs
Jobs Android / Server Stable Pausable Background jobs/queues library
Infrastructure: Infrastructure components
Cache Android / Server Stable Caching library
Core Android / Server Stable Infrastructure Abstractions(Files, Queues, etc)
Notifications Server Stable Email, SMS, Slack, Push
Tracking Android / Server Stable Diagnostics related library
Data: Database related modules
DB Server Stable Convenient datbase operations over JDBC
Query Android / Server Stable A light-weight SQL Query builder
Data Android / Server Stable Repository pattern for data persistence
Entities Android / Server Stable Light-weight Data-Mapper for models/tables
Support: Misc support libraries and tools
Slate Kit Server / Console Stable Slate Kit CLI for MacOS
Generator Server / Console Stable Project templates and code generator
Providers: 3rd Party Integrations
Logback Android / Server Stable Logback logging provider for Slate Kit logs
DataDog Android / Server Stable DataDog metrics provider for Slate Kit metrics
AWS Android / Server Stable AWS S3, SQS provider files/queues
Connectors: Connects 2 or modules together
API / CLI Server / Console Stable Makes Universal APIs run on the CLI
API / Jobs Server Stable Makes Universal APIs accessible from jobs/queues
Entities/DB Android / Server Stable Makes Entities/Databases available in the Context
Internal: Internal libraries (not for public use)
Http Android / Server Stable Thin library on top of OkHttp for RPC calls
Meta Android / Server Stable For Reflections and meta-programming
Policy Android / Server Stable For middleware and enforcing policies like once, every
Serialization Android / Server Stable Custom serializer/deserializer for Slate Kit Universal APIs

Back to top



Design

The architecture of the Kiit can be visualized in this high-level diagram of the modules and how they are logical organized.


Back to top



Philosophy

Philosophy, design goals, approaches and standards

Tech Built in Kotlin, for the JVM ( multi-platform coming later), and designed to be reusable for both Client ( Android ) and Server (Backend/APIs/Services).
Design Library based approach instead of a "Framework". Structured into several modules so you can pick as little or as much as you want.
Standards Check our coding standards
Approach Simplicity and Practicality above all else
Components Composable, single-purpose components as building blocks. Organized into various projects.
Portable Designed for reasonably low vendor lock-in via a "library" based approach.
Minimal Dependencies on external, 3rd-party libraries are kept to a minimum. Json Simple, OkHttp( for Http client ), Logback( Optional ), Micrometer ( Optional )
License See license. This is a Dual license, with support for Apache 2.0 for majority of users.
Style Emphasis on immutability and pragmatic functional programming as much as possible.
However, this is NOT a 100% purely functional code base, and there is NO category theory.

Back to top



Releases

Releases occur roughly every 2 weeks to 1 month for planned releases and uses Semantic Versioning in format MAJOR.MINOR.PATCH

Type Cycle Version Note(s)
Hot-Fix On Demand 2.0.2 For critical issues
Patches ~ 2 Weeks 2.0.3 For planned bug-fixes. Roughly every 2 weeks or as needed
Minor ~ 1 Month 2.1.0 For small or moderate changes and/or new features.
Major ~ 3 Months 3.0.0 For major releases with new features and potentially breaking changes/ redesigns

Back to top



Timeline

1 2015 Started off as an idea in 2015. Slate Kit was being built in-parallel with a mobile app/start-up. The idea was to keep the architecture as decoupled from the business/mobile app as possible in Scala.
2 2016 Actively builing out the architecture components. Separating code into various projects for better organization
3 2017 Slate Kit almost fully extracted from a mobile startup and converted from Scala to Kotlin to allow for full-stack client ( Android ) and Server development and code reuse. This greatly reduced time, costs and made development for other projects much simpler using 1 language for Android and Server.
4 2018 Actively used in production and in beta apps. Dog-fooding this framework helped to polish up the components and discover and update use-cases. Slate Kit become a major effort and a cornerstone for mobile work and some future SAAS product ideas.
5 2019 Emphasis on tooling, build automation, package distribution to BinTray, Unit-Tests and website updated with docs.
6 2020 Established stable, production ready, and well tested modules on both Server and Android, approach public release.
7 2021 Finalize organization of modules, documentation, website and communication channels. Begin work a Slate Kit based MBaas ( Mobile Backend as a Service ) as a self-hosted alternative to Google Firebase.

Back to top



Security

Security details of the various modules will be coming soon and available/documented within each applicable module such as App, CLI, Jobs, APIs, Queues, etc. Generally speaking, most modules security revolve around protecting sensitive configuration settings, data during transmission and authentication / authorization for runnable services such as the App, CLI, APIs.

Type Security Note(s)
Conf Config settings Settings can be encrypted or loaded from env vars
Files AWS S3 Also refer to AWS S3 docs
Queues AWS SQS Also refer to AWS SQS docs
App Runnable App See module docs for more info
APIs Web/Http APIs See module docs for more info
CLI CLI See module docs for more info
Data Sql See module docs for more info

Back to top