Skip to content

Commit 00db1e5

Browse files
committed
Update docs
1 parent da02adc commit 00db1e5

File tree

8 files changed

+165
-133
lines changed

8 files changed

+165
-133
lines changed

doc/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ layout: home
33
currentMenu: home
44
---
55

6-
## Why should you care?
6+
## What is this all about?
7+
78
__InEngine.NET__ is a set of .NET packages that allow for the creation of a code-centric data integration and asynchronous job scheduling server.
89
Integration jobs are created in code, making them flexible and testable.
910

doc/change-log.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,21 @@ currentMenu: change-log
55

66
# Change Log
77

8+
## 2.0.2
9+
10+
__Fixes__
11+
* Configure MailClient's internal SMTP client in send method.
12+
13+
## 2.0.1
14+
15+
__Fixes__
16+
* Downgrade ServiceStack client to BSD version.
17+
18+
## 2.0.0
19+
20+
__Features__
21+
* Add support for Integration Points.
22+
823
## 2.0.0-rc2
924

1025
__Chores__

doc/configuration.md

Lines changed: 81 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ currentMenu: configuration
88
__InEngine.NET__ is configured with a JSON file called IntegrationEngine.json.
99
The configuration file has several sections, outlined below.
1010

11-
### WebApi
11+
## WebApi
1212

