All Projects → swiftengine → Swiftengine

swiftengine / Swiftengine

Licence: mpl-2.0
Apple Swift based HTTP server. The answer for a Swift based, turn key, crash resilient, high scale, and production grade web server.

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Swiftengine

Hummingbird
Lightweight, flexible HTTP server framework written in Swift
Stars: ✭ 114 (-82.73%)
Mutual labels:  server-side-swift, http-server
Perfecttemplate
Empty Perfect Starter Project.
Stars: ✭ 221 (-66.52%)
Mutual labels:  server-side-swift, http-server
Hexaville
The modern serverless web application engine and framework for Swift
Stars: ✭ 123 (-81.36%)
Mutual labels:  serverless, server-side-swift
Serverless Authentication Boilerplate
Generic authentication boilerplate for Serverless framework
Stars: ✭ 563 (-14.7%)
Mutual labels:  serverless
Soto
Swift SDK for AWS that works on Linux, macOS and iOS
Stars: ✭ 579 (-12.27%)
Mutual labels:  server-side-swift
Openwhisk
Apache OpenWhisk is an open source serverless cloud platform
Stars: ✭ 5,499 (+733.18%)
Mutual labels:  serverless
Octo Cli
CLI tool to expose data from any database as a serverless web service.
Stars: ✭ 653 (-1.06%)
Mutual labels:  serverless
Sockets
🔌 Non-blocking TCP socket layer, with event-driven server and client.
Stars: ✭ 559 (-15.3%)
Mutual labels:  server-side-swift
Aws Sam Cli
CLI tool to build, test, debug, and deploy Serverless applications using AWS SAM
Stars: ✭ 5,817 (+781.36%)
Mutual labels:  serverless
Reflection
DEPRECATED
Stars: ✭ 592 (-10.3%)
Mutual labels:  server-side-swift
Swiftserverside Vapor
🦄 Swift server open source projects based on the Swift 4.1 and Vapor 3 frameworks. (Swift 服务端开源项目)
Stars: ✭ 588 (-10.91%)
Mutual labels:  server-side-swift
Poco
The POCO C++ Libraries are powerful cross-platform C++ libraries for building network- and internet-based applications that run on desktop, server, mobile, IoT, and embedded systems.
Stars: ✭ 5,762 (+773.03%)
Mutual labels:  http-server
Serverless Plugin Typescript
Serverless plugin for zero-config Typescript support
Stars: ✭ 611 (-7.42%)
Mutual labels:  serverless
Perfectdocs
Reference and documentation for Perfect (Server-side Swift). Perfect (支持服务器端Swift语言的软件函数库)使用文档和参考手册.
Stars: ✭ 564 (-14.55%)
Mutual labels:  server-side-swift
Corral
🐎 A serverless MapReduce framework written for AWS Lambda
Stars: ✭ 648 (-1.82%)
Mutual labels:  serverless
Puppeteer Lambda Starter Kit
Starter Kit for running Headless-Chrome by Puppeteer on AWS Lambda.
Stars: ✭ 563 (-14.7%)
Mutual labels:  serverless
Aws Lambda Zombie Workshop
Code and walkthrough labs to set up a serverless chat application for the Zombie Apocalypse Workshop
Stars: ✭ 622 (-5.76%)
Mutual labels:  serverless
Ssr
A most advanced ssr framework support React/Vue2/Vue3 at the same time on Earth that implemented serverless-side render specification for faas and traditional web server.
Stars: ✭ 576 (-12.73%)
Mutual labels:  serverless
Swiftybeaver
Convenient & secure logging during development & release in Swift 3, 4 & 5
Stars: ✭ 5,392 (+716.97%)
Mutual labels:  server-side-swift
Functional Typescript
TypeScript standard for rock solid serverless functions.
Stars: ✭ 600 (-9.09%)
Mutual labels:  serverless

SwiftEngine

We work for 🌟’s and 🍴’s ... please Star our repo

🙋 Hey there!
Please note: This project is still in Alpha Version and we’re actively working on forking over a lot of nifty features from SwiftEngine to make it compatible with SwiftNIO. We appreciate any contributors or testers joining our project!

Features 😍

  • Swift on Back-End - Improve productivity by using the modern Swift language for all your app's development needs (learn more)
  • Hot Code Reload - Increase the speed of your endpoints as each file is individually compiled. If a file has not been modified since it was last used, it won't need to be recompiled (learn more)
  • Automated Routing Logic - Avoid writing custom routers; SwiftEngine will automagically route each request to the desired file (learn more)
  • Uptime Resiliency - Reduce risk by leveraging a fail-safe and high-availability operating environment where each client requests functions independently (learn more)
  • Easy web based run-time error analysis - Save time by not having to dig through shell dumps; SwiftEngine displays the full error trace on your browser for easy debugging (learn more)

Getting Started 💥

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites ❗️

What are the dependencies we need to get this to work?

OS Version
macOS 10.13+
Ubuntu 14.04, 16.04, 16.10

Getting started with the project 👍

  1. Clone this repo: git clone https://github.com/swiftengine/SwiftEngine.git
  2. cd to SwiftEngine directory and run sudo ./install.sh
  3. Run ./run.sh This should start the server running and listening on port 8887

Using ⭐️

Programming your site:

  1. Create a new mypage.swift file within the /var/swiftengine/www/ directory (see example below)
  2. From the browser, enter the following url http://<machine_ip>:8887/mypage (by default this is localhost:8887)

That's it! No compilation or dealing with shell dumps required! Your requested endpoints will be automagically compiled during the first request, and results will be shown.

Any swift file you place in /var/swiftengine/www will be accessible through the browser without the .swift extension. Read more about SwiftEngine's autonomous system and routing logic (here)

Example of a SwiftEngine based .swift file 🏆

// Import SwiftEngine essentials
import SwiftEngine


// specify other required files for this file
//se: require /common.swift

// Entry Point function; where all code begins
func entryPoint(ctx: RequestContext) {

	// add GET handlers to the request context
	ctx.addHandler(forMethod:"GET", withRoute:"*"){
		req, res in
		res.write("Hello from SwiftEngine!")
	}

	// add POST handlers to the request context
	ctx.addHandler(forMethod:"POST", withRoute:"*"){
		req, res in
		res.write("Handle for POST request method")
	}

	// add catch-all handlers to the request context
	ctx.addHandler(forMethod:"*", withRoute:"*"){
		req, res in
		res.write("Handle for catch-all")
	}

}

Built With ☀️

Contributing 👪

We would love to hear your thoughts and feedback about SwiftEngine. If you would like to contribute to our project or have an issue you would like to open, please visit our CONTRIBUTING document for more details.

Authors 🏭

Contact Us 🏭

License 🎶

This project is licensed under the Mozilla Public License Version 2.0 - see the LICENSE file for details

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].