Reference and documentation for Perfect (Server-side Swift). Perfect (支持服务器端Swift语言的软件函数库）使用文档和参考手册.
# Perfect Documentation Library [简体中文](README.zh_CN.md)

<p align="center">
    <a href="http://perfect.org/get-involved.html" target="_blank">
        <img src="http://perfect.org/assets/github/perfect_github_2_0_0.jpg" alt="Get Involved with Perfect!" width="854" />
    </a>
</p>

<p align="center">
    <a href="https://github.com/PerfectlySoft/Perfect" target="_blank">
        <img src="http://www.perfect.org/github/Perfect_GH_button_1_Star.jpg" alt="Star Perfect On Github" />
    </a>  
    <a href="http://stackoverflow.com/questions/tagged/perfect" target="_blank">
        <img src="http://www.perfect.org/github/perfect_gh_button_2_SO.jpg" alt="Stack Overflow" />
    </a>  
    <a href="https://twitter.com/perfectlysoft" target="_blank">
        <img src="http://www.perfect.org/github/Perfect_GH_button_3_twit.jpg" alt="Follow Perfect on Twitter" />
    </a>  
    <a href="http://perfect.ly" target="_blank">
        <img src="http://www.perfect.org/github/Perfect_GH_button_4_slack.jpg" alt="Join the Perfect Slack" />
    </a>
</p>

<p align="center">
    <a href="https://developer.apple.com/swift/" target="_blank">
        <img src="https://img.shields.io/badge/Swift-4.1-orange.svg?style=flat" alt="Swift 4.1">
    </a>
    <a href="https://developer.apple.com/swift/" target="_blank">
        <img src="https://img.shields.io/badge/Platforms-OS%20X%20%7C%20Linux%20-lightgray.svg?style=flat" alt="Platforms OS X | Linux">
    </a>
    <a href="http://perfect.org/licensing.html" target="_blank">
        <img src="https://img.shields.io/badge/License-Apache-lightgrey.svg?style=flat" alt="License Apache">
    </a>
    <a href="http://twitter.com/PerfectlySoft" target="_blank">
        <img src="https://img.shields.io/badge/Twitter-@PerfectlySoft-blue.svg?style=flat" alt="PerfectlySoft Twitter">
    </a>
    <a href="http://perfect.ly" target="_blank">
        <img src="http://perfect.ly/badge.svg" alt="Slack Status">
    </a>
</p>

This library contains all the reference documentation and API reference-related material you need to run and use Perfect.

## Table of Contents

* [Introduction](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/introduction.md)
* [Getting Started](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/gettingStarted.md)
* [Getting Started From Scratch](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/gettingStartedFromScratch.md)
* [An HTTP and Web Services Primer](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/WebServicesPrimer.md)
* [Repository Layout](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/repositoryLayout.md)
* [Building with Swift Package Manager](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/buildingWithSPM.md)
* [Configuring and Launching HTTPServer](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HTTPServer.md)
* [Handling Requests](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/handlingRequests.md)
	* [Routing](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/routing.md)
	* [HTTPRequest](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HTTPRequest.md)
		* [Using Form Data](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/formData.md)
		* [File Uploads](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/fileUploads.md)
	* [HTTPResponse](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HTTPResponse.md)
	* [Request &amp; Response Filters](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/filters.md)
		* [Web Redirect Filters](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/webRedirects.md)
	* [Sessions](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/sessions.md)
		* [CSRF Security](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/csrf.md)
		* [CORS Security](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/cors.md)
	* [Local Authentication modules](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/authentication.md)
	* [GSS-SPNEGO Security Feature](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/SPNEGO.md)
	* [JSON](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/JSON.md)
	* [Static File Content](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/staticFileContent.md)
	* [Mustache](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/mustache.md)
	* [Markdown](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Markdown.md)
	* [HTTP Request Logging](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HTTPRequestLogging.md)
* [CRUD](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/crud.md)
* [WebSockets](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/webSockets.md)
* [Utilities](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/utilities.md)
	* [Bytes](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/bytes.md)
	* [File](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/file.md)
	* [Dir](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/dir.md)
	* [Environmental Variables](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/env.md)
	* [Threading](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/thread.md)
	* [Networking](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/net.md) @kjessup
	* [OAuth2 and Providers](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/OAuth2.md)
	* [UUID](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/UUID.md)
	* [SysProcess](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/sysProcess.md)
	* [Log](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/log.md)
	* [Log Files](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/logFiles.md)
	* [Remote Logging](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/logRemote.md)
	* [CURL](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/cURL.md)
	* [XML](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/xml.md)
	* [INI](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/ini.md)
	* [Zip](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/zip.md)
	* [Crypto](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/crypto.md)
	* [SMTP](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/SMTP.md)
	* [Google Analytics Measurement Protocol](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/GoogleAnalytics.md)
	* [Repeater](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/repeater.md)
* [Database Connectors](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/databaseConnectors.md)
	* [SQLite](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/SQLite.md)
	* [MySQL](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MySQL.md)
	* [MariaDB](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MariaDB.md)
	* [PostgreSQL](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/PostgreSQL.md)
	* [MongoDB](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MongoDB.md)
		* [MongoDB Databases](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MongoDB-Database.md)
		* [MongoDB Collections](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MongoDB-Collections.md)
		* [MongoDB Client](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MongoDB-Client.md)
		* [Working with BSON](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MongoDB-BSON.md)
		* [GridFS](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/MongoDB-GridFS.md)
	* [CouchDB](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/CouchDB.md)
	* [LDAP](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/LDAP.md)
	* [Redis](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Redis.md) @kjessup
	* [FileMaker](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/filemaker.md)

* [iOS Notifications](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/iOSNotifications.md) @kjessup
* [Deployment](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/deployment.md)
	* [Ubuntu](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/deployment-Ubuntu.md)
	* Docker
	* [Heroku](https://github.com/PerfectlySoft/Perfect/wiki/Deploying-with-Heroku)
	* Azure
	* AWS
	* Linode
	* [Digital Ocean](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/deployment-DigitalOcean.md)

* Performance Profiling & Remote Monitoring
	* [SysInfo](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/SYSINFO.md)
	* [New Relic](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/NEWRELIC.md)

* Message Queue & Cluster Control
	* [Kafka](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Kafka.md)
	* [Mosquitto](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/mosquitto.md)
	* [ZooKeeper (Linux Only)](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/ZooKeeper.md)


* Big Data / Artificial Intelligence & Machine Learning
	* [TensorFlow](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/tensorflow.md)
	* [Hadoop](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Hadoop.md)
		* [HDFS](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HadoopWebHDFS.md)
		* [MapReduce Master](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HadoopMapReduceMaster.md)
		* [MapReduce History](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HadoopMapReduceHistory.md)
		* [YARN Node Manager](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HadoopYARNNodeManager.md)
		* [YARN Resource Manager](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/HadoopYARNResourceManager.md) 	

* Platform specific Notes
	* [Ubuntu 16.04: Starting Services at System Boot](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/starting-services.md)

* Language Extensions:
	* [Python](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/python.md)

	 
## StORM, a Swift ORM

StORM is not distributed as a Perfect.org project; however, the Perfect libraries are integral to its operation, and some authors are common.
	
* [StORM, a Swift ORM](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM.md)
	* [Introduction to StORM](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM.md)
	* [Setting up a class](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-Setting-up-a-class.md)
	* [Saving, Retrieving and Deleting Rows](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-Saving-Retrieving-and-Deleting-Rows.md)
	* [StORMCursor](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-Cursor.md)
	* [Inserting rows](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-Insert.md)
	* [Updating rows](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-Update.md)
	* [StORM Lifecycle Events](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORMLifecycleEvents.md)
	* Database Specific Implementations
		* [PostgresStORM](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-PostgreSQL.md)
		* [SQLiteStORM](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-SQLite.md)
		* [MySQLStORM](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-MySQL.md)
		* [Apache CouchDB](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-CouchDB.md)
		* [MongoDBStoRM](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/StORM-MongoDB.md)

## Perfect Turnstile – an authentication layer for Perfect

[Turnstile](https://github.com/stormpath/Turnstile) is an Open Source project from [Stormpath](https://github.com/stormpath) focussing on standardizing authentication across platforms and frameworks. Thanks to work done by [Edward Jiang](https://github.com/edjiang) on Turnstile and a foundation linking Turnstile with Perfect, an authentication layer is available for Perfect.

**⚠️NOTE⚠️** Turnstile is out of service as declared by its author, please check [Storm API Migration FAQ](https://stormpath.com/oktaplusstormpath?utm_source=github&utm_medium=readme&utm-campaign=okta-announcement) for more information.

* [Perfect-Turnstile](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Turnstile.md)
	* [Perfect Turnstile with SQLite Integration](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Turnstile.md)
	* [Perfect Turnstile with PostgreSQL Integration](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Turnstile.md)
	* [Perfect Turnstile with MySQL Integration](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Turnstile.md)
	* [Perfect Turnstile with CouchDB Integration](https://github.com/PerfectlySoft/PerfectDocs/blob/master/guide/Turnstile.md)