1313
The _WebApi_ section contains settings for the InEngine.NET's WebApi.
1414
Namely, the hostname and port of the web API.
@@ -28,100 +28,100 @@ Note that it is not recommended to use "*" wildcard, but a list of specific doma
2828
}
2929
```
3030

31-
### MessageQueue
31+
## NLogAdapter
3232

33-
The _MessageQueue_ section contains settings for connecting to a RabbitMQ server.
34-
If these settings are not correct, then a connection exception will be thrown when a job is triggered.
35-
36-
A queue called "myqueue" will not exist on a freshly installed RabbitMQ server.
37-
It will need to be created.
33+
The _NLogAdapter_ section contains settings for configuring the [NLog Common.Logging adapter](http://netcommon.sourceforge.net/docs/2.1.0/reference/html/ch01.html#logging-adapters-nlog).
3834

3935
```js
4036
{
4137
// ...
42-
"MessageQueue": {
43-
"QueueName": "myqueue",
44-
"ExchangeName": "amq.direct",
45-
"UserName": "inengine",
46-
"Password": "secret",
47-
"HostName": "localhost",
48-
"VirtualHost": "/"
49-
},
50-
// ...
38+
"NLogAdapter": {
39+
"ConfigType": "File",
40+
"ConfigFile": "IntegrationEngine.nlog.xml"
41+
}
42+
// ..
5143
}
5244
```
5345

54-
### Elasticsearch
46+
## Integration Points
5547

56-
The _Elasticsearch_ section contains settings for connecting to a Elasticsearch server.
57-
If these settings are not correct, then a connection exception will be thrown when a job is scheduled.
48+
Any number of integration points [Integration Points](integration-points.html) can be configured.
49+
All integration points should have a unique name defined in its _IntegrationPointName_ property.
5850

59-
```js
60-
{
61-
// ...
62-
"Elasticsearch": {
63-
"Protocol": "http",
64-
"HostName": "localhost",
65-
"Port": 9200,
66-
"DefaultIndex": "integration-engine"
67-
},
68-
// ...
69-
}
70-
```
51+
### RabbitMQ
7152

72-
### Mail
53+
The _RabbitMQ_ section contains settings for connecting to a RabbitMQ server.
54+
If these settings are not correct, then a connection exception will be thrown when a job is triggered.
7355

74-
The _Mail_ section contains settings for connecting to an SMTP server.
75-
If these settings are not correct, then a connection exception will be thrown when sending an email.
56+
A queue called "myqueue" will not exist on a freshly installed RabbitMQ server.
57+
It will need to be created.
7658

7759
```js
7860
{
7961
// ...
80-
"Mail": {
81-
"HostName": "localhost",
82-
"Port": 25
83-
},
62+
"IntegrationPoints": {
63+
"RabbitMQ": [
64+
{
65+
"IntegrationPointName": "DefaultRabbitMQ",
66+
"QueueName": "myqueue",
67+
"ExchangeName": "amq.direct",
68+
"UserName": "inengine",
69+
"Password": "secret",
70+
"HostName": "localhost",
71+
"VirtualHost": "/"
72+
}
73+
],
74+
}
8475
// ...
8576
}
8677
```
8778

88-
### Database
79+
### Elasticsearch
8980

90-
The _Database_ section contains settings for connecting to a either a SQL Server or MySQL server via [Entity Framework](http://msdn.microsoft.com/en-us/data/ef.aspx).
91-
If these settings are not correct, then a connection exception will be thrown when a SQL job runs.
81+
The _Elasticsearch_ section contains settings for connecting to a Elasticsearch server.
82+
If these settings are not correct, then a connection exception will be thrown when a job is scheduled.
9283

9384
```js
9485
{
9586
// ...
96-
"Database": {
97-
"ServerType": "SQLServer",
98-
"HostName": "localhost",
99-
"Port": 1433,
100-
"DatabaseName": "IntegrationEngine",
101-
"UserName": "inengine",
102-
"Password": "secret"
87+
"IntegrationPoints": {
88+
"Elasticsearch": [
89+
{
90+
"IntegrationPointName": "DefaultElasticsearch",
91+
"Protocol": "http",
92+
"HostName": "localhost",
93+
"Port": 9200,
94+
"DefaultIndex": "integration-engine"
95+
}
96+
]
10397
}
104-
// ..
98+
// ...
10599
}
106100
```
107101

108-
### NLogAdapter
102+
### Mail
109103

110-
The _NLogAdapter_ section contains settings for configuring the [NLog Common.Logging adapter](http://netcommon.sourceforge.net/docs/2.1.0/reference/html/ch01.html#logging-adapters-nlog).
104+
The _Mail_ section contains settings for connecting to an SMTP server.
105+
If these settings are not correct, then a connection exception will be thrown when sending an email.
111106

112107
```js
113108
{
114109
// ...
115-
"NLogAdapter": {
116-
"ConfigType": "File",
117-
"ConfigFile": "IntegrationEngine.nlog.xml"
110+
"IntegrationPoints": {
111+
"Mail": [
112+
{
113+
"IntegrationPointName": "DefaultMail",
114+
"HostName": "localhost",
115+
"Port": 25
116+
}
117+
]
118118
}
119-
// ..
119+
// ...
120120
}
121121
```
122122

123123
## Sample Configuration
124-
This is a sample configuration.
124+
This is a sample minimum configuration.
125125

126126
```js
127127
{
@@ -130,35 +130,31 @@ This is a sample configuration.
130130
"Port": 9001,
131131
"Origins": ["*"]
132132
},
133-
"MessageQueue": {
134-
"QueueName": "myqueue",
135-
"ExchangeName": "amq.direct",
136-
"UserName": "inengine",
137-
"Password": "secret",
138-
"HostName": "localhost",
139-
"VirtualHost": "/"
140-
},
141-
"Elasticsearch": {
142-
"Protocol": "http",
143-
"HostName": "localhost",
144-
"Port": 9200,
145-
"DefaultIndex": "integration-engine"
146-
},
147-
"Mail": {
148-
"HostName": "localhost",
149-
"Port": 25
150-
},
151-
"Database": {
152-
"ServerType": "SQLServer",
153-
"HostName": "localhost",
154-
"Port": 1433,
155-
"DatabaseName": "IntegrationEngine",
156-
"UserName": "inengine",
157-
"Password": "secret"
133+
"NLogAdapter": {
134+
"ConfigType": "File",
135+
"ConfigFile": "IntegrationEngine.nlog.xml"
158136
},
159-
"NLogAdapter": {
160-
"ConfigType": "File",
161-
"ConfigFile": "IntegrationEngine.nlog.xml"
162-
}
137+
"IntegrationPoints": {
138+
"RabbitMQ": [
139+
{
140+
"IntegrationPointName": "DefaultRabbitMQ",
141+
"QueueName": "myqueue",
142+
"ExchangeName": "amq.direct",
143+
"UserName": "inengine",
144+
"Password": "secret",
145+
"HostName": "localhost",
146+
"VirtualHost": "/"
147+
}
148+
],
149+
"Elasticsearch": [
150+
{
151+
"IntegrationPointName": "DefaultElasticsearch",
152+
"Protocol": "http",
153+
"HostName": "localhost",
154+
"Port": 9200,
155+
"DefaultIndex": "integration-engine"
156+
}
157+
]
158+
}
163159
}
164160
```

doc/couscous.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,12 @@ menu:
3131
relativeUrl: configuration.html
3232
integration-jobs:
3333
text: Integration Jobs
34-
iconClass: 'fa fa-fw fa-exchange'
34+
iconClass: 'fa fa-fw fa-tasks'
3535
relativeUrl: integration-jobs.html
36+
integration-points:
37+
text: Integration Points
38+
iconClass: 'fa fa-fw fa-exchange'
39+
relativeUrl: integration-points.html
3640
web-api:
3741
text: Web API
3842
iconClass: 'fa fa-fw fa-cloud'

doc/documentation.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ currentMenu: documentation
1111

1212
<dt><a href="integration-jobs.html">Integration Jobs</a></dt>
1313
<dd>Lists the built-in integration jobs in the <a href="https://www.nuget.org/packages/IntegrationEngine.Core">InEngine.NET Core</a> package, and explains their usage.</dd>
14-
14+
15+
<dt><a href="integration-points.html">Integration Points</a></dt>
16+
<dd>Describes how to create integration points, and explains their usage.</dd>
17+
1518
<dt><a href="web-api/cron-trigger.html">Web API</a></dt>
1619
<dd>Lists the available HTTP endpoints in the Web API, and explains their usage.</dd>
1720

doc/integration-jobs.md

Lines changed: 7 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,15 @@ currentMenu: integration-jobs
55

66
# Integration Jobs
77

8-
Integration jobs can do anything, not just retrieve, transform, and persist data.
9-
They can also be made to send an email, run a console command, call some third party library, or anything else that can
8+
Integration jobs contain a _Run_ method, thanks to _IIntegrationJob_, that run when the job is executed by the __InEngine.NET__ scheduler.
9+
10+
Integration jobs utilize [Integration Points](integration-points.html) to query and persist data.
11+
They can also send an email, run a console command, call some third party library, or anything else that can
1012
be done in a .NET application.
1113

1214
## Built-in Job Types
1315

14-
__InEngine.NET__ comes with a few built-in integration jobs defined in _IntegrationEngine.Core.Jobs_.
15-
They are __Integration Job__, __Mail Job__, __Elasticsearch Job__, __Log Job__, and __SQL Job__.
16+
__InEngine.NET__ comes with a few built-in integration jobs, defined in _IntegrationEngine.Core.Jobs_, described below.
1617

1718
### Integration Job
1819

@@ -21,47 +22,9 @@ They are __Integration Job__, __Mail Job__, __Elasticsearch Job__, __Log Job__,
2122
* The interface has one argumentless method called _Run_ which is executed when the job is triggered.
2223
* All other jobs must implement _IIntegrationJob_ directly or indirectly.
2324

24-
### Elasticsearch Job
25-
26-
* Implement the _IElasticsearchJob_ interface to create an Elasticsearch Job.
27-
* The _ElasticClient_ property of the _IElasticsearchJob_ is automatically instantiated and configured with the Elasticsearch settings in [IntegrationEngine.json](configuration.html).
28-
* The _ElasticClient_ is an instance of _Nest.ElasticClient_.
29-
* See the NEST [quick start](http://nest.azurewebsites.net/nest/quick-start.html) for information on how to use it.
30-
31-
### Log Job
32-
33-
* Implement the _ILogJob_ interface to create a log job.
34-
* The _Log_ property of the _ILogJob_ is automatically instantiated and configured with the
35-
[log4net](http://logging.apache.org/log4net/) settings in the host applications App.config file.
36-
* The _Log_ instance can be configured to log to a variety of [logging targets](logging.apache.org/log4net/release/features.html#appenders).
37-
* Messages and exception can be logged according to their [severity](http://logging.apache.org/log4net/release/manual/introduction.html#hierarchy).
38-
39-
### Mail Job
40-
41-
* Implement the _IMailJob_ interface to create a mail job.
42-
* The _MailClient_ property of the _IMailJob_ is automatically instantiated and configured with the mail settings in [IntegrationEngine.json](configuration.html).
43-
* The _MailClient_'s _Send_ method can be used to send a _System.Net.Mail.MailMessage_.
44-
4525
### Parameterized Job
4626

4727
* Implement the _IParameterizedJob_ interface to create a parameterized job.
48-
* The _Parameters_ property of the _IParameterizedJob_ is automatically instantiated and populated with the Parameters dictionary stored in the trigger that is used to schedule the job.
28+
* There is no need to directly implement _IIntegrationJob_ when implementing _IParameterizedJob_ as it already implements _IIntegrationJob_.
29+
* The _Parameters_ property of _IParameterizedJo db_ is automatically instantiated and populated with the _Parameters_ IDictionary stored in the trigger that is used to schedule the job.
4930
* _Parameters_ can be used to configure the job in some way.
50-
51-
### SQL Job
52-
53-
* Implement the _ISqlJob_ interface to create a sql job.
54-
* The _DbContext_ property of the _ISqlJob_ is automatically instantiated and configured with the Database settings in [IntegrationEngine.json](configuration.html).
55-
* The _Query_ property of the _ISqlJob_ must be populated with a valid SQL command before the _RunQuery<T>_ method is called.
56-
* The generic parameter in the _RunQuery<T>_ method is a class that represents a record returned from the database.
57-
* The _RunQuery<T>_ method returns a _IList<T>_ collection of records from the database.
58-
59-
#### Concrete SQL Job Class
60-
61-
There is also concrete class defined in _IntegrationEngine.Core.Jobs_ called _SqlJob_.
62-
63-
* It implements _ISqlJob_, _IMailJob_, amd _ILogJob_.
64-
* A class derived from _SqlJob_ will run whatever query is assigned to its _Query_ property by default.
65-
* However, both the _RunQuery<T>_ and _Run_ methods are marked as virtual and thus can be overridden.
66-
* A common practice is to override the _Run_ method, call _RunQuery<T>_, examine the results, then send a notification email.
67-
* The _Log_ property can be used to log when the query fails.

0 commit comments

Comments
 (0)