Publish 2018-06-27 Example-driven development article
This commit is contained in:
@@ -1,5 +1,94 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom"><title>Opensource Game Studio</title><link href="http://opengamestudio.org/" rel="alternate"></link><link href="http://opengamestudio.org/feeds/all.atom.xml" rel="self"></link><id>http://opengamestudio.org/</id><updated>2018-04-20T00:00:00+03:00</updated><entry><title>OpenSceneGraph cross-platform examples</title><link href="http://opengamestudio.org/openscenegraph-examples.html" rel="alternate"></link><updated>2018-04-20T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-04-20:openscenegraph-examples.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-04-20-openscenegraph-examples.png" /></p>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom"><title>Opensource Game Studio</title><link href="http://opengamestudio.org/" rel="alternate"></link><link href="http://opengamestudio.org/feeds/all.atom.xml" rel="self"></link><id>http://opengamestudio.org/</id><updated>2018-06-27T00:00:00+03:00</updated><entry><title>Example-driven development</title><link href="http://opengamestudio.org/example-driven-development.html" rel="alternate"></link><updated>2018-06-27T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-06-27:example-driven-development.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-06-27-example-driven-development.png" /></p>
|
||||
<p>This article explains how the third OpenSceneGraph cross-platform example
|
||||
opened our eyes to example-driven development.</p>
|
||||
<p><strong>The third OpenSceneGraph cross-platform example</strong></p>
|
||||
<p>The third OpenSceneGraph cross-platform example explains how to implement
|
||||
<a href="https://github.com/OGStudio/openscenegraph-cross-platform-examples/tree/master/03.RemoteDebugging">remote debugging across platforms</a>. This example is less about
|
||||
OpenSceneGraph and more about different platforms.</p>
|
||||
<p>Remote anything nowadays assumes the use of HTTP(s) over TCP/IP. Thus, the
|
||||
first idea was to embed HTTP server into an application and let HTTP clients
|
||||
interact with the server. However, serving HTTP across all platforms is
|
||||
complicated:</p>
|
||||
<ul>
|
||||
<li>desktops have firewalls</li>
|
||||
<li>mobiles have restrictions on background processes</li>
|
||||
<li>web browsers are HTTP clients by design</li>
|
||||
</ul>
|
||||
<p>That's why we decided to create a mediator between debugged application and UI.
|
||||
<a href="https://github.com/OGStudio/debug-broker">Debug broker</a>, a small Node.js application, became that mediator.
|
||||
Debug broker uses no external dependencies, so it's easy to run virtually
|
||||
anywhere. Also, since debug broker is a server application, you can configure
|
||||
it once and use it for any number of applications.</p>
|
||||
<p>Both <a href="https://github.com/OGStudio/debug-ui">debug UI</a> and <a href="https://github.com/OGStudio/debug-broker">debug broker</a> use JavaScript
|
||||
because we wanted these tools to be accessible from anywhere with no prior
|
||||
installation. This decision limited us to web browser solution. Providing
|
||||
any sort of desktop application would incur additional installation and
|
||||
maintenance effort, which would only complicate the tools.</p>
|
||||
<p><strong>Example-driven development establishment</strong></p>
|
||||
<p>Once the third example was implemented, we realized how important and
|
||||
beneficial it is to develop new features outside the main project:</p>
|
||||
<ul>
|
||||
<li>the main project is freed from excessive commit noise</li>
|
||||
<li>a new feature is publicly shared for everyone to learn, criticize, and improve</li>
|
||||
</ul>
|
||||
<p>When we publicly share our knowledge:</p>
|
||||
<ul>
|
||||
<li>we must create documentation for everyone (including ourselves later) to understand what's going on</li>
|
||||
<li>we must not use hacks because that would break your trust in us</li>
|
||||
</ul>
|
||||
<p>From now on, all new features like input handling, Mahjong layout loading,
|
||||
resource caching, etc. are going to be first implemented as examples.
|
||||
We call this example-driven development.</p>
|
||||
<p>That's it for explaining how the third OpenSceneGraph cross-platform example
|
||||
opened our eyes to example-driven development.</p></summary></entry><entry><title>Разработка через создание примеров</title><link href="http://opengamestudio.org/example-driven-development-ru.html" rel="alternate"></link><updated>2018-06-27T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-06-27:example-driven-development-ru.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-06-27-example-driven-development.png" /></p>
|
||||
<p>Эта статья описывает то, как создание третьего кросс-платформенного примера
|
||||
OpenSceneGraph привело нас к разработке через создание примеров.</p>
|
||||
<p><strong>Третий кросс-платформенный пример OpenSceneGraph</strong></p>
|
||||
<p>Третий кросс-платформенный пример OpenSceneGraph содержит реализацию
|
||||
<a href="https://github.com/OGStudio/openscenegraph-cross-platform-examples/tree/master/03.RemoteDebugging">удалённой отладки, работающей на всех поддерживаемых платформах</a>.
|
||||
Этот пример относится не столько к OpenSceneGraph, сколько к поддержке
|
||||
различных платформ.</p>
|
||||
<p>Удалённое взаимодействие ныне предполагает использование HTTP(s) поверх
|
||||
TCP/IP. Таким образом, первая идея реализации подразумевала встраивание сервера
|
||||
HTTP в приложение, чтобы клиенты HTTP могли взаимодействовать с этим сервером.
|
||||
Однако, раздача HTTP на различных платформах имеет свои сложности:</p>
|
||||
<ul>
|
||||
<li>на десктопах есть межсетевые экраны (firewalls)</li>
|
||||
<li>на мобилках есть ограничения по работе фоновых процессов</li>
|
||||
<li>веб-браузеры являются клиентами HTTP по дизайну</li>
|
||||
</ul>
|
||||
<p>Эти ограничения подтолкнули нас к созданию посредника между отлаживаемым
|
||||
приложением и пользовательским интерфейсом отладки.
|
||||
<a href="https://github.com/OGStudio/debug-broker">Брокер отладки</a>, небольшое приложение Node.js, стало тем самым
|
||||
посредником. Брокер отладки не имеет внешних зависимостей, поэтому его легко
|
||||
использовать практически везде. Благодаря тому, что брокер отладки - это
|
||||
серверное приложение, его достаточно настроить лишь раз и использовать для
|
||||
любого количества приложений.</p>
|
||||
<p>И <a href="https://github.com/OGStudio/debug-ui">пользовательский интерфейс отладки</a>,
|
||||
и <a href="https://github.com/OGStudio/debug-broker">брокер отладки</a> используют JavaScript, т.к. мы хотели сделать
|
||||
эти инструменты максимально доступными без предварительной установки. Данное
|
||||
решение привело нас к реализации инструментов именно для веб-браузеров.
|
||||
Десктопное приложение потребовало бы дополнительных усилий на установку и
|
||||
поддержку, что лишь усложнило бы работу с инструментами.</p>
|
||||
<p><strong>Разработка через создание примеров</strong></p>
|
||||
<p>После создания третьего примера мы осознали важность и достоинства разработки
|
||||
новых функций вне основного проекта:</p>
|
||||
<ul>
|
||||
<li>освобождение основного проекта от шума изменений (commit noise)</li>
|
||||
<li>публичное освещение новой функции приглашает всех к её изучению, критике и улучшению</li>
|
||||
</ul>
|
||||
<p>Когда мы делимся нашими знаниями:</p>
|
||||
<ul>
|
||||
<li>мы обязаны создавать документацию, объясняющую происходящее (в том числе для нас самих позже)</li>
|
||||
<li>мы обязаны сторониться непродуманных решений, т.к. они повредят нашей репутации</li>
|
||||
</ul>
|
||||
<p>С этого момента все новые функции вроде обработки ввода, загрузки раскладок
|
||||
Маджонга, кэширования ресурсов и т.п. мы будем сначала реализовывать в виде
|
||||
примеров. Мы называем этот подход разработкой через создание примеров.</p>
|
||||
<p>На этом мы заканчиваем описание того, как создание третьего
|
||||
кросс-платформенного примера OpenSceneGraph привело нас к разработке через
|
||||
создание примеров.</p></summary></entry><entry><title>OpenSceneGraph cross-platform examples</title><link href="http://opengamestudio.org/openscenegraph-examples.html" rel="alternate"></link><updated>2018-04-20T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-04-20:openscenegraph-examples.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-04-20-openscenegraph-examples.png" /></p>
|
||||
<p>This article summarizes the work we did to produce the first two
|
||||
cross-platform OpenSceneGraph examples.</p>
|
||||
<p>By the time <a href="http://opengamestudio.org/mahjong-techdemo1-gameplay.html">the first technology demonstration of OGS Mahjong 2</a>
|
||||
|
||||
@@ -1,5 +1,47 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom"><title>Opensource Game Studio</title><link href="http://opengamestudio.org/" rel="alternate"></link><link href="http://opengamestudio.org/feeds/news.atom.xml" rel="self"></link><id>http://opengamestudio.org/</id><updated>2018-04-20T00:00:00+03:00</updated><entry><title>OpenSceneGraph cross-platform examples</title><link href="http://opengamestudio.org/openscenegraph-examples.html" rel="alternate"></link><updated>2018-04-20T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-04-20:openscenegraph-examples.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-04-20-openscenegraph-examples.png" /></p>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom"><title>Opensource Game Studio</title><link href="http://opengamestudio.org/" rel="alternate"></link><link href="http://opengamestudio.org/feeds/news.atom.xml" rel="self"></link><id>http://opengamestudio.org/</id><updated>2018-06-27T00:00:00+03:00</updated><entry><title>Example-driven development</title><link href="http://opengamestudio.org/example-driven-development.html" rel="alternate"></link><updated>2018-06-27T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-06-27:example-driven-development.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-06-27-example-driven-development.png" /></p>
|
||||
<p>This article explains how the third OpenSceneGraph cross-platform example
|
||||
opened our eyes to example-driven development.</p>
|
||||
<p><strong>The third OpenSceneGraph cross-platform example</strong></p>
|
||||
<p>The third OpenSceneGraph cross-platform example explains how to implement
|
||||
<a href="https://github.com/OGStudio/openscenegraph-cross-platform-examples/tree/master/03.RemoteDebugging">remote debugging across platforms</a>. This example is less about
|
||||
OpenSceneGraph and more about different platforms.</p>
|
||||
<p>Remote anything nowadays assumes the use of HTTP(s) over TCP/IP. Thus, the
|
||||
first idea was to embed HTTP server into an application and let HTTP clients
|
||||
interact with the server. However, serving HTTP across all platforms is
|
||||
complicated:</p>
|
||||
<ul>
|
||||
<li>desktops have firewalls</li>
|
||||
<li>mobiles have restrictions on background processes</li>
|
||||
<li>web browsers are HTTP clients by design</li>
|
||||
</ul>
|
||||
<p>That's why we decided to create a mediator between debugged application and UI.
|
||||
<a href="https://github.com/OGStudio/debug-broker">Debug broker</a>, a small Node.js application, became that mediator.
|
||||
Debug broker uses no external dependencies, so it's easy to run virtually
|
||||
anywhere. Also, since debug broker is a server application, you can configure
|
||||
it once and use it for any number of applications.</p>
|
||||
<p>Both <a href="https://github.com/OGStudio/debug-ui">debug UI</a> and <a href="https://github.com/OGStudio/debug-broker">debug broker</a> use JavaScript
|
||||
because we wanted these tools to be accessible from anywhere with no prior
|
||||
installation. This decision limited us to web browser solution. Providing
|
||||
any sort of desktop application would incur additional installation and
|
||||
maintenance effort, which would only complicate the tools.</p>
|
||||
<p><strong>Example-driven development establishment</strong></p>
|
||||
<p>Once the third example was implemented, we realized how important and
|
||||
beneficial it is to develop new features outside the main project:</p>
|
||||
<ul>
|
||||
<li>the main project is freed from excessive commit noise</li>
|
||||
<li>a new feature is publicly shared for everyone to learn, criticize, and improve</li>
|
||||
</ul>
|
||||
<p>When we publicly share our knowledge:</p>
|
||||
<ul>
|
||||
<li>we must create documentation for everyone (including ourselves later) to understand what's going on</li>
|
||||
<li>we must not use hacks because that would break your trust in us</li>
|
||||
</ul>
|
||||
<p>From now on, all new features like input handling, Mahjong layout loading,
|
||||
resource caching, etc. are going to be first implemented as examples.
|
||||
We call this example-driven development.</p>
|
||||
<p>That's it for explaining how the third OpenSceneGraph cross-platform example
|
||||
opened our eyes to example-driven development.</p></summary></entry><entry><title>OpenSceneGraph cross-platform examples</title><link href="http://opengamestudio.org/openscenegraph-examples.html" rel="alternate"></link><updated>2018-04-20T00:00:00+03:00</updated><author><name>Opensource Game Studio</name></author><id>tag:opengamestudio.org,2018-04-20:openscenegraph-examples.html</id><summary type="html"><p><img alt="Screenshot" src="http://opengamestudio.org/2018-04-20-openscenegraph-examples.png" /></p>
|
||||
<p>This article summarizes the work we did to produce the first two
|
||||
cross-platform OpenSceneGraph examples.</p>
|
||||
<p>By the time <a href="http://opengamestudio.org/mahjong-techdemo1-gameplay.html">the first technology demonstration of OGS Mahjong 2</a>
|
||||
|
||||
Reference in New Issue
Block a user