Server APIs Project

Server APIs Project,第1张

概述Server APIs Project Article source:https://swift.org/server-apis/ Swift has amazing potential on the server, and to be an even better language for server-side development Swift needs great low-level A Server APIs Project

Article source:https://swift.org/server-apis/

Swift has amazing potential on the server,and to be an even better language for server-sIDe development Swift needs great low-level APIs common among server frameworks. The Server APIs project will provIDe core capabilitIEs in areas such as networking and security so Swift programs no longer need to frequently rely on platform-specific C librarIEs to provIDe this functionality. As a result,developers will be able to create frameworks and server applications using pure-Swift code,without the need to also have systems programming skills and kNowledge of multiple platforms.

While very early in development,the Server APIs are intended to have the following key characteristics:

They will provIDe access to low-level,standards defined capabilitIEs such as sockets,http parsing and security.

They will becross-platformand work on platforms supported by Swift.

They will not provIDe high level server frameworks such as web frameworks. Instead,they serve as a foundation to enable those frameworks to be developed by others.

The design of the APIs will involve representatives from developers of server-sIDe frameworks and applications. These representatives from the community will both provIDe input to the API design and implementation,and act as early adopters for the APIs.

The APIs are intended to provIDe maximum interoperability with other Swift APIs by using primitive data types from the Standard library and Foundation (where appropriate).

A starting design goal is for these librarIEs to be delivered as packages via the Swift Package Manager,although the precise way these librarIEs will be distributed will be determined once the effort is farther along.

The Server APIs project is being managed as part of the Swift.org open source community. The Server APIs are in the early stages of development,and we are excited to design and build these APIs in public from the very beginning. This project is not yet tIEd to release along with any specific version of the Swift Language,allowing this project to mature at its own pace as Swift marches on toward version 4.

Focus Areas

The project will initially focus on producing API proposals for base networking,security and encryption,and http parsing:

Base Networking: ProvIDe a portable interface for low level socket-based network I/O,including TCP/IP and UDP protocols,IPv4 and IPv6 support and domain name resolution. Support should be provIDed to create and use both synchronous and asynchronous non-blocking connections.

Security and Encryption: ProvIDe common cryptographic constants and cyphers along with keychain and certificate management,and SSL/TLS based secure transport. This must integrate with the base networking support to provIDe secure sockets,and with the http parsing library to provIDe httpS support.

http and WebSockets: ProvIDe low level http parsing,including http,http/2 and WebSocket support making it possible,in conjunction with the security and networking APIs,to create secure http and WebSocket servers.

Portability

A key goal of Server APIs is to support both the platforms that Swift is currently available on,and be in a position to adopt new platforms as and when Swift support is added. This means that there must be consistent APIs across platforms to ensure code portability. There may be alternative underlying implementations,however,on each platform. Further,in order to avoID the API provIDing only the lowest common denominator of capabilitIEs across all the platforms,platform specific extensions can be added.

Using External librarIEs

Where there are existing well supported librarIEs on a platform these should be assessed for use in conjunction with a Swift overlay,provIDed they meet the designed Swift API specification. While it may be desirable to implement the APIs using pure Swift code in the future,using existing librarIEs enables capabilitIEs to be delivered more rAPIdly and allows Swift to benefit from existing communitIEs.

APIs can subsequently evolve to have pure Swift implementations where there are advantages,including improved performance,user-experIEnce (usage,installability),or maintenance.

Note that the use ofanylibrary for this purpose must beexplicitlyapproved by theProject leadper thegeneral policyof adding dependencIEs on external librarIEs to the Swift project.

Work Group

The creation of these APIs will be steered by a work group consisting of a steering team,stakeholders from the server-sIDe Swift community,and anyone who wants to get involved. The work group consists of three roles: steering team member,stakeholder,and contributor. Participants may have more than one role in the work group.

Everyone is welcome to contribute to the Server APIs Work Group through participating in a range of activitIEs including joining as a stakeholder,participating in design discussions,asking or answering questions on the mailing Lists,reporting or triaging BUGs or by submitting pull requests to the project(s) for implementation or tests.

Steering Team

Analagous to the primaryCore Teamfor Swift,the work group has a steering team that is responsible for provIDing overall technical direction,ensuring co-ordination both between the varIoUs API efforts (for example around network security and http integration for httpS) and with the wIDer Swift Core librarIEs and language. Membership of the steering team is contribution based and is expected to evolve over time.

The initial steering team consists of the following people (and their GitHub IDs):

Chris Bailey (@seabaylea,IBM Kitura) Logan Wright (@LoganWright,Vapor) Paulo Faria (@paulofaria,Zewo) Steve Algernon (@salgernon,Apple)

Additionally it is expected that sub-teams will form over time to focus on specific API areas.

Stakeholders

The work group also has stakeholders who represent server-sIDe frameworks or applications. They are responsible for provIDing early input on use cases and API design as part of the iterative design and implementation process,and to adopt the new APIs into their frameworks.

Joining and leaving the work group as a stakeholder is a straightforward process. The only requirement is to raise a Pull Request to add or remove your name from the stakeholder List in thework group GitHub project,which will act to add or remove you from invites to formal work group discussions.

The initial stakeholders consists of:

DanIEl Dunbar (@ddunbar,Apple) Gregor Milos (@gmilos,Apple) Kyle Jessup (@kjessup,Perfect) Robert Dickerson (@rfdickerson,IBM Kitura) Tanner Nelson (@tannernelson,Vapor) Tom Doron (@tomerd,Apple) Development Process

The development of new server-focused APIs under the guIDance of the Server APIs work group occurs in three phases: API Proposal,PrototyPing and Development,and Release.

API Proposals

Proposals for new APIs are created by the Server APIs steering team,stakeholders,and contributors. The initial API proposal is not a full API specification with a detailed architecture and design. The initial proposal should be use case focused,highlighting:

The set of capabilitIEs and function targeted for implementation Why those functions are useful and what types of server frameworks for applications would benefit from them How those functions would be used,and an initial overvIEw of the intended approach to implement them

The API proposal is then revIEwed and approved by the steering team and stakeholders who look to valIDate that the proposed functions are reasonable capabilitIEs to be added,that they fit within the remit of the Server APIs work group,and that the overall approach is valID.

The proposal is then socialized with the wIDer Swift community as a “Pitch” in the Swift Evolution process.

PrototyPing and Development

Once the API proposal is approved by the steering team and stakeholders,and input has been received from the wIDer community via Swift Evolution,prototyPing and development can begin. This is an iterative process involving four steps:

Develop: Development is done by the work group contributors to produce an incubator release. Function is added incrementally,adding tests and documentation as part of the development process.

Release: Once sufficIEnt new function has been developed,the steering team and stakeholders branch the code to provIDe a new incubator release. The availability of the release for testing,adoption and Feedback is then announced using the Swift evolution-announce mailing List

Adopt: The incubator release is then adopted by the stakeholders and the wIDer community in order to assess the APIs for usability,coverage and quality.

Feedback: Finally,any Feedback from the stakeholders and wIDer community is fed back into the next development cycle.

Once the full set of function has been developed,released,adopted and Feedback acted on,the steering team and stake holders will branch a formal PrevIEw release.

Release Process

In addition to soliciting Feedback from the wIDer community at the initial pitch and development milestones,once a prevIEw release is available a formal Swift Evolution proposal is published and announced via the Swift Evolution mailing List. This gives the wIDer community a formal opportunity to revIEw the final API and architecture and provIDe Feedback before the library is released.

Mailing List

The Server APIs Work Group utilizes theswift-server-devmailing List for general discussion.

总结

以上是内存溢出为你收集整理的Server APIs Project全部内容,希望文章能够帮你解决Server APIs Project所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/web/1070119.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-26
下一篇 2022-05-26

发表评论

登录后才能评论

评论列表(0条)