This is an automated email from the ASF dual-hosted git repository. dcelasun pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/thrift-website.git
commit 69a3bf0da4c17701a4ac774f9f2c9e739baf019f Author: Christopher Tubbs <[email protected]> AuthorDate: Thu Oct 29 09:43:30 2020 -0400 Convert markdown and liquid * Use Jekyll front-matter to indicate markdown to generate * Use Liquid syntax to loop over data --- _config.yml | 100 ++++++++++++++++++++++++++++++ _includes/footer.html | 61 +++++++++---------- _includes/header.html | 78 ++++++++---------------- _includes/nav.html | 15 ----- _layouts/default.html | 18 +++--- _layouts/tutorial.html | 21 +++++++ _layouts/tutorial_intro.md | 12 ---- about.md | 67 ++++++++++---------- developers.md | 27 ++++----- docs/BuildingFromSource.md | 43 ++++++------- docs/HowToContribute.md | 3 +- docs/HowToNewLanguage.md | 17 +++--- docs/Languages.md | 8 +-- docs/coding_standards.md | 5 +- docs/committers/AdditionalReading.md | 2 +- docs/committers/HowToCommit.md | 2 +- docs/committers/HowToThriftWebsite.md | 10 +-- docs/committers/ReleaseManagement.md | 4 +- docs/committers/index.html | 2 - docs/committers/index.md | 3 + docs/concepts.md | 3 +- docs/features.md | 11 ++-- docs/idl.md | 3 +- docs/{index.html => index.md} | 24 +++++--- docs/install/centos.md | 5 +- docs/install/debian.md | 23 ++----- docs/install/{index.html => index.md} | 22 ++++--- docs/install/os_x.md | 5 +- docs/install/windows.md | 7 ++- docs/types.md | 5 +- download.md | 15 ++--- index.html => index.md | 27 +++++---- lib/c_glib.md | 23 ++----- lib/cl.md | 23 ++----- lib/cpp.md | 23 ++----- lib/csharp.md | 23 ++----- lib/d.md | 23 ++----- lib/delphi.md | 23 ++----- lib/erl.md | 23 ++----- lib/go.md | 23 ++----- lib/haxe.md | 23 ++----- lib/hs.md | 23 ++----- lib/{index.html => index.md} | 32 +++++----- lib/java.md | 23 ++----- lib/js.md | 23 ++----- lib/netstd.md | 23 ++----- lib/nodejs.md | 23 ++----- lib/ocaml.md | 23 ++----- lib/perl.md | 23 ++----- lib/php.md | 23 ++----- lib/py.md | 23 ++----- lib/rb.md | 23 ++----- lib/st.md | 23 ++----- mailing.md | 1 + perllib/path.pm | 111 +--------------------------------- perllib/view.pm | 6 -- sitemap.html | 1 - sitemap.md | 13 ++++ static/css/alerts.css | 2 +- static/css/forms.css | 4 +- static/css/mixins.css | 2 +- static/css/sprites.css | 4 +- static/css/thrift.css | 25 ++++++++ static/css/type.css | 2 +- static/js/thrift.js | 14 +++++ test/ThriftTest.thrift | 4 +- test/index.md | 6 +- test/keys.md | 22 ++----- tutorial/as3.md | 5 +- tutorial/c_glib.md | 7 ++- tutorial/cpp.md | 5 +- tutorial/csharp.md | 5 +- tutorial/d.md | 5 +- tutorial/dart.md | 5 +- tutorial/delphi.md | 5 +- tutorial/go.md | 7 ++- tutorial/graphviz.md | 13 ++-- tutorial/haxe.md | 17 +++--- tutorial/hs.md | 5 +- tutorial/index.html | 42 ------------- tutorial/index.md | 44 ++++++++++++++ tutorial/java.md | 5 +- tutorial/js.md | 15 ++--- tutorial/netstd.md | 5 +- tutorial/nodejs.md | 5 +- tutorial/ocaml.md | 5 +- tutorial/perl.md | 5 +- tutorial/php.md | 5 +- tutorial/py.md | 5 +- tutorial/rb.md | 5 +- 90 files changed, 672 insertions(+), 905 deletions(-) diff --git a/_config.yml b/_config.yml index 6ec575b..4161c43 100644 --- a/_config.yml +++ b/_config.yml @@ -36,3 +36,103 @@ defaults: values: layout: "default" +# Additional variables to power specific pages +git_repo: "https://github.com/apache/thrift" +release_url: "https://www.apache.org/dist/thrift" +mirror_url: "http://www.apache.org/dyn/closer.cgi?path=" +jira_url: "http://issues.apache.org/jira/browse/THRIFT" + +current_release: "0.13.0" +current_release_date: "2019-OCT-16" + +# Apache ID, Name, Specialities, Timezone +committers: + - [ "mcslee", "Mark Slee", "General vision and implementation", "-8" ] + - [ "dreiss", "David Reiss", "Everything, GIT configuration, performance", "-8" ] + - [ "aditya", "Aditya Agarwal", "C++ servers", "-8" ] + - [ "marck", "Marc Kwiatkowski", "C++ concurrency", "-8" ] + - [ "jwang", "James Wang", "C++ transports and processors", "-8" ] + - [ "cpiro", "Chris Piro", "Erlang", "-8" ] + - [ "bmaurer", "Ben Maurer", "Python data serialization", "-5" ] + - [ "kclark", "Kevin Clark", "Ruby implementation", "-8" ] + - [ "jake", "Jake Luciani", "Perl, JavaScript", "-5" ] + - [ "bryanduxbury", "Bryan Duxbury", "Compact Protocol, Java, Ruby", "-8" ] + - [ "esteve", "Esteve Fernandez", "Python, Twisted, async transports", "1" ] + - [ "todd", "Todd Lipcon", "Erlang, Java", "-8" ] + - [ "geechorama", "Andrew McGeachie", "Cocoa", "?" ] + - [ "molinaro", "Anthony Molinaro", "Erlang, Perl, autotools", "-8" ] + - [ "roger", "Roger Meier", "Continuous Integration, C++, C#, JavaScript, make cross and other stuff", "2" ] + - [ "jfarrell", "Jake Farrell", "Release Manager, Build, Client Publishing, Java, PHP, Ruby", "-5" ] + - [ "jensg", "Jens Geyer", "Delphi, C#/NetStd, Go, Graphviz, Haxe", "1" ] + - [ "carl", "Carl Yeksigian", "C#", "-5" ] + - [ "ra", "Randy Abernethy", "C++, Python, JavaScript, C#, what have you", "-8" ] + - [ "hcorg", "Konrad Grochowski", "C++, Python, Git, Continuous Integration", "1"] + - [ "nsuke", "Nobuaki Sukegawa ", "", "9"] + - [ "simonsouth", "Simon South", "C (GLib)", "-5"] + +# Powered by: Company name, website +powered_by: + - [ "Cloudera", "http://www.cloudera.com" ] + - [ "Evernote", "http://evernote.com" ] + - [ "Facebook", "http://www.facebook.com" ] + - [ "last.fm", "http://www.last.fm" ] + - [ "Mendeley", "http://www.mendeley.com" ] + - [ "OpenX", "http://www.openx.org" ] + - [ "Pinterest", "http://www.pinterest.com" ] + - [ "Quora", "http://www.quora.com" ] + - [ "RapLeaf", "http://www.rapleaf.com" ] + - [ "reCaptcha", "http://www.recaptcha.com" ] + - [ "Siemens", "http://www.siemens.com" ] + - [ "Uber", "http://uber.com" ] + +# Apache Projects using Thrift: Project name, website +apache_projects: + - [ "Accumulo", "https://accumulo.apache.org" ] + - [ "Aurora", "http://aurora.apache.org" ] + - [ "Camel", "http://camel.apache.org/" ] + - [ "Hadoop", "http://wiki.apache.org/hadoop/HDFS-APIs" ] + - [ "HBase", "http://wiki.apache.org/hadoop/Hbase/ThriftApi" ] + - [ "Parquet", "https://parquet.apache.org" ] + - [ "Storm", "http://storm.apache.org/" ] + +# OSS Projects using Thrift: Project name, website +oss_projects: + - [ "Microsoft Robust Distributed System Nucleus (rDSN)", "https://github.com/Microsoft/rDSN" ] + - [ "Twitter Finagle", "http://twitter.github.io/finagle/guide/Protocols.html" ] + - [ "Twitter Scrooge", "http://twitter.github.io/scrooge" ] + +# external packages hosted elsewhere: +# - Thrift target language +# - package manager name +# - link to package (URL) to most recent version +# - package control file (git source tree link) +# - package maintainer name +# - remarks +external_packages: + - [ "(all)", "Docker", "https://hub.docker.com/_/thrift/", "Dockerfile", "", "thrift compiler in /usr/local/bin/thrift" ] + - [ "ActionScript","Maven", "https://repository.apache.org/#nexus-search;quick~libthrift-as3", "lib/as3/build.xml", "jking", "" ] + - [ "C (glib)", "", "", "", "", "language has no package manager" ] + - [ "C++", "", "", "", "", "see THRIFT-4800" ] + - [ "C#", "NuGet", "https://www.nuget.org/packages/ApacheThrift", "ApacheThrift.nuspec", "jfarrell, codesf, jking", "multi-framework nupkg for csharp and netcore" ] + - [ "Cocoa", "", "", "", "", "deprecated on 0.12.0 - use swift" ] + - [ "Common LISP", "", "", "", "", "no official ASF package available" ] + - [ "D", "dub", "https://code.dlang.org/packages/apache-thrift", "dub.json", "jking", "" ] + - [ "Dart", "Pub", "https://pub.dartlang.org/packages/thrift", "lib/dart/pubspec.yaml", "jking", "" ] + - [ ".NET Standard", "NuGet", "https://www.nuget.org/packages/ApacheThrift", "ApacheThrift.nuspec", "jfarrell, codesf, jking", "multi-framework nupkg for csharp and netcore" ] + - [ "Erlang", "Hex PM", "https://hex.pm/packages?search=thrift&sort=downloads", "", "", "no official ASF package available" ] + - [ "Haskell", "Hackage", "https://hackage.haskell.org/package/thrift", "lib/hs/thrift.cabal", "jfarrell, clavoie, jking", "" ] + - [ "Haxe", "Haxelib", "", "lib/haxe/haxelib.json", "jensg", "no package uploaded - see THRIFT-3036" ] + - [ "Go", "", "", "", "", "no official ASF package available" ] + - [ "Java", "Maven", "https://repository.apache.org/#nexus-search;quick~org.apache.thrift", "lib/java/gradle.properties", "jking", "" ] + - [ "JavaScript", "Bower", "https://libraries.io/bower/thrift", "bower.json", "", "" ] + - [ "Lua", "LuaRocks", "https://luarocks.org/modules/drauschenbach/thrift", "", "", "not official - stale at 0.10.0 - see THRIFT-4708" ] + - [ "Node.js", "npm", "https://www.npmjs.com/package/thrift", "package.json", "jfarrell, wadey, jking", "" ] + - [ "OCaml", "opam", "https://opam.ocaml.org/packages/thrift/", "lib/ocaml/opam", "", "stale at 0.9.0 (community provided) - see THRIFT-4706" ] + - [ "Perl", "CPAN", "https://metacpan.org/release/Thrift", "lib/perl/Makefile.PL", "jking", "" ] + - [ "PHP", "Packagist", "https://packagist.org/packages/apache/thrift", "composer.json", "jfarrell, bufferoverflow, jking", "" ] + - [ "Python", "pypi", "https://pypi.python.org/pypi/thrift", "lib/py/setup.py", "jfarrell", "stale at 0.11.0 - see THRIFT-4687" ] + - [ "Ruby", "Ruby Gem", "https://rubygems.org/gems/thrift", "lib/rb/Gemfile", "jfarrell", "stale at 0.11.0 - see THRIFT-4707" ] + - [ "Rust", "Cargo", "https://crates.io/crates/thrift", "lib/rs/cargo.toml", "all thrift committers", "" ] + - [ "Smalltalk", "", "", "", "", "no official ASF package available" ] + - [ "Swift", "", "", "", "", "no official ASF package available" ] + diff --git a/_includes/footer.html b/_includes/footer.html index 7a7dd03..ab186b2 100644 --- a/_includes/footer.html +++ b/_includes/footer.html @@ -1,33 +1,32 @@ <div class="container"> - <hr> - <footer class="footer"> - <div class="row"> - <div class="span3"> - <h3>Links</h3> - <ul class="unstyled"> - <li><a href="/download">Download</a></li> - <li><a href="/developers">Developers</a></li> - <li><a href="/tutorial">Tutorials</a></li> - </ul> - <ul class="unstyled"> - <li><a href="/sitemap">Sitemap</a></li> - </ul> - </div> - <div class="span3"> - <h3>Get Involved</h3> - <ul class="unstyled"> - <li><a href="/mailing">Mailing Lists</a></li> - <li><a href="{{ conf.jira_url }}">Issue Tracking</a></li> - <li><a href="/docs/HowToContribute">How To Contribute</a></li> - </ul> - </div> - <div class="span6"> - <a href="http://www.apache.org/"><img src="/static/images/feather.svg" onerror="this.src='/static/images/feather.png';this.onerror=null;" /></a> - Copyright ©2017 <a href="http://www.apache.org/">Apache Software Foundation</a>. - Licensed under the <a href="http://www.apache.org/licenses/">Apache License v2.0</a>. - Apache, Apache Thrift, and the Apache feather logo are trademarks of The Apache Software Foundation. - </div> - </div> - - </footer> + <hr> + <footer class="footer"> + <div class="row"> + <div class="span3"> + <h3>Links</h3> + <ul class="unstyled"> + <li><a href="/download">Download</a></li> + <li><a href="/developers">Developers</a></li> + <li><a href="/tutorial">Tutorials</a></li> + </ul> + <ul class="unstyled"> + <li><a href="/sitemap">Sitemap</a></li> + </ul> + </div> + <div class="span3"> + <h3>Get Involved</h3> + <ul class="unstyled"> + <li><a href="/mailing">Mailing Lists</a></li> + <li><a href="{{ site.jira_url }}">Issue Tracking</a></li> + <li><a href="/docs/HowToContribute">How To Contribute</a></li> + </ul> + </div> + <div class="span6"> + <a href="http://www.apache.org/"><img src="/static/images/feather.svg" onerror="this.src='/static/images/feather.png';this.onerror=null;" /></a> + Copyright © {{ 'now' | date: "%Y" }} <a href="http://www.apache.org/">Apache Software Foundation</a>. + Licensed under the <a href="http://www.apache.org/licenses/">Apache License v2.0</a>. + Apache, Apache Thrift, and the Apache feather logo are trademarks of The Apache Software Foundation. + </div> + </div> + </footer> </div> diff --git a/_includes/header.html b/_includes/header.html index 134dd19..2cfc78c 100644 --- a/_includes/header.html +++ b/_includes/header.html @@ -1,54 +1,28 @@ <div class="navbar"> - <div class="navbar-inner"> - <div class="container"> - <a class="brand" href="/">Apache Thrift ™</a> - <div class="nav-collapse"> - <ul class="nav pull-right"> - <li> - <a href="/download">Download</a> - </li> - <li> - <a href="/docs">Documentation</a> - </li> - <li> - <a href="/developers">Developers</a> - </li> - <li> - <a href="/lib">Libraries</a> - </li> - <li> - <a href="/tutorial">Tutorial</a> - </li> - <li> - <a href="/test">Test Suite</a> - </li> - <li> - <a href="/about">About</a> - </li> - <li class="dropdown"> - <a href="#" class="dropdown-toggle" data-toggle="dropdown"> - Apache <b class="caret"></b> - </a> - <ul class="dropdown-menu"> - <li> - <a href="http://www.apache.org/" target="_blank">Apache Home</a> - </li> - <li> - <a href="http://www.apache.org/licenses/" target="_blank">Apache License v2.0</a> - </li> - <li> - <a href="http://www.apache.org/foundation/sponsorship.html" target="_blank">Donate</a> - </li> - <li> - <a href="http://www.apache.org/foundation/thanks.html" target="_blank">Thanks</a> - </li> - <li> - <a href="http://www.apache.org/security/" target="_blank">Security</a> - </li> - </ul> - </li> - </ul> - </div> - </div> - </div> + <div class="navbar-inner"> + <div class="container"> + <a class="brand" href="/">Apache Thrift ™</a> + <div class="nav-collapse"> + <ul class="nav pull-right"> + <li><a href="/download">Download</a></li> + <li><a href="/docs">Documentation</a></li> + <li><a href="/developers">Developers</a></li> + <li><a href="/lib">Libraries</a></li> + <li><a href="/tutorial">Tutorial</a></li> + <li><a href="/test">Test Suite</a></li> + <li><a href="/about">About</a></li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Apache <b class="caret"></b></a> + <ul class="dropdown-menu"> + <li><a href="http://www.apache.org/" target="_blank">Apache Home</a></li> + <li><a href="http://www.apache.org/licenses/" target="_blank">Apache License v2.0</a></li> + <li><a href="http://www.apache.org/foundation/sponsorship.html" target="_blank">Donate</a></li> + <li><a href="http://www.apache.org/foundation/thanks.html" target="_blank">Thanks</a></li> + <li><a href="http://www.apache.org/security/" target="_blank">Security</a></li> + </ul> + </li> + </ul> + </div> + </div> + </div> </div> diff --git a/_includes/nav.html b/_includes/nav.html deleted file mode 100644 index f520c90..0000000 --- a/_includes/nav.html +++ /dev/null @@ -1,15 +0,0 @@ -<div class="leftnav"> - <ul> - <li><a href="/">Home</a></li> - <li><a href="/about">About</a></li> - <li><a href="/download">Download</a></li> - </ul> - <ul> - <li><a href="/developers">Developers</a></li> - <li><a href="/mailing">Mailing Lists</a></li> - <li><a href="/tutorial">Tutorials</a></li> - </ul> - <ul> - <li><a href="{{ conf.jira_url }}">Thrift Issue Tracking</a></li> - </ul> -</div> diff --git a/_layouts/default.html b/_layouts/default.html index 1d9808e..fb7307b 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -9,18 +9,20 @@ <link href="/static/css/style.css" rel="stylesheet" type="text/css" /> <link href="/static/css/codehilite.css" rel="stylesheet" type="text/css" /> <link href="/static/css/bootstrap.css" media="screen, projection" rel="stylesheet" type="text/css" /> + <link href="/static/css/thrift.css" media="screen, projection" rel="stylesheet" type="text/css" /> <script src="/static/js/jquery.min.js"></script> - <script src="/static/js/bootstrap-dropdown.js"></script> + <script src="/static/js/bootstrap-dropdown.js"></script> <script src="/static/js/bootstrap-tab.js"></script> - - <title>{{ conf.title }} - {% block title %}{{ headers.title }}{% endblock %}</title> + <script src="/static/js/thrift.js"></script> + + <title>{{ site.title }} - {{ page.title }}</title> </head> <body> - {% include 'header' %} - <div class="container"> - {% block content %}{{ content|markdown }}{% endblock %} - </div> - {% include 'footer' %} + {% include header.html %} + <div class="container"> + {{ content }} + </div> + {% include footer.html %} </body> </html> diff --git a/_layouts/tutorial.html b/_layouts/tutorial.html new file mode 100644 index 0000000..b0a51c1 --- /dev/null +++ b/_layouts/tutorial.html @@ -0,0 +1,21 @@ +--- +layout: default +--- + +<h2>{{ page.title }} Tutorial</h2> + +<h3>Introduction</h3> + +<p> +All Apache Thrift tutorials require that you have: + +<ol> + <li>The Apache Thrift Compiler and Libraries, see <a href="/download">Download</a> and <a href="/docs/BuildingFromSource">Building from Source</a> for more details.</li> + <li>Generated the <a href="https://github.com/apache/thrift/blob/master/tutorial/tutorial.thrift">tutorial.thrift</a> and <a href="https://github.com/apache/thrift/blob/master/tutorial/shared.thrift">shared.thrift</a> files:<br> + <pre><code>thrift -r --gen {{ page.librarylang }} tutorial.thrift</code></pre> + </li> + <li>Followed all prerequisites listed below.</li> +</ol> + +{{ content }} + diff --git a/_layouts/tutorial_intro.md b/_layouts/tutorial_intro.md deleted file mode 100644 index 38c6db5..0000000 --- a/_layouts/tutorial_intro.md +++ /dev/null @@ -1,12 +0,0 @@ -## {{ headers.title }} Tutorial ----- - -### Introduction -All Apache Thrift tutorials require that you have: - -1. The Apache Thrift Compiler and Libraries, see [Download](/download) and [Building from Source](/docs/BuildingFromSource) for more details. -1. Generated the [tutorial.thrift](https://github.com/apache/thrift/blob/master/tutorial/tutorial.thrift) and [shared.thrift](https://github.com/apache/thrift/blob/master/tutorial/shared.thrift) files: - - thrift -r --gen {{ headers.library_lang }} tutorial.thrift - -1. Followed all prerequisites listed below. diff --git a/about.md b/about.md index c4a9547..3a802d5 100644 --- a/about.md +++ b/about.md @@ -1,21 +1,22 @@ --- title: "About" --- -Apache Thrift is a software project spanning a variety of programming languages and use cases. Our goal is to make reliable, performant communication and data serialization across languages as efficient and seamless as possible. Originally developed at Facebook, Thrift was open sourced in April 2007 and entered the Apache Incubator in May, 2008. Thrift became an Apache TLP in October, 2010. + +Apache Thrift is a software project spanning a variety of programming languages and use cases. Our goal is to make reliable, performant communication and data serialization across languages as efficient and seamless as possible. Originally developed at Facebook, Thrift was open sourced in April 2007 and entered the Apache Incubator in May, 2008. Thrift became an Apache TLP in October, 2010. Apache Thrift aims to embody the following values: * **Simplicity** - Thrift code is simple and approachable, free of unnecessary dependencies. + Thrift code is simple and approachable, free of unnecessary dependencies. * **Transparency** - Thrift conforms to the most common idioms in all languages. + Thrift conforms to the most common idioms in all languages. * **Consistency** - Niche, language-specific features belong in extensions, not the core library. + Niche, language-specific features belong in extensions, not the core library. * **Performance** - Strive for performance first, elegance second. + Strive for performance first, elegance second. ---- @@ -25,24 +26,24 @@ Project Team ### Committers <div class="committers"> - <table class="table table-bordered table-striped"> - <tbody> - <tr> - <td><b>Apache ID</b></td> - <td><b>Full Name</b></td> - <td><b>Specialities</b></td> - <td><b>Timezone</b></td> - </tr> - {% for item in conf.committers %} - <tr class=""> - <td class="username">{{ item.0 }}</td> - <td class="fullname">{{ item.1 }}</td> - <td>{{ item.2 }}</td> - <td align="right">{{ item.3 }}</td> - </tr> - {% endfor %} - </tbody> - </table> + <table class="table table-bordered table-striped"> + <tbody> + <tr> + <td><b>Apache ID</b></td> + <td><b>Full Name</b></td> + <td><b>Specialities</b></td> + <td><b>Timezone</b></td> + </tr> + {% for item in site.committers %} + <tr class=""> + <td class="username">{{ item[0] }}</td> + <td class="fullname">{{ item[1] }}</td> + <td>{{ item[2] }}</td> + <td align="right">{{ item[3] }}</td> + </tr> + {% endfor %} + </tbody> + </table> </div> ### Champion @@ -66,10 +67,10 @@ The following companies are known to employ Apache Thrift in their production se <td><b>Company</b></td> <td><b>Website</b></td> </tr> - {% for item in conf.powered_by %} + {% for item in site.powered_by %} <tr class=""> - <td class="company">{{ item.0 }}</td> - <td class="website"><a href="{{ item.1 }}">{{ item.1 }}</a></td> + <td class="company">{{ item[0] }}</td> + <td class="website"><a href="{{ item[1] }}">{{ item[1] }}</a></td> </tr> {% endfor %} </tbody> @@ -87,10 +88,10 @@ Apache Thrift is widely used in lots of other Open Source projects. These are so <td><b>Project</b></td> <td><b>Website</b></td> </tr> - {% for item in conf.oss_projects %} + {% for item in site.oss_projects %} <tr class=""> - <td class="company">{{ item.0 }}</td> - <td class="website"><a href="{{ item.1 }}">{{ item.1 }}</a></td> + <td class="company">{{ item[0] }}</td> + <td class="website"><a href="{{ item[1] }}">{{ item[1] }}</a></td> </tr> {% endfor %} </tbody> @@ -108,13 +109,13 @@ There's also plenty of other Apache projects who are using and/or supporting Thr <td><b>Project</b></td> <td><b>Website</b></td> </tr> - {% for item in conf.apache_projects %} + {% for item in site.apache_projects %} <tr class=""> - <td class="company">{{ item.0 }}</td> - <td class="website"><a href="{{ item.1 }}">{{ item.1 }}</a></td> + <td class="company">{{ item[0] }}</td> + <td class="website"><a href="{{ item[1] }}">{{ item[1] }}</a></td> </tr> {% endfor %} </tbody> </table> </div> - + diff --git a/developers.md b/developers.md index 42f9984..142cb6d 100644 --- a/developers.md +++ b/developers.md @@ -1,34 +1,31 @@ --- title: "Developers" --- -##Contributing -Anyone interested in contributing to Apache Thrift should read the [How to Contribute](/docs/HowToContribute) guide prior to submitting any patches to [Jira]({{ conf.jira_url }}). There's also a short guide on [how to add new language bindings](/docs/HowToNewLanguage). If you have any questions about this please [contact us](/mailing). ---- +## Contributing +Anyone interested in contributing to Apache Thrift should read the [How to Contribute](/docs/HowToContribute) guide prior to submitting any patches to [Jira]({{ site.jira_url }}). There's also a short guide on [how to add new language bindings](/docs/HowToNewLanguage). If you have any questions about this please [contact us](/mailing). -##Issue Tracking -Apache Thrift tracks both bugs and enhancements using [Jira]({{ conf.jira_url }}). Before filing new requests, we ask that you first do the following: +## Issue Tracking +Apache Thrift tracks both bugs and enhancements using [Jira]({{ site.jira_url }}). Before filing new requests, we ask that you first do the following: -* Search the [Jira]({{ conf.jira_url }}) database +* Search the [Jira]({{ site.jira_url }}) database * Check the [user mailing list](/mailing) via searching the archives or asking a question - ---- ## Source Control The Apache Thrift source code resides in [GitHub](https://github.com/apache/thrift). Three types of access are available: * **Web-Access (read-only)** - Source code can be browsed via the Web: - - [https://github.com/apache/thrift](https://github.com/apache/thrift) +Source code can be browsed via the Web: + +[https://github.com/apache/thrift](https://github.com/apache/thrift) * **Anonymous (read-only) git** - git clone https://github.com/apache/thrift.git - + git clone https://github.com/apache/thrift.git + * **Committer Access (read-write)** - General instructions for committer access is [here](https://git-wip-us.apache.org/#committers-getting-started). It is a little stale (especially the netrc file information). +General instructions for committer access is [here](https://git-wip-us.apache.org/#committers-getting-started). It is a little stale (especially the netrc file information). - git clone [email protected]:apache/thrift.git + git clone [email protected]:apache/thrift.git diff --git a/docs/BuildingFromSource.md b/docs/BuildingFromSource.md index a7c0a2d..1918aab 100644 --- a/docs/BuildingFromSource.md +++ b/docs/BuildingFromSource.md @@ -1,76 +1,77 @@ --- title: "Building From Source" -kind: doc +isdoc: true --- + ## Building from source First make sure your system meets all necessary [Apache Thrift Requirements](/docs/install) If you are building from the first time out of the source repository, you will need to generate the configure scripts. (This is not necessary if you downloaded a released tarball.) From the top directory, do: - ./bootstrap.sh + ./bootstrap.sh Once the configure scripts are generated, thrift can be configured. From the top directory, do: - ./configure + ./configure Disable a language: - ./configure --without-java + ./configure --without-java You may need to specify the location of the boost files explicitly. If you installed boost in /usr/local, you would run configure as follows: - ./configure --with-boost=/usr/local + ./configure --with-boost=/usr/local If you want to override the logic of the detection of the Java SDK, use the JAVAC environment variable: - ./configure JAVAC=/usb/bin/javac + ./configure JAVAC=/usb/bin/javac Note that by default the thrift C++ library is typically built with debugging symbols included. If you want to customize these options you should use the CXXFLAGS option in configure, as such: - ./configure CXXFLAGS='-g -O2' - ./configure CFLAGS='-g -O2' - ./configure CPPFLAGS='-DDEBUG_MY_FEATURE' + ./configure CXXFLAGS='-g -O2' + ./configure CFLAGS='-g -O2' + ./configure CPPFLAGS='-DDEBUG_MY_FEATURE' To see other configuration options run - ./configure --help + ./configure --help Once you have run configure you can build Thrift via make: - make + make and run the test suite: - make check + make check and the cross language test suite: - sh test/test.sh + sh test/test.sh ### Issues while compiling * "compiler/cpp/thriftl.cc:2190: undefined reference to `yywrap'" - you need to install the [Flex library](https://github.com/westes/flex) (See also [Apache Thrift Requirements](/docs/install) ) and re-run the configuration script. +you need to install the [Flex library](https://github.com/westes/flex) (See also [Apache Thrift Requirements](/docs/install) ) and re-run the configuration script. * mv: cannot stat "'.deps/TBinaryProtocol.Tpo': No such file or directory" while building the Thrift Runtime Library - Re-reun configure with - - --enable-libtool-lock +Re-reun configure with + + --enable-libtool-lock - or by turning off parallel make by placing **.NOTPARALLEL:** in lib/cpp/Makefile or +or by turning off parallel make by placing **.NOTPARALLEL:** in lib/cpp/Makefile or - make -j 1 + make -j 1 - Although the thrift compiler build appears to be compatible with parallel make without libtool lock, the thrift runtime build is not. +Although the thrift compiler build appears to be compatible with parallel make without libtool lock, the thrift runtime build is not. ## Installing From the top directory, become superuser and do: - make install + make install Note that some language packages must be installed manually using build tools better suited to those languages (this applies to Java, Ruby, PHP). diff --git a/docs/HowToContribute.md b/docs/HowToContribute.md index 2848284..fc902e9 100644 --- a/docs/HowToContribute.md +++ b/docs/HowToContribute.md @@ -1,5 +1,6 @@ --- title: "How To Contribute" -kind: doc +isdoc: true --- + [snippet:path=CONTRIBUTING.md] diff --git a/docs/HowToNewLanguage.md b/docs/HowToNewLanguage.md index 767c813..a77c5bb 100644 --- a/docs/HowToNewLanguage.md +++ b/docs/HowToNewLanguage.md @@ -1,7 +1,8 @@ --- title: "How to add new language bindings" -kind: doc +isdoc: true --- + ## Roadmap for adding new language bindings When considering new language bindings, there are certain points to think about. First, you should find out, if you are about to implement completely new language bindings that are not yet supported with Thrift, or if you just want to add support for a specific "flavour" of an already implemented language. @@ -17,7 +18,7 @@ In that case, it is recommended to add the new feature as an option to the exist The good news is, although there is some work required, the process is not as hard as it looks. First, make sure you have a fully functional build environment and are able to [build the compiler from source](/docs/BuildingFromSource). Read the [How to Contribute](/docs/HowToContribute) section to understand, how the general contribution process works. -Next, search [Jira]({{ conf.jira_url }}) and maybe the mailing list archives. If you do not find anything similar, create a new ticket, shortly describing what you are planning. If you are not quite sure, ask on the [developer's mailing list](/mailing). +Next, search [Jira]({{ site.jira_url }}) and maybe the mailing list archives. If you do not find anything similar, create a new ticket, shortly describing what you are planning. If you are not quite sure, ask on the [developer's mailing list](/mailing). Now fork the [Apache Thrift code base](https://thrift.apache.org/developers) on GitHub. Although we accept patch files, especially for comparingly long-living feature branches (such as adding a new language) a GitHub branch is much easier to handle. @@ -25,7 +26,7 @@ Now fork the [Apache Thrift code base](https://thrift.apache.org/developers) on * Implement the [code generator](https://github.com/apache/thrift/tree/master/compiler/cpp/src/generate), typically by picking one from the existing pool that is close to what you need. There are already plenty of languages supported, and you'll find oop, procedural and functional styles. If in doubt, which one to choose of the two or three candidates you found, head to the next point -* Implement the Thrift library for that particular language, again by picking one of the [existing libraries](https://github.com/apache/thrift/tree/master/lib) as a starting point. Because the libraries differ largely with regard to the "depth" of their implementations it is recommended to have a closer look on what is implemented, and what is not. +* Implement the Thrift library for that particular language, again by picking one of the [existing libraries](https://github.com/apache/thrift/tree/master/lib) as a starting point. Because the libraries differ largely with regard to the "depth" of their implementations it is recommended to have a closer look on what is implemented, and what is not. * Implement the standardized [Thrift cross platform test](https://github.com/apache/thrift/tree/master/test) and make sure all tests succeed when run against at least one other language. This ensures interoperability and makes sure that the code does not only work when talking with yourself (= same language). You may also add other tests, but these should be put into `lib/yourlang/test` rather than `test/yourlang` - the latter is intended to host solely the standardized cross platform test. @@ -46,20 +47,20 @@ These are not strictly required in the first run, but are commonly used. Dependi * Transports: HTTP server, Pipes, NamedPipes (where it makes sense) * Protocols: Compact * Server types: Nonblocking, Threaded and/or Threadpool server implementation - - + + ### Final things - + * Add a `Readme.md` file to your library's folder, describing requirements, dependencies and what else might be important. Look at the existing Readme files if you are unsure about what to put into that file. * Make sure the generator, library, tests and tutorial have proper `makefile.am` files. Include everything into the build/test scripts. If you need help with these steps, don't hesitate to ask on the mailing lists. -* Your done, now open a pull request! +* You're done, now open a pull request! ## Remarks Note that the 4 implementation steps are not really a linear process, it is more kind of an iteration. Even if the code that comes out of the generator finally is compileable and does not spit out any warnings and seems to run fine, you still will run into problems as you move on with implementing library and tests. This is fully normal and expected. - + It is a good idea to post your work early on the mailing lists, and to create the JIRA ticket early - that's why this particular point is on top of the list. This serves not only the purpose of announcing the work you are about to do, it is also a good starting point for other people who might be just looking for exactly that stuff. You will be able not only to get valuable early feedback, but probably also be able to raise some support with implementation and/or testing. Having someone [...] diff --git a/docs/Languages.md b/docs/Languages.md index d9262ba..d217e9d 100644 --- a/docs/Languages.md +++ b/docs/Languages.md @@ -1,11 +1,9 @@ --- title: "Language and Feature Matrix" -kind: doc +isdoc: true --- -[This page on GitHub](https://github.com/apache/thrift/blob/master/LANGUAGES.md) - -[snippet:path=LANGUAGES.md] - +[This page on GitHub](https://github.com/apache/thrift/blob/master/LANGUAGES.md) +[snippet:path=LANGUAGES.md] diff --git a/docs/coding_standards.md b/docs/coding_standards.md index 1aa47e4..9cf9f7a 100644 --- a/docs/coding_standards.md +++ b/docs/coding_standards.md @@ -1,5 +1,6 @@ --- title: "Coding standards" -kind: doc +isdoc: true --- -[snippet:path=doc/coding_standards.md] \ No newline at end of file + +[snippet:path=doc/coding_standards.md] diff --git a/docs/committers/AdditionalReading.md b/docs/committers/AdditionalReading.md index 898d909..34e82ea 100644 --- a/docs/committers/AdditionalReading.md +++ b/docs/committers/AdditionalReading.md @@ -1,7 +1,7 @@ --- title: "General articles and links for committers" -kind: doc --- + ## Useful articles for committers * [ASF Releases FAQ](http://www.apache.org/dev/release.html) * [Signing Releases](http://www.apache.org/dev/release-signing.html) diff --git a/docs/committers/HowToCommit.md b/docs/committers/HowToCommit.md index 1661018..02fc352 100644 --- a/docs/committers/HowToCommit.md +++ b/docs/committers/HowToCommit.md @@ -1,5 +1,5 @@ --- title: "How To Commit" -kind: doc --- + [snippet:path=doc/committers.md] diff --git a/docs/committers/HowToThriftWebsite.md b/docs/committers/HowToThriftWebsite.md index 386147d..eb4277c 100644 --- a/docs/committers/HowToThriftWebsite.md +++ b/docs/committers/HowToThriftWebsite.md @@ -1,7 +1,7 @@ --- title: "How to update the website" -kind: doc --- + ## Apache Thrift Website The thrift website is made up of markdown files with YAML headers and templates, and uses the [Apache CMS](http://www.apache.org/dev/cms). @@ -42,17 +42,17 @@ ensure your source content is easily understood by by blank lines, - Preferring four-space indents per level over tab characters. -Not only will your readers prefer a clean style, it will result in fewer bugs and a more +Not only will your readers prefer a clean style, it will result in fewer bugs and a more consistent experience with the various markdown parsers deployed by the CMS. ### Updating Release Versions The current release versioning is kept in the YAML __DATA__ section of the global "configuration file" [lib/path.pm](https://svn.apache.org/repos/asf/thrift/cms-site/trunk/lib/path.pm). Update -the following values and then following <b>Updating the Website</b> section below +the following values and then following <b>Updating the Website</b> section below - current_release: "{{ conf.current_release }}" - current_release_date: "{{ conf.current_release_date }}" + current_release: "{{ site.current_release }}" + current_release_date: "{{ site.current_release_date }}" ### Updating the website diff --git a/docs/committers/ReleaseManagement.md b/docs/committers/ReleaseManagement.md index 8283a54..28edf56 100644 --- a/docs/committers/ReleaseManagement.md +++ b/docs/committers/ReleaseManagement.md @@ -1,4 +1,6 @@ -Title: Release Management +--- +title: Release Management +--- [See it on GitHub](https://github.com/apache/thrift/blob/master/doc/ReleaseManagement.md) diff --git a/docs/committers/index.html b/docs/committers/index.html deleted file mode 100644 index ff1d669..0000000 --- a/docs/committers/index.html +++ /dev/null @@ -1,2 +0,0 @@ -{% extends 'default' %} -{% block title %}Index of committers/{% endblock %} diff --git a/docs/committers/index.md b/docs/committers/index.md new file mode 100644 index 0000000..97ded93 --- /dev/null +++ b/docs/committers/index.md @@ -0,0 +1,3 @@ +--- +title: "Index of committers/" +--- diff --git a/docs/concepts.md b/docs/concepts.md index e7298ef..9f96792 100644 --- a/docs/concepts.md +++ b/docs/concepts.md @@ -1,7 +1,8 @@ --- title: "Concepts" -kind: doc +isdoc: true --- + ## Thrift network stack Simple representation of the Apache Thrift networking stack <pre><code> diff --git a/docs/features.md b/docs/features.md index 7bbf53e..2b5de0e 100644 --- a/docs/features.md +++ b/docs/features.md @@ -1,8 +1,9 @@ --- title: "Features" -kind: doc +isdoc: true --- -## Apache Thrift Features + +## Apache Thrift Features * interface description language - Everything is specified in an IDL file from which bindings for many languages can be generated. See [Thrift IDL](/docs/idl) * language bindings - Thrift is supported in many languages and environments @@ -33,13 +34,13 @@ kind: doc * service inheritance - Subservices implement all functions of their base services and can have additional functions * asynchronous invocations - Functions that do not return a result can be invoked asynchronously so the client is not blocked until the server has finished processing the request. The server may execute asynchronous invocations of the same client in parallel/out of order * exceptions - If an error occurs a function can throw a standard or user-defined exception. See [Thrift Types](/docs/types) - * cyclic structs - Starting with version 0.9.2, Thrift supports structs that contain themselves, or other structs to be declared later. - + * cyclic structs - Starting with version 0.9.2, Thrift supports structs that contain themselves, or other structs to be declared later. + ## Non-features The following are not supported by Apache Thrift: * struct inheritance - Use struct composition instead * polymorphism - As there is no inheritance, polymorphism is also not supported * overloading - All methods within a service must be uniquely named - * heterogeneous containers - All items in a container must be of the same type + * heterogeneous containers - All items in a container must be of the same type * Null return - null cannot be returned directly from a function. Use a wrapper struct or a marker value instead diff --git a/docs/idl.md b/docs/idl.md index d030714..06dd803 100644 --- a/docs/idl.md +++ b/docs/idl.md @@ -1,5 +1,6 @@ --- title: "Interface Description Language (IDL)" -kind: doc +isdoc: true --- + [snippet:path=doc/specs/idl.md] diff --git a/docs/index.html b/docs/index.md similarity index 71% rename from docs/index.html rename to docs/index.md index 415aedb..1a3912b 100644 --- a/docs/index.html +++ b/docs/index.md @@ -1,7 +1,7 @@ -{% extends 'default' %} -{% block title %}Documentation{% endblock %} -{% block content %} -{% filter markdown %} +--- +title: Documentation +--- + # Apache Thrift Documentation ## Documentation Topics @@ -10,16 +10,20 @@ Each supported language needs the Apache Thrift Libraries and the generated code Some language specific documentation is for the Apache Thrift Libraries are generated from lib/${language}/README.md files: -{{ content|safe }} +<ul> +{% for item in site.pages %} +{% if item.isdoc %} + <li><a href="{{item.url}}">{{item.title}}</a></li> +{% endif %} +{% endfor %} +</ul> ## Other resources -For a quick introduction that covers a lot of Thrift knowledge on just one page, we recommended +For a quick introduction that covers a lot of Thrift knowledge on just one page, we recommended Diwaker Gupta's [Thrift: The Missing Guide](https://diwakergupta.github.io/thrift-missing-guide). -If you want to do a real deep dive into the various language bindings, consider Randy Abernethy's -[The Programmer's Guide to Apache Thrift](https://www.manning.com/books/programmers-guide-to-apache-thrift). +If you want to do a real deep dive into the various language bindings, consider Randy Abernethy's +[The Programmer's Guide to Apache Thrift](https://www.manning.com/books/programmers-guide-to-apache-thrift). The book comes with a lot of inside knowlegde and is packed with practical examples. -{% endfilter %} -{% endblock %} diff --git a/docs/install/centos.md b/docs/install/centos.md index 377f940..16c157e 100644 --- a/docs/install/centos.md +++ b/docs/install/centos.md @@ -1,5 +1,6 @@ --- title: "Centos 6.5 Install" -kind: doc +isinstall: true --- -[snippet:path=doc/install/centos.md] \ No newline at end of file + +[snippet:path=doc/install/centos.md] diff --git a/docs/install/debian.md b/docs/install/debian.md index 5519f40..3df529b 100644 --- a/docs/install/debian.md +++ b/docs/install/debian.md @@ -1,19 +1,6 @@ -Title: Debian/Ubuntu install -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Debian/Ubuntu install +isinstall: true +--- -[snippet:path=doc/install/debian.md] \ No newline at end of file +[snippet:path=doc/install/debian.md] diff --git a/docs/install/index.html b/docs/install/index.md similarity index 87% rename from docs/install/index.html rename to docs/install/index.md index df871d4..f486574 100644 --- a/docs/install/index.html +++ b/docs/install/index.md @@ -1,10 +1,16 @@ -{% extends 'default' %} -{% block title %}Index of install/{% endblock %} -{% block content %}{% filter markdown %} --- +title: "Index of install/" +--- + Apache Thrift's compiler is written in C++ and designed to be portable, but there are some system requirements which must be installed prior to use. Select your os below for a guide on setting up your system to get started -{{ content|markdown }} +<ul> +{% for item in site.pages %} +{% if item.isinstall %} + <li><a href="{{item.url}}">{{item.title}}</a></li> +{% endif %} +{% endfor %} +</ul> --- @@ -16,7 +22,7 @@ Apache Thrift's compiler is written in C++ and designed to be portable, but ther * Runtime libraries for lex and yacc might be needed for the compiler. ## Requirements for building from source -* GNU build tools: +* GNU build tools: * autoconf 2.65 * automake 1.13 * libtool 1.5.24 @@ -25,7 +31,7 @@ Apache Thrift's compiler is written in C++ and designed to be portable, but ther * libssl-dev ## Requirements for building the compiler from source on Windows -* Visual Studio C++ +* Visual Studio C++ * Flex and Bison (e.g. the WinFlexBison package) ## Language requirements @@ -51,7 +57,3 @@ These are only required if you choose to build the libraries for the given langu * Go 1.4 * Delphi 2010 - -{% endfilter %}{% endblock %} - - diff --git a/docs/install/os_x.md b/docs/install/os_x.md index 4ded3cd..b7e0320 100644 --- a/docs/install/os_x.md +++ b/docs/install/os_x.md @@ -1,5 +1,6 @@ --- title: "OS X Install" -kind: doc +isinstall: true --- -[snippet:path=doc/install/os_x.md] \ No newline at end of file + +[snippet:path=doc/install/os_x.md] diff --git a/docs/install/windows.md b/docs/install/windows.md index 29d899c..8534185 100644 --- a/docs/install/windows.md +++ b/docs/install/windows.md @@ -1,5 +1,6 @@ --- -title: "Windows Install" -kind: doc +title: "Windows Install" +isinstall: true --- -[snippet:path=doc/install/windows.md] \ No newline at end of file + +[snippet:path=doc/install/windows.md] diff --git a/docs/types.md b/docs/types.md index 6ac86f8..be04aad 100644 --- a/docs/types.md +++ b/docs/types.md @@ -1,7 +1,8 @@ --- title: "Thrift Type system" -kind: doc +isdoc: true --- + ## Thrift Types The Thrift type system is intended to allow programmers to use native types as much as possible, no matter what programming language they are working in. This information is based on, and supersedes, the information in the [Thrift Whitepaper](/static/files/thrift-20070401.pdf). The [Thrift IDL](/docs/idl) provides descriptions of the types which are used to generate code for each target language. @@ -48,4 +49,4 @@ Services are defined using Thrift types. Definition of a service is semantically A service consists of a set of named functions, each with a list of parameters and a return type. -Note that void is a valid type for a function return, in addition to all other defined Thrift types. Additionally, an oneway modifier keyword may be added to a void function, which will generate code that does not wait for a response. Note that a pure void function will return a response to the client which guarantees that the operation has completed on the server side. With oneway method calls the client will only be guaranteed that the request succeeded at the transport layer. Oneway m [...] \ No newline at end of file +Note that void is a valid type for a function return, in addition to all other defined Thrift types. Additionally, an oneway modifier keyword may be added to a void function, which will generate code that does not wait for a response. Note that a pure void function will return a response to the client which guarantees that the operation has completed on the server side. With oneway method calls the client will only be guaranteed that the request succeeded at the transport layer. Oneway m [...] diff --git a/download.md b/download.md index de5aa49..c1421a5 100644 --- a/download.md +++ b/download.md @@ -1,24 +1,25 @@ --- title: "Download" --- + ## Release -The latest stable release of Thrift is {{ conf.current_release }} (released on {{ conf.current_release_date }}). +The latest stable release of Thrift is {{ site.current_release }} (released on {{ site.current_release_date }}). -* [thrift-{{ conf.current_release }}.tar.gz]({{ conf.mirror_url }}/thrift/{{ conf.current_release }}/thrift-{{ conf.current_release }}.tar.gz) \[[PGP]({{ conf.release_url }}/{{ conf.current_release }}/thrift-{{ conf.current_release }}.tar.gz.asc)\] -\[[MD5]({{ conf.release_url }}/{{ conf.current_release }}/thrift-{{ conf.current_release }}.tar.gz.md5)\] -* [Thrift compiler for Windows (thrift-{{ conf.current_release }}.exe)]({{ conf.mirror_url }}/thrift/{{ conf.current_release }}/thrift-{{ conf.current_release }}.exe) \[[PGP]({{ conf.release_url }}/{{ conf.current_release }}/thrift-{{ conf.current_release }}.exe.asc)\] \[[MD5]({{ conf.release_url }}/{{ conf.current_release }}/thrift-{{ conf.current_release }}.exe.md5)\] +* [thrift-{{ site.current_release }}.tar.gz]({{ site.mirror_url }}/thrift/{{ site.current_release }}/thrift-{{ site.current_release }}.tar.gz) \[[PGP]({{ site.release_url }}/{{ site.current_release }}/thrift-{{ site.current_release }}.tar.gz.asc)\] +\[[MD5]({{ site.release_url }}/{{ site.current_release }}/thrift-{{ site.current_release }}.tar.gz.md5)\] +* [Thrift compiler for Windows (thrift-{{ site.current_release }}.exe)]({{ site.mirror_url }}/thrift/{{ site.current_release }}/thrift-{{ site.current_release }}.exe) \[[PGP]({{ site.release_url }}/{{ site.current_release }}/thrift-{{ site.current_release }}.exe.asc)\] \[[MD5]({{ site.release_url }}/{{ site.current_release }}/thrift-{{ site.current_release }}.exe.md5)\] ## Maven artifact <pre><code><dependency> <groupId>org.apache.thrift</groupId> <artifactId>libthrift</artifactId> - <version>{{ conf.current_release }}</version> + <version>{{ site.current_release }}</version> </dependency> </code></pre> -When downloading from a mirror, please be sure to [verify](http://www.apache.org/info/verification.html) the checksums and signature (see the MD5 and PGP links above). The [KEYS]({{ conf.release_url }}/KEYS) file contains the public key(s) used for signing releases. +When downloading from a mirror, please be sure to [verify](http://www.apache.org/info/verification.html) the checksums and signature (see the MD5 and PGP links above). The [KEYS]({{ site.release_url }}/KEYS) file contains the public key(s) used for signing releases. ---- +--- ## Incubator Releases Releases from the incubator ( less than 0.6.0 ) are available at the [Thrift Incubator Archive](http://archive.apache.org/dist/incubator/thrift) diff --git a/index.html b/index.md similarity index 82% rename from index.html rename to index.md index c7b0c1f..652d7cc 100644 --- a/index.html +++ b/index.md @@ -1,9 +1,10 @@ -{% extends 'default.html' %} -{% block title %}Home{% endblock %} -{% block content %} +--- +title: Home +--- + <div class="row"> <div class="span8"> - <p> + <p> The Apache Thrift software framework, for scalable cross-language services development, combines a software stack with a code generation engine to build services that work efficiently and seamlessly between C++, Java, Python, PHP, Ruby, Erlang, Perl, Haskell, C#, Cocoa, JavaScript, Node.js, Smalltalk, OCaml and Delphi and other languages. </p> <h3>Getting Started</h3> @@ -32,19 +33,19 @@ </div> <div class="span3 well center pull-right"> <h2>Download</h2> - <p>Apache Thrift v{{ conf.current_release }}</p> + <p>Apache Thrift v{{ site.current_release }}</p> <p> - <a class="btn btn-large" href="{{ conf.mirror_url }}/thrift/{{ conf.current_release }}/thrift-{{ conf.current_release }}.tar.gz"> - Download <small>v{{ conf.current_release }}</small> + <a class="btn btn-large" href="{{ site.mirror_url }}/thrift/{{ site.current_release }}/thrift-{{ site.current_release }}.tar.gz"> + Download <small>v{{ site.current_release }}</small> </a> </p> <p> <small> - <a href="{{ conf.release_url }}/{{ conf.current_release }}/thrift-{{ conf.current_release }}.tar.gz.md5">MD5</a> + <a href="{{ site.release_url }}/{{ site.current_release }}/thrift-{{ site.current_release }}.tar.gz.md5">MD5</a> </small> | <small> - <a href="{{ conf.release_url }}/{{ conf.current_release }}/thrift-{{ conf.current_release }}.tar.gz.asc">PGP</a> + <a href="{{ site.release_url }}/{{ site.current_release }}/thrift-{{ site.current_release }}.tar.gz.asc">PGP</a> </small> </p> <p> @@ -74,12 +75,12 @@ [snippet:path=tutorial/py/PythonClient.py:lang=python:lines=36,55] </div> <div class="tab-pane" id="3"> - Initialize the Server: + Initialize the Server: [snippet:path=tutorial/java/src/JavaServer.java:lang=java:lines:65,76] - The CalculatorHandler: - [snippet:path=tutorial/java/src/CalculatorHandler.java:lang=java:lines:28,91] + The CalculatorHandler: + [snippet:path=tutorial/java/src/CalculatorHandler.java:lang=java:lines:28,91] </div> </div> </div> -{% endblock %} + diff --git a/lib/c_glib.md b/lib/c_glib.md index 0a0cda2..7e31289 100644 --- a/lib/c_glib.md +++ b/lib/c_glib.md @@ -1,19 +1,6 @@ -Title: C GLib -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: C GLib +islib: true +--- -[snippet:path=lib/c_glib/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/c_glib/README.md:lines=22] diff --git a/lib/cl.md b/lib/cl.md index b85f204..1d205a6 100644 --- a/lib/cl.md +++ b/lib/cl.md @@ -1,19 +1,6 @@ -Title: Common Lisp Library README -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Common Lisp Library README +islib: true +--- -[snippet:path=lib/cl/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/cl/README.md:lines=22] diff --git a/lib/cpp.md b/lib/cpp.md index c6620f2..4df8225 100644 --- a/lib/cpp.md +++ b/lib/cpp.md @@ -1,19 +1,6 @@ -Title: C++ library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: C++ library +islib: true +--- -[snippet:path=lib/cpp/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/cpp/README.md:lines=22] diff --git a/lib/csharp.md b/lib/csharp.md index 91adfd2..be2feb0 100644 --- a/lib/csharp.md +++ b/lib/csharp.md @@ -1,19 +1,6 @@ -Title: C# library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: C# library +islib: true +--- -[snippet:path=lib/csharp/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/csharp/README.md:lines=22] diff --git a/lib/d.md b/lib/d.md index 46be608..95df3f2 100644 --- a/lib/d.md +++ b/lib/d.md @@ -1,19 +1,6 @@ -Title: D library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: D library +islib: true +--- -[snippet:path=lib/d/README.md:lines=23] \ No newline at end of file +[snippet:path=lib/d/README.md:lines=23] diff --git a/lib/delphi.md b/lib/delphi.md index 0463ab8..42c9e2c 100644 --- a/lib/delphi.md +++ b/lib/delphi.md @@ -1,19 +1,6 @@ -Title: Delphi library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Delphi library +islib: true +--- -[snippet:path=lib/delphi/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/delphi/README.md:lines=22] diff --git a/lib/erl.md b/lib/erl.md index 1dda83d..d0799b2 100644 --- a/lib/erl.md +++ b/lib/erl.md @@ -1,19 +1,6 @@ -Title: Erlang library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Erlang library +islib: true +--- -[snippet:path=lib/erl/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/erl/README.md:lines=22] diff --git a/lib/go.md b/lib/go.md index 01ae445..d5f10cb 100644 --- a/lib/go.md +++ b/lib/go.md @@ -1,19 +1,6 @@ -Title: Go library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Go library +islib: true +--- -[snippet:path=lib/go/README.md:lines=23] \ No newline at end of file +[snippet:path=lib/go/README.md:lines=23] diff --git a/lib/haxe.md b/lib/haxe.md index b8fdc8e..a12e81d 100644 --- a/lib/haxe.md +++ b/lib/haxe.md @@ -1,19 +1,6 @@ -Title: Haxe library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Haxe library +islib: true +--- -[snippet:path=lib/haxe/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/haxe/README.md:lines=22] diff --git a/lib/hs.md b/lib/hs.md index 8825087..77a7456 100644 --- a/lib/hs.md +++ b/lib/hs.md @@ -1,19 +1,6 @@ -Title: Haskell library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Haskell library +islib: true +--- -[snippet:path=lib/hs/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/hs/README.md:lines=22] diff --git a/lib/index.html b/lib/index.md similarity index 61% rename from lib/index.html rename to lib/index.md index c46b19d..f572a34 100644 --- a/lib/index.html +++ b/lib/index.md @@ -1,7 +1,7 @@ -{% extends 'default.html' %} -{% block title %}Library{% endblock %} -{% block content %} -{% filter markdown %} +--- +title: Library +--- + # Apache Thrift Libraries ## Source Tree @@ -10,10 +10,15 @@ Each supported language needs the Apache Thrift Libraries and the generated code Some language specific documentation is for the Apache Thrift Libraries are generated from lib/${language}/README.md files: -{{ content|safe }} +<ul> +{% for item in site.pages %} +{% if item.islib %} + <li><a href="{{item.url}}">{{item.title}}</a></li> +{% endif %} +{% endfor %} +</ul> ## Package manager information and references -{% endfilter %} <!-- place table outside filter/endfilter --> <div class="packages"> @@ -27,18 +32,17 @@ Some language specific documentation is for the Apache Thrift Libraries are gene <td><b>Maintainer</b></td> <td><b>Remarks</b></td> </tr> - {% for item in conf.external_packages %} + {% for item in site.external_packages %} <tr class=""> - <td class="language">{{ item.0 }}</td> - <td class="packman">{{ item.1 }}</td> - <td class="packurl"><a href="{{ item.2 }}">{{ item.2 }}</a></td> - <td class="ctrlfile">{{ item.3 }}</td> - <td class="maintainer">{{ item.4 }}</td> - <td class="remarks">{{ item.5 }}</td> + <td class="language">{{ item[0] }}</td> + <td class="packman">{{ item[1] }}</td> + <td class="packurl"><a href="{{ item[2] }}">{{ item[2] }}</a></td> + <td class="ctrlfile">{{ item[3] }}</td> + <td class="maintainer">{{ item[4] }}</td> + <td class="remarks">{{ item[5] }}</td> </tr> {% endfor %} </tbody> </table> </div> -{% endblock %} diff --git a/lib/java.md b/lib/java.md index 12c2bab..01924d9 100644 --- a/lib/java.md +++ b/lib/java.md @@ -1,19 +1,6 @@ -Title: Java library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Java library +islib: true +--- -[snippet:path=lib/java/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/java/README.md:lines=22] diff --git a/lib/js.md b/lib/js.md index b24e48b..afe4408 100644 --- a/lib/js.md +++ b/lib/js.md @@ -1,19 +1,6 @@ -Title: JavaScript library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: JavaScript library +islib: true +--- -[snippet:path=lib/js/README.md:lines=25] \ No newline at end of file +[snippet:path=lib/js/README.md:lines=25] diff --git a/lib/netstd.md b/lib/netstd.md index c2067d7..435b5d6 100644 --- a/lib/netstd.md +++ b/lib/netstd.md @@ -1,19 +1,6 @@ -Title: .NET Standard library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: .NET Standard library +islib: true +--- -[snippet:path=lib/netstd/README.md] \ No newline at end of file +[snippet:path=lib/netstd/README.md] diff --git a/lib/nodejs.md b/lib/nodejs.md index d16f33a..e590273 100644 --- a/lib/nodejs.md +++ b/lib/nodejs.md @@ -1,19 +1,6 @@ -Title: node.js library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: node.js library +islib: true +--- -[snippet:path=lib/nodejs/README.md:lines=23] \ No newline at end of file +[snippet:path=lib/nodejs/README.md:lines=23] diff --git a/lib/ocaml.md b/lib/ocaml.md index dffd258..cd929fe 100644 --- a/lib/ocaml.md +++ b/lib/ocaml.md @@ -1,19 +1,6 @@ -Title: OCaml library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: OCaml library +islib: true +--- -[snippet:path=lib/ocaml/README.md:lines=23] \ No newline at end of file +[snippet:path=lib/ocaml/README.md:lines=23] diff --git a/lib/perl.md b/lib/perl.md index ac1f826..59d1a31 100644 --- a/lib/perl.md +++ b/lib/perl.md @@ -1,19 +1,6 @@ -Title: Perl library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Perl library +islib: true +--- -[snippet:path=lib/perl/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/perl/README.md:lines=22] diff --git a/lib/php.md b/lib/php.md index 3cfed1f..89a43fe 100644 --- a/lib/php.md +++ b/lib/php.md @@ -1,19 +1,6 @@ -Title: PHP library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: PHP library +islib: true +--- -[snippet:path=lib/php/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/php/README.md:lines=22] diff --git a/lib/py.md b/lib/py.md index 4881ea3..750b8ea 100644 --- a/lib/py.md +++ b/lib/py.md @@ -1,19 +1,6 @@ -Title: Python library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Python library +islib: true +--- -[snippet:path=lib/py/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/py/README.md:lines=22] diff --git a/lib/rb.md b/lib/rb.md index e5fff6a..90b1836 100644 --- a/lib/rb.md +++ b/lib/rb.md @@ -1,19 +1,6 @@ -Title: Ruby library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Ruby library +islib: true +--- -[snippet:path=lib/rb/README.md:lines=22] \ No newline at end of file +[snippet:path=lib/rb/README.md:lines=22] diff --git a/lib/st.md b/lib/st.md index da6b74b..9eb970b 100644 --- a/lib/st.md +++ b/lib/st.md @@ -1,19 +1,6 @@ -Title: SmallTalk library -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: SmallTalk library +islib: true +--- -[snippet:path=lib/st/README.md:lines=28] \ No newline at end of file +[snippet:path=lib/st/README.md:lines=28] diff --git a/mailing.md b/mailing.md index 44bc453..a5de463 100644 --- a/mailing.md +++ b/mailing.md @@ -1,6 +1,7 @@ --- title: "Mailing Lists" --- + In accordance with the principles of the Apache Software Foundation, Thrift encourages a collaborative and community-based development environment. All project discussion is carried out publicly, on the following archived lists. diff --git a/perllib/path.pm b/perllib/path.pm index 2e29370..4f8c8c5 100644 --- a/perllib/path.pm +++ b/perllib/path.pm @@ -1,12 +1,12 @@ package path; - + use ASF::Util qw/walk_content_tree Load/; use strict; use warnings; my $thrift_snippet_footer = <<'EOT'; # '$snippet' string magically refers to current snippet obj <p class='snippet_footer'> - This snippet was generated by {{ conf.title }}'s <strong>source tree docs</strong>: + This snippet was generated by {{ site.title }}'s <strong>source tree docs</strong>: <a href="{{ $snippet.pretty_uri }}"</a>{{ $snippet.path }}</a> </p> EOT @@ -75,110 +75,3 @@ delete $dependencies{"/index.html"}; # the home page really doesn't depend on an 1; -__DATA__ -# Thrift Site Variables -title: "Apache Thrift" -base_url: "http://thrift.apache.org" -git_repo: "https://github.com/apache/thrift" -release_url: "https://www.apache.org/dist/thrift" -mirror_url: "http://www.apache.org/dyn/closer.cgi?path=" -jira_url: "http://issues.apache.org/jira/browse/THRIFT" - -current_release: "0.13.0" -current_release_date: "2019-OCT-16" - -# Apache ID, Name, Specialities, Timezone -committers: [ - [ "mcslee", "Mark Slee", "General vision and implementation", "-8" ], - [ "dreiss", "David Reiss", "Everything, GIT configuration, performance", "-8" ], - [ "aditya", "Aditya Agarwal", "C++ servers", "-8" ], - [ "marck", "Marc Kwiatkowski", "C++ concurrency", "-8" ], - [ "jwang", "James Wang", "C++ transports and processors", "-8" ], - [ "cpiro", "Chris Piro", "Erlang", "-8" ], - [ "bmaurer", "Ben Maurer", "Python data serialization", "-5" ], - [ "kclark", "Kevin Clark", "Ruby implementation", "-8" ], - [ "jake", "Jake Luciani", "Perl, JavaScript", "-5" ], - [ "bryanduxbury", "Bryan Duxbury", "Compact Protocol, Java, Ruby", "-8" ], - [ "esteve", "Esteve Fernandez", "Python, Twisted, async transports", "1" ], - [ "todd", "Todd Lipcon", "Erlang, Java", "-8" ], - [ "geechorama", "Andrew McGeachie", "Cocoa", "?" ], - [ "molinaro", "Anthony Molinaro", "Erlang, Perl, autotools", "-8" ], - [ "roger", "Roger Meier", "Continuous Integration, C++, C#, JavaScript, make cross and other stuff", "2" ], - [ "jfarrell", "Jake Farrell", "Release Manager, Build, Client Publishing, Java, PHP, Ruby", "-5" ], - [ "jensg", "Jens Geyer", "Delphi, C#/NetStd, Go, Graphviz, Haxe", "1" ], - [ "carl", "Carl Yeksigian", "C#", "-5" ], - [ "ra", "Randy Abernethy", "C++, Python, JavaScript, C#, what have you", "-8" ], - [ "hcorg", "Konrad Grochowski", "C++, Python, Git, Continuous Integration", "1"], - [ "nsuke", "Nobuaki Sukegawa ", "", "9"], - [ "simonsouth", "Simon South", "C (GLib)", "-5"], - ] - - -# Powered by: Company name, website -powered_by: [ - [ "Cloudera", "http://www.cloudera.com" ], - [ "Evernote", "http://evernote.com" ], - [ "Facebook", "http://www.facebook.com" ], - [ "last.fm", "http://www.last.fm" ], - [ "Mendeley", "http://www.mendeley.com" ], - [ "OpenX", "http://www.openx.org" ], - [ "Pinterest", "http://www.pinterest.com" ], - [ "Quora", "http://www.quora.com" ], - [ "RapLeaf", "http://www.rapleaf.com" ], - [ "reCaptcha", "http://www.recaptcha.com" ], - [ "Siemens", "http://www.siemens.com" ], - [ "Uber", "http://uber.com" ] - ] - -# Apache Projects using Thrift: Project name, website -apache_projects: [ - [ "Aurora", "http://aurora.apache.org" ], - [ "Camel", "http://camel.apache.org/" ], - [ "Hadoop", "http://wiki.apache.org/hadoop/HDFS-APIs" ], - [ "HBase", "http://wiki.apache.org/hadoop/Hbase/ThriftApi" ], - [ "Parquet", "https://parquet.apache.org" ], - [ "Storm", "http://storm.apache.org/" ] - ] - -# OSS Projects using Thrift: Project name, website -oss_projects: [ - [ "Microsoft Robust Distributed System Nucleus (rDSN)", "https://github.com/Microsoft/rDSN" ], - [ "Twitter Finagle", "http://twitter.github.io/finagle/guide/Protocols.html" ], - [ "Twitter Scrooge", "http://twitter.github.io/scrooge" ] - ] - -# external packages hosted elsewhere: -# - Thrift target language -# - package manager name -# - link to package (URL) to most recent version -# - package control file (git source tree link) -# - package maintainer name -# - remarks -external_packages: [ - [ "(all)", "Docker", "https://hub.docker.com/_/thrift/", "Dockerfile", "", "thrift compiler in /usr/local/bin/thrift" ], - [ "ActionScript","Maven", "https://repository.apache.org/#nexus-search;quick~libthrift-as3", "lib/as3/build.xml", "jking", "" ], - [ "C (glib)", "", "", "", "", "language has no package manager" ], - [ "C++", "", "", "", "", "see THRIFT-4800" ], - [ "C#", "NuGet", "https://www.nuget.org/packages/ApacheThrift", "ApacheThrift.nuspec", "jfarrell, codesf, jking", "multi-framework nupkg for csharp and netcore" ], - [ "Cocoa", "", "", "", "", "deprecated on 0.12.0 - use swift" ], - [ "Common LISP", "", "", "", "", "no official ASF package available" ], - [ "D", "dub", "https://code.dlang.org/packages/apache-thrift", "dub.json", "jking", "" ], - [ "Dart", "Pub", "https://pub.dartlang.org/packages/thrift", "lib/dart/pubspec.yaml", "jking", "" ], - [ ".NET Standard", "NuGet", "https://www.nuget.org/packages/ApacheThrift", "ApacheThrift.nuspec", "jfarrell, codesf, jking", "multi-framework nupkg for csharp and netcore" ], - [ "Erlang", "Hex PM", "https://hex.pm/packages?search=thrift&sort=downloads", "", "", "no official ASF package available" ], - [ "Haskell", "Hackage", "https://hackage.haskell.org/package/thrift", "lib/hs/thrift.cabal", "jfarrell, clavoie, jking", "" ], - [ "Haxe", "Haxelib", "", "lib/haxe/haxelib.json", "jensg", "no package uploaded - see THRIFT-3036" ], - [ "Go", "", "", "", "", "no official ASF package available" ], - [ "Java", "Maven", "https://repository.apache.org/#nexus-search;quick~org.apache.thrift", "lib/java/gradle.properties", "jking", "" ], - [ "JavaScript", "Bower", "https://libraries.io/bower/thrift", "bower.json", "", "" ], - [ "Lua", "LuaRocks", "https://luarocks.org/modules/drauschenbach/thrift", "", "", "not official - stale at 0.10.0 - see THRIFT-4708" ], - [ "Node.js", "npm", "https://www.npmjs.com/package/thrift", "package.json", "jfarrell, wadey, jking", "" ], - [ "OCaml", "opam", "https://opam.ocaml.org/packages/thrift/", "lib/ocaml/opam", "", "stale at 0.9.0 (community provided) - see THRIFT-4706" ], - [ "Perl", "CPAN", "https://metacpan.org/release/Thrift", "lib/perl/Makefile.PL", "jking", "" ], - [ "PHP", "Packagist", "https://packagist.org/packages/apache/thrift", "composer.json", "jfarrell, bufferoverflow, jking", "" ], - [ "Python", "pypi", "https://pypi.python.org/pypi/thrift", "lib/py/setup.py", "jfarrell", "stale at 0.11.0 - see THRIFT-4687" ], - [ "Ruby", "Ruby Gem", "https://rubygems.org/gems/thrift", "lib/rb/Gemfile", "jfarrell", "stale at 0.11.0 - see THRIFT-4707" ], - [ "Rust", "Cargo", "https://crates.io/crates/thrift", "lib/rs/cargo.toml", "all thrift committers", "" ], - [ "Smalltalk", "", "", "", "", "no official ASF package available" ], - [ "Swift", "", "", "", "", "no official ASF package available" ], - ] diff --git a/perllib/view.pm b/perllib/view.pm deleted file mode 100644 index ce2624f..0000000 --- a/perllib/view.pm +++ /dev/null @@ -1,6 +0,0 @@ -package view; - -# see https://svn.apache.org/repos/infra/websites/cms/build/lib/ASF/View.pm -use base 'ASF::View'; - -1; diff --git a/sitemap.html b/sitemap.html deleted file mode 100644 index 31a8d9e..0000000 --- a/sitemap.html +++ /dev/null @@ -1 +0,0 @@ -{% include 'default.html' %} diff --git a/sitemap.md b/sitemap.md new file mode 100644 index 0000000..252d1a6 --- /dev/null +++ b/sitemap.md @@ -0,0 +1,13 @@ +--- +title: Sitemap +sitemap_exclude: true +--- + +<ul> +{% for item in site.pages %} +{% unless item.sitemap_exclude %} + <li><a href="{{ item.url }}">{{ item.title }}</a></li> +{% endunless %} +{% endfor %} +</ul> + diff --git a/static/css/alerts.css b/static/css/alerts.css index 562826f..99bc123 100644 --- a/static/css/alerts.css +++ b/static/css/alerts.css @@ -28,7 +28,7 @@ .alert-success { background-color: @successBackground; - border-color: @successBorder; + border-color: @successBorder; } .alert-success, .alert-success .alert-heading { diff --git a/static/css/forms.css b/static/css/forms.css index 0a5fa2b..08d6bb3 100644 --- a/static/css/forms.css +++ b/static/css/forms.css @@ -301,7 +301,7 @@ select:focus:required:invalid { border-color: #ee5f5b; &:focus { border-color: darken(#ee5f5b, 10%); - .box-shadow(0 0 6px lighten(#ee5f5b, 20%)); + .box-shadow(0 0 6px lighten(#ee5f5b, 20%)); } } @@ -406,7 +406,7 @@ select:focus:required:invalid { } .uneditable-input { border-left-color: #eee; - border-right-color: #ccc; + border-right-color: #ccc; } .add-on { margin-right: 0; diff --git a/static/css/mixins.css b/static/css/mixins.css index 3cf1a37..701cd82 100644 --- a/static/css/mixins.css +++ b/static/css/mixins.css @@ -154,7 +154,7 @@ // Setup the mixins to be used .columns(@gridGutterWidth, @gridColumnWidth, @gridRowWidth, @columns) { width: (@gridColumnWidth * @columns) + (@gridGutterWidth * (@columns - 1)); - } + } .offset(@gridColumnWidth, @gridGutterWidth, @columns) { margin-left: (@gridColumnWidth * @columns) + (@gridGutterWidth * (@columns - 1)) + (@gridGutterWidth * 2); } diff --git a/static/css/sprites.css b/static/css/sprites.css index a774166..a7f9122 100644 --- a/static/css/sprites.css +++ b/static/css/sprites.css @@ -6,8 +6,8 @@ // ICONS // ----- -// All icons receive the styles of the <i> tag with a base class -// of .i and are then given a unique class to add width, height, +// All icons receive the styles of the <i> tag with a base class +// of .i and are then given a unique class to add width, height, // and background-position. Your resulting HTML will look like // <i class="icon-inbox"></i>. diff --git a/static/css/thrift.css b/static/css/thrift.css new file mode 100644 index 0000000..165acef --- /dev/null +++ b/static/css/thrift.css @@ -0,0 +1,25 @@ + +a.headerlink:hover { + text-decoration: none +} + +h1 > .headerlink, +h2 > .headerlink, +h3 > .headerlink, +h4 > .headerlink, +h5 > .headerlink, +h6 > .headerlink, +dt > .elementid-permalink { + visibility: hidden +} + +h1:hover > .headerlink, +h2:hover > .headerlink, +h3:hover > .headerlink, +h4:hover > .headerlink, +h5:hover > .headerlink, +h6:hover > .headerlink, +dt:hover > .elementid-permalink { + visibility: visible +} + diff --git a/static/css/type.css b/static/css/type.css index 6ba83bc..bcf06d6 100644 --- a/static/css/type.css +++ b/static/css/type.css @@ -196,7 +196,7 @@ blockquote { // Quotes q:before, q:after, -blockquote:before, +blockquote:before, blockquote:after { content: ""; } diff --git a/static/js/thrift.js b/static/js/thrift.js new file mode 100644 index 0000000..e90962f --- /dev/null +++ b/static/js/thrift.js @@ -0,0 +1,14 @@ + + $(function() { + // decorate section headers with anchors + return $("h2, h3, h4, h5, h6").each(function(i, el) { + var $el, icon, id; + $el = $(el); + id = $el.attr('id'); + icon = 'ΒΆ'; + if (id) { + return $el.append($("<a />").addClass("headerlink").attr("href", "#" + id).html(icon)); + } + }); + }); + diff --git a/test/ThriftTest.thrift b/test/ThriftTest.thrift index 726f1bf..e804a1c 100644 --- a/test/ThriftTest.thrift +++ b/test/ThriftTest.thrift @@ -1,3 +1,5 @@ -Title: ThriftTest +--- +title: ThriftTest +--- [snippet:path=test/ThriftTest.thrift:lang=text:numbers=1] diff --git a/test/index.md b/test/index.md index 895b457..370b0c6 100644 --- a/test/index.md +++ b/test/index.md @@ -1,5 +1,5 @@ -Title: Test Suite +--- +title: Test Suite +--- [snippet:path=test/README.md] - - diff --git a/test/keys.md b/test/keys.md index 7949edb..40a8b46 100644 --- a/test/keys.md +++ b/test/keys.md @@ -1,19 +1,5 @@ -Title: -Notice: Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. +--- +title: Keys +--- -[snippet:path=test/keys/README.md] \ No newline at end of file +[snippet:path=test/keys/README.md] diff --git a/tutorial/as3.md b/tutorial/as3.md index 66595e6..62eafc3 100644 --- a/tutorial/as3.md +++ b/tutorial/as3.md @@ -1,8 +1,9 @@ --- title: "Actionscript 3.0" -library_lang: "as3" +librarylang: "as3" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/c_glib.md b/tutorial/c_glib.md index 56820de..22faa07 100644 --- a/tutorial/c_glib.md +++ b/tutorial/c_glib.md @@ -1,8 +1,9 @@ --- title: "c_glib" -library_lang: "c_glib" +librarylang: "c_glib" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Client @@ -10,4 +11,4 @@ library_lang: "c_glib" ### Server -[snippet:path=tutorial/c_glib/c_glib_server.c:lang=c:lines=20,527] \ No newline at end of file +[snippet:path=tutorial/c_glib/c_glib_server.c:lang=c:lines=20,527] diff --git a/tutorial/cpp.md b/tutorial/cpp.md index 001cf9a..1e18f7a 100644 --- a/tutorial/cpp.md +++ b/tutorial/cpp.md @@ -1,8 +1,9 @@ --- title: "C++" -library_lang: "cpp" +librarylang: "cpp" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/csharp.md b/tutorial/csharp.md index da2e69a..6efa89d 100644 --- a/tutorial/csharp.md +++ b/tutorial/csharp.md @@ -1,8 +1,9 @@ --- title: "CSharp" -library_lang: "csharp" +librarylang: "csharp" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/d.md b/tutorial/d.md index 8449b60..3f2b774 100644 --- a/tutorial/d.md +++ b/tutorial/d.md @@ -1,8 +1,9 @@ --- title: "D" -library_lang: "d" +librarylang: "d" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/dart.md b/tutorial/dart.md index ec4cf5c..c893ca5 100644 --- a/tutorial/dart.md +++ b/tutorial/dart.md @@ -1,8 +1,9 @@ --- title: "Dart" -library_lang: "dart" +librarylang: "dart" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/delphi.md b/tutorial/delphi.md index 852c5c1..cb8cb40 100644 --- a/tutorial/delphi.md +++ b/tutorial/delphi.md @@ -1,8 +1,9 @@ --- title: "Delphi" -library_lang: "delphi" +librarylang: "delphi" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites * Thrift requires at least Delphi 2010. Earlier versions and FPC will not work due to the lack of Generics. diff --git a/tutorial/go.md b/tutorial/go.md index f51758b..0b53337 100644 --- a/tutorial/go.md +++ b/tutorial/go.md @@ -1,14 +1,15 @@ --- title: "Go" -library_lang: "go" +librarylang: "go" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites * At least Go 1.7 is required to run the tutorial code. * The GOPATH may need to be adjusted, alternatively manually put the Go Thrift library files into a suitable location. - * The Thrift library and compiler must be the same version. Applications might work even with a version mismatch, but this unsupported. + * The Thrift library and compiler must be the same version. Applications might work even with a version mismatch, but this unsupported. To use a specific version of the library, either clone the repository for that version, or use a package manager like [dep](https://golang.github.io/dep/) or [Go modules](https://github.com/golang/go/wiki/Modules). diff --git a/tutorial/graphviz.md b/tutorial/graphviz.md index cbc5085..800748d 100644 --- a/tutorial/graphviz.md +++ b/tutorial/graphviz.md @@ -1,20 +1,21 @@ --- title: "Graphviz" -library_lang: "cpp" +librarylang: "cpp" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites * A Graphviz renderer - The [official renderers](http://www.graphviz.org) can be used as a command line tool to produce a graphic from the '.gv' file +The [official renderers](http://www.graphviz.org) can be used as a command line tool to produce a graphic from the '.gv' file ### Overview The Graphviz generator is a convenient way to generate documentation diagrams for your API. Usage: - $ thrift -r --gen gv tutorial.thrift + thrift -r --gen gv tutorial.thrift This will create the file `gen-gv/tutorial.gv`, which is a [Graphviz source](http://en.wikipedia.org/wiki/DOT_(graph_description_language)) - a @@ -23,7 +24,7 @@ and functions diagram). You will need to actually render those graphs into any of the supported output formats (e.g. PNG, PDFs, SVG, etc.) by using a Graphiz renderer in your platform. - $ dot -Tpdf -otutorial.pdf gen-gv/tutorial.gv + dot -Tpdf -otutorial.pdf gen-gv/tutorial.gv ## Extra options @@ -32,4 +33,4 @@ exceptions (although the exception structures are displayed). You can set the generator to render those exceptions arrows (i.e. function throws) by using the "`exception`" option: - $ thrift -r --gen:gv:exceptions gv tutorial.thrift + thrift -r --gen:gv:exceptions gv tutorial.thrift diff --git a/tutorial/haxe.md b/tutorial/haxe.md index 0d8e16f..d74e4ad 100644 --- a/tutorial/haxe.md +++ b/tutorial/haxe.md @@ -1,29 +1,30 @@ --- title: "Haxe Framework" -library_lang: "haxe" +librarylang: "haxe" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites * Thrift requires at least Haxe 3.1.3. (You may try with older versions on your own luck). -### Client -For this tutorial, we put both the server and the client main code into one single program. +### Client +For this tutorial, we put both the server and the client main code into one single program. Depending on the arguments passed, it runs as a server or as a client program. [snippet:path=tutorial/haxe/src/Main.hx:lines=20,332] Were done with the client, but need some more for the server: A service handler implementaion. - + ### Server -As the name suggests, the service handler implements the Thrift service on the server side. +As the name suggests, the service handler implements the Thrift service on the server side. The code to achieve this is as follows: [snippet:path=tutorial/haxe/src/CalculatorHandler.hx:lines=20,102] ### Additional Information -Similar to Thrift, Haxe supports different compiler targets. Depending on the target, some features -may or may not be supported. For example, if you plan to use Flash or JavaScript targets, +Similar to Thrift, Haxe supports different compiler targets. Depending on the target, some features +may or may not be supported. For example, if you plan to use Flash or JavaScript targets, there is currently no way to pass command line arguments to the program. diff --git a/tutorial/hs.md b/tutorial/hs.md index 4a4d725..9958a8e 100644 --- a/tutorial/hs.md +++ b/tutorial/hs.md @@ -1,8 +1,9 @@ --- title: "Haskell" -library_lang: "hs" +librarylang: "hs" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/index.html b/tutorial/index.html deleted file mode 100644 index 3d42d93..0000000 --- a/tutorial/index.html +++ /dev/null @@ -1,42 +0,0 @@ -{% extends 'default.html' %} -{% block title %}Index of tutorial/{% endblock %} -{% block content %} -{% filter markdown %} -## Apache Thrift Tutorial ----- - -* ### Download Apache Thrift -To get started, [download](/download) a copy of Thrift. - -* ### Build and Install the Apache Thrift compiler and libraries -You will then need to build the Apache Thrift compiler and libraries. - - ./configure && make - - This will also compile the tutorial client and server for several languages. - See the [Building from source](/docs/BuildingFromSource) guide for any help with this step. - -* ### Writing a .thrift file -After the Thrift compiler is installed you will need to create a .thrift file. This file is an [interface definition](/docs/idl) made up of [thrift types](/docs/types) and Services. The services you define in this file are implemented by the server and are called by any clients. - -* ### Generate Thrift file to source code -The Thrift compiler is used to generate your Thrift file into source code which is used by the different client libraries and the server you write. To generate the source from a Thrift file run - - thrift --gen <language> <Thrift filename> - - To recursivly generate source code from a Thrift file and all other Thrift files included by it, run - - thrift -r --gen <language> <Thrift filename> - - The sample [tutorial.thrift](https://git-wip-us.apache.org/repos/asf?p=thrift.git;a=blob_plain;f=tutorial/tutorial.thrift) - file defines a basic calculator service. This sample calculator service .thrift file includes another file called - [shared.thrift](https://git-wip-us.apache.org/repos/asf?p=thrift.git;a=blob_plain;f=tutorial/shared.thrift). - Both files will be used to demonstrate how to build a Thrift client and server pair. - -## Examples Clients and Servers -{% endfilter %} -{{ content|markdown }} -{% endblock %} - - - diff --git a/tutorial/index.md b/tutorial/index.md new file mode 100644 index 0000000..b6085a0 --- /dev/null +++ b/tutorial/index.md @@ -0,0 +1,44 @@ +--- +title: "Index of tutorial/" +--- + +## Apache Thrift Tutorial + +* ### Download Apache Thrift +To get started, [download](/download) a copy of Thrift. + +* ### Build and Install the Apache Thrift compiler and libraries +You will then need to build the Apache Thrift compiler and libraries. + + ./configure && make + +This will also compile the tutorial client and server for several languages. +See the [Building from source](/docs/BuildingFromSource) guide for any help with this step. + +* ### Writing a .thrift file +After the Thrift compiler is installed you will need to create a .thrift file. This file is an [interface definition](/docs/idl) made up of [thrift types](/docs/types) and Services. The services you define in this file are implemented by the server and are called by any clients. + +* ### Generate Thrift file to source code +The Thrift compiler is used to generate your Thrift file into source code which is used by the different client libraries and the server you write. To generate the source from a Thrift file run + + thrift --gen <language> <Thrift filename> + +To recursivly generate source code from a Thrift file and all other Thrift files included by it, run + + thrift -r --gen <language> <Thrift filename> + +The sample [tutorial.thrift](https://git-wip-us.apache.org/repos/asf?p=thrift.git;a=blob_plain;f=tutorial/tutorial.thrift) +file defines a basic calculator service. This sample calculator service .thrift file includes another file called +[shared.thrift](https://git-wip-us.apache.org/repos/asf?p=thrift.git;a=blob_plain;f=tutorial/shared.thrift). +Both files will be used to demonstrate how to build a Thrift client and server pair. + +## Examples Clients and Servers + +<ul> +{% for item in site.pages %} +{% if item.tutorial %} + <li><a href="{{item.url}}">{{item.title}}</a></li> +{% endif %} +{% endfor %} +</ul> + diff --git a/tutorial/java.md b/tutorial/java.md index dc090e5..b2f7fc2 100644 --- a/tutorial/java.md +++ b/tutorial/java.md @@ -1,8 +1,9 @@ --- title: "Java" -library_lang: "java" +librarylang: "java" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/js.md b/tutorial/js.md index 98e1bc6..90502b4 100644 --- a/tutorial/js.md +++ b/tutorial/js.md @@ -1,10 +1,11 @@ --- title: "Javascript" -library_lang: "js" +librarylang: "js" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} -### Prerequisites +### Prerequisites * This tutorial depends on an existing Thrift server. See either the [Java tutorial](/tutorial/java) or [node.js tutorial](/tutorial/nodejs) for how to build and setup one of these servers. Out of the box, a Thrift HTTP server using the JSON protocol is expected. To learn more about how to use other transports and/or protocols refer to the "Additional Information" section below. @@ -34,7 +35,7 @@ function calc() { ### Server -Use either the [Java tutorial](/tutorial/java) or [C++ tutorial](/tutorial/cpp) server +Use either the [Java tutorial](/tutorial/java) or [C++ tutorial](/tutorial/cpp) server ## Additional Information @@ -62,7 +63,7 @@ Now that we have a functional Service Interface object created, we can can setup work.num2 = $("#num2").val(); work.op = $("#op").val(); -Once the object is created, we can now pass +Once the object is created, we can now pass try { result = client.calculate(1, work); @@ -99,12 +100,12 @@ and CalculatorClient.prototype.calculate = function(logid, w) {} -Unfortunately, the Javascript object isn't just called Calculator and there are a lot of other functions defined as well, but how those are used are out of the scope of this tutorial. +Unfortunately, the Javascript object isn't just called Calculator and there are a lot of other functions defined as well, but how those are used are out of the scope of this tutorial. ### Inspecting the Thrift.js file * The main goal of the library is to define the Transport and Protocol layers. -* The Transport layer can use AJAX or WebSockets. +* The Transport layer can use AJAX or WebSockets. * The Protocol layer handles the encoding/decoding to JSON or Binary format. * There are also the Thrift object types and call functions defined here as well. * The Thrift.js library can use jQuery.js if provided. diff --git a/tutorial/netstd.md b/tutorial/netstd.md index e729b0e..f90c3f6 100644 --- a/tutorial/netstd.md +++ b/tutorial/netstd.md @@ -1,8 +1,9 @@ --- title: ".NET Standard" -library_lang: "netstd" +librarylang: "netstd" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/nodejs.md b/tutorial/nodejs.md index 925a42c..a489cb1 100644 --- a/tutorial/nodejs.md +++ b/tutorial/nodejs.md @@ -1,8 +1,9 @@ --- title: "Node.js" -library_lang: "js:node" +librarylang: "js:node" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/ocaml.md b/tutorial/ocaml.md index 4e58818..4c46ef1 100644 --- a/tutorial/ocaml.md +++ b/tutorial/ocaml.md @@ -1,8 +1,9 @@ --- title: "OCaml" -library_lang: "ocaml" +librarylang: "ocaml" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/perl.md b/tutorial/perl.md index 0d0eeb6..7e92cb4 100644 --- a/tutorial/perl.md +++ b/tutorial/perl.md @@ -1,8 +1,9 @@ --- title: "Perl" -library_lang: "perl" +librarylang: "perl" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/php.md b/tutorial/php.md index 900e81d..f423dd2 100644 --- a/tutorial/php.md +++ b/tutorial/php.md @@ -1,8 +1,9 @@ --- title: "PHP" -library_lang: "php" +librarylang: "php" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/py.md b/tutorial/py.md index fae273d..fe527d1 100644 --- a/tutorial/py.md +++ b/tutorial/py.md @@ -1,8 +1,9 @@ --- title: "Python" -library_lang: "py" +librarylang: "py" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites diff --git a/tutorial/rb.md b/tutorial/rb.md index 080adb8..3406567 100644 --- a/tutorial/rb.md +++ b/tutorial/rb.md @@ -1,8 +1,9 @@ --- title: "Ruby" -library_lang: "rb" +librarylang: "rb" +layout: tutorial +tutorial: true --- -{% include 'tutorial_intro.md' %} ### Prerequisites
