Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update documentation for 0.2.0 and 0.2.1 releases. Added blog post fo…
…r 0.2.1. (#13)
- Loading branch information
Showing
15 changed files
with
1,882 additions
and
479 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<!DOCTYPE HTML> | ||
|
||
<meta charset="UTF-8"> | ||
<meta http-equiv="refresh" content="5; url=%{url}"> | ||
|
||
%{google_analytics_universal} | ||
|
||
<script> | ||
window.location.href = "%{url}" | ||
</script> | ||
|
||
<title>Page Redirection</title> | ||
Looks like you used an old link. We will teleport you to the <a href='%{url}'>right place</a> in a second. } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# A list of redirects picked up by the RedirectCreator extension | ||
# For each key in this file a html page is created with a appropriate meta redirect directive to | ||
# the new URL | ||
|
||
# General | ||
docs/tutorial: /docs/0.2/tutorial | ||
#docs/connector: /docs/0.2/connector | ||
issues: https://issues.jboss.org/projects/DBZ/issues | ||
issues.html: https://issues.jboss.org/projects/DBZ/issues |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
require 'awestruct/handlers/base_handler' | ||
|
||
module Awestruct | ||
module Extensions | ||
# Awestruct extension creating html pages with redirect directives. | ||
# Configuration via _config/redirects.yml | ||
class RedirectCreator | ||
Default_Redirect_Config = "redirects" | ||
|
||
def initialize(*args) | ||
@redirect_configs = Array.new | ||
@redirect_configs.push(*args) | ||
if @redirect_configs.index(Default_Redirect_Config) == nil | ||
@redirect_configs.push(Default_Redirect_Config) | ||
end | ||
end | ||
|
||
def execute(site) | ||
@redirect_configs.each { |config| | ||
if !site[config].nil? | ||
site[config].each do |requested_url, target_url| | ||
redirect_page = Page.new(site, Handlers::RedirectCreationHandler.new( site, requested_url, target_url )) | ||
# make sure indexifier is ignoring redirect pages | ||
redirect_page.inhibit_indexifier = true | ||
site.pages << redirect_page | ||
end | ||
end | ||
} | ||
end | ||
end | ||
end | ||
|
||
module Handlers | ||
class RedirectCreationHandler < BaseHandler | ||
include Awestruct::Extensions::GoogleAnalytics | ||
|
||
Default_Redirect_Template = "redirects.template" | ||
def initialize(site, requested_url, target_url) | ||
super( site ) | ||
@requested_url = requested_url | ||
@target_url = target_url | ||
@creation_time = Time.new | ||
@template = load_template | ||
|
||
end | ||
|
||
def simple_name | ||
File.basename( @requested_url, ".*" ) | ||
end | ||
|
||
def output_filename | ||
simple_name + output_extension | ||
end | ||
|
||
def output_extension | ||
'.html' | ||
end | ||
|
||
def output_path | ||
if( File.extname( @requested_url ).empty?) | ||
File.join( File.dirname(@requested_url), simple_name, "index.html" ) | ||
else | ||
File.join( File.dirname(@requested_url), output_filename ) | ||
end | ||
end | ||
|
||
def content_syntax | ||
:text | ||
end | ||
|
||
def input_mtime(page) | ||
@creation_time | ||
end | ||
|
||
def rendered_content(context, with_layouts=true) | ||
@template | ||
end | ||
|
||
private | ||
def load_template | ||
template_file = File.join(File.dirname(__FILE__), "..", "_config", Default_Redirect_Template) | ||
if !File.exist?(template_file) | ||
abort("RedirectCreator is configured in pipeline, but redirect template (#{template_file}) does not exist") | ||
end | ||
file = File.open(template_file, "rb") | ||
content = file.read | ||
file.close | ||
content % {url: @target_url, google_analytics_universal: google_analytics_universal} | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
= Debezium 0.2.1 Released | ||
rhauch | ||
:awestruct-tags: [ releases, mysql, docker ] | ||
:awestruct-layout: blog-post | ||
|
||
I'm happy to announce that **Debezium 0.2.1 is now available**. The link:/docs/connectors/mysql[MySQL connector] has been significantly improved and is now able to monitor and produce change events for link:/docs/connectors/mysql#ha-mysql-clusters#enabling-gtids[HA MySQL clusters] using link:/docs/connectors/mysql[GTIDs], perform a link:/docs/connectors/mysql#snapshots[consistent snapshot] when starting up the first time, and has a completely redesigned link:/docs/connectors/mysql#events[event message structure] that provides a ton more information with every event. Our link:/docs/releases[change log] has all the details about bugs, enhancements, new features, and backward compatibility notices. We've also updated our link:/docs/tutorial[tutorial]. | ||
|
||
[NOTE] | ||
==== | ||
What happened to 0.2.0? Well, we released it to Maven Central before we'd noticed a https://issues.jboss.org/browse/DBZ-71[few] https://issues.jboss.org/browse/DBZ-72[problems] that we thought it best to fix right away. Thus 0.2.1 was born. | ||
==== | ||
|
||
== Installing the MySQL connector | ||
|
||
If you've already installed https://zookeeper.apache.org[Zookeeper], http://kafka.apache.org/[Kafka], and http://kafka.apache.org/documentation.html#connect[Kafka Connect], then using Debezium's MySQL connector is easy. Simply download the https://repo1.maven.org/maven2/io/debezium/debezium-connector-mysql/0.2.1/debezium-connector-mysql-0.2.1-plugin.tar.gz[connector's plugin archive], extract the JARs into your Kafka Connect environment, and add the directory with the JARs to http://docs.confluent.io/3.0.0/connect/userguide.html#installing-connector-plugins[Kafka Connect's classpath]. Restart your Kafka Connect process to pick up the new JARs. | ||
|
||
If immutable containers are your thing, then check out https://hub.docker.com/r/debezium/[Debezium's Docker images] for Zookeeper, Kafka, and Kafka Connect with the MySQL connector already pre-installed and ready to go. Our link:/docs/tutorial[tutorial] even walks you through using these images, and this is a great way to learn what Debezium is all about. You can even link:/blog/2016/05/31/Debezium-on-Kubernetes[run Debezium on Kubernetes and OpenShift]. | ||
|
||
== Using the MySQL connector | ||
|
||
To use the connector to produce change events for a particular MySQL server or cluster, simply create a link:/docs/connectors/mysql/#configuration[configuration file for the MySQL Connector] and use the link:http://docs.confluent.io/3.0.0/connect/userguide.html#rest-interface[Kafka Connect REST API] to add that connector to your Kafka Connect cluster. When the connector starts, it will grab a consistent snapshot of the databases in your MySQL server and start reading the MySQL binlog, producing events for every inserted, updated, and deleted row. The connector can optionally produce events with the DDL statements that were applied, and you can even choose to produce events for a subset of the databases and tables. Optionally ignore, mask, or truncate columns that are sensitive, too large, or not needed. See the link:/docs/connectors/mysql/[MySQL connector's documentation] for all the details. | ||
|
||
== Using the libraries | ||
|
||
Although Debezium is really intended to be used as turnkey services, all of Debezium's JARs and other artifacts are available in http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22io.debezium%22[Maven Central]. You might want to use our link:/blog/2016/04/15/parsing-ddl/[MySQL DDL parser] from our MySQL connector library to parse those DDL statments in your consumers. | ||
|
||
We do provide a small library so applications can link:/docs/embedded[embed any Kafka Connect connector] and consume data change events read directly from the source system. This provides a much lighter weight system (since Zookeeper, Kafka, and Kafka Connect services are not needed), but as a consequence is not as fault tolerant or reliable since the application must manage and maintain all state normally kept inside Kafka's distributed and replicated logs. It's perfect for use in tests, and with careful consideration it may be useful in some applications. | ||
|
||
== About Debezium | ||
|
||
Debezium is an open source distributed platform that turns your existing databases into event streams, so applications can see and respond almost instantly to each committed row-level change in the databases. Debezium is built on top of http://kafka.apache.org/[Kafka] and provides http://kafka.apache.org/documentation.html#connect[Kafka Connect] compatible connectors that monitor specific database management systems. Debezium records the history of data changes in Kafka logs, so your application can be stopped and restarted at any time and can easily consume all of the events it missed while it was not running, ensuring that all events are processed correctly and completely. Debezium is link:/license[open source] under the http://www.apache.org/licenses/LICENSE-2.0.html[Apache License, Version 2.0]. | ||
|
||
== Get involved | ||
|
||
We hope you find Debezium interesting and useful, and want to give it a try. Follow us on Twitter https://twitter.com/debezium[@debezium], https://gitter.im/debezium/user[chat with us on Gitter], or join our https://groups.google.com/forum/#!forum/debezium[mailing list] to talk with the community. All of the code is open source https://github.com/debezium/[on GitHub], so build the code locally and help us improve the MySQL connector and add more connectors. If you find problems or have ideas how we can improve Debezium, please let us know or https://issues.jboss.org/projects/DBZ/issues/[log an issue]. And stay tuned, because we're hoping to add a MongoDB connector in our next release. | ||
|
||
Thanks to Emmanuel, Chris, Christian, Konstantin, David, Akshath, James, Ewen, Cheng, and Paul for their help with the release, discussions, design assistance, contributions, and questions! |
Oops, something went wrong.