Changi NNTP Server 1.0

[ Bottom of Page | Previous Page | Next Page | Table of Contents ]

newsfeeds

This part may appear difficult to understand for the novice user. If you simply want to send your local posts to the provider, then there is no need to read any further. You may select the next page or return to the table of contents.

A file named newsfeeds specifies where to send incoming articles, local posts as well as articles transfered from other servers. Changi expects this file to live in CHANGIWORKDIR and parses it during the startup phase. If the file doesn't exist, then feeding other sites is performed in a default way, which may be sufficient for most implementations. For each locally posted article Changi will create a set of spool files in CHANGISPOOLDIR to be sent to the site specified by NNTPNEIGHBOR.

The file is interpreted line by line. Each line represents a feed entry. Continuation lines are possible by adding a backslash at the end of the previous line. Blank lines and lines starting with # are ignored.

Each line is divided into fields separated by colons and optional sub-fields separated by slashes. Some fields may contain several items separated by commas.

The general format of each entry is

site[/exclist]:patterns[/distribs]:flags:param

site
The full domain name of the site to send articles to. If this name appears in the path line of any article's header, that article will not be sent to this site. This field is not case sensitive, excepting an entry named ME, which is treated specially (see below).

exclist
A comma separated list of additional site names. If any of these names appear in the path line of an article's header, that article will not be sent to this site.

patterns
This is a comma separated list of wildcat expressions and defines the site's subscriptions. The site will receive all newsgroups matching this list. Note that any pattern specified in the ME entry is prepended to this list. A typical setup might set the pattern in ME to match all default groups and use the pattern field of all other sites to exclude some defaults and include special groups.

distribs
With this optional list you may further specify which articles the site should receive, based on the distribution line in the article header. Use an exclamation mark to exclude distributions.

For further explanations refer to the chapter titled Limiting Distribution of Posts.

flags
This is a comma separated list of flags, used to switch on or off miscellaneous options. Note that some flags require values, which should immediately follow the flag character without any separating whitespace.

<size
Only articles whose size is below the given value will be sent.

Amodifiers
With Ad articles will be sent only if they contain a distribution line in the header. Ap will instruct Changi not to check the pathline for the site's name. Note that the exclist is still checked.

F
If this flag is given, then the articles are stored in a file rather than a transmission command. The fourth field may contain a pathname of a file. If it is left empty, then the articles will be stored in an uucp spool.

f
This flag has the same meaning as the F flag and is included for compatibility.

Gcount
Only articles crossposted to not more than count newsgroups are sent to the site.

Hcount
This flag specifies a maximum hop count. Articles are sent only if there are no more than count sites in the path header.

I
Changi will feed articles by message-id. This flag implies Ti

L
Only local posts will be sent to this site.

m
This site will only receive articles to moderated groups. This flag doesn't differ from specifying Nm but is included for compatibility.

Nmodifiers
Changi will only sent articles to moderated (Nm) or unmoderated (Nu) newsgroups.

M
Changi will feed articles by pathname and message-id. This flag implies Ti

Ssize
If the amount of data queued for this site reaches size bytes, then this data will be spooled. Default size is 131,072 bytes.

Ttype
This flag specifies the type of the feed.

There are two general feed types, which are mutually exclusive.

Tf
This site will be fed by a file. The fourth field is interpreted as a pathname of a file, rather than a transmission command.

Tp
The site will be fed by a program. This is the default.

Both general types may be combined with any the following modifiers.

Tb
Single articles are collected in batch files, before storing them in a file or feeding them to a program.

Tc
Same as Tb, but batchfiles will be compressed. Note, that GZIP.EXE must be found in a PATH directory.

Ti
Changi will feed, not the contents of an article itself, but certain information like its pathname (default) or the article's message-ID. Note, that feeding the pathname will only transmit articles, which had also been stored locally.

In addition to the two general types there is a special file feed for UUPC support.

TU
Articles will be fed by UUPC compatible spoolfiles. This option implies Tf.
u
This site will only receive articles to unmoderated groups. This flag doesn't differ from specifying Nu and has been included for compatibility.

Wmodifiers
If flag Ti has been specified, then Changi will feed pathnames. This default may be overwritten by using any combination of the following modifiers.
Wb
Size of the article in bytes.

Wf
Full pathname of the article.

Wg
Name of the first newsgroup.

WG
Name of all newsgroups separated by commas.

Wm
Message-ID of the article.

Wn
Relative pathname of the article in CHANGINEWSDIR.

Ws
Name of the site which transmitted the article to Changi.

Wt
The article's arrival time, given in number of seconds since 01/01/1979.

WD
Contents of the distribution header, or a question mark if it's not present.

WH
All headers of the article, each transmitted on a separate line and terminated by a blank line.

WN
Contents of the newsgroup header.

param
The meaning of this field depends on the feed's type.

If the site is fed by a file, then this field specifies the name of the file, either with an absolute path or relative to CHANGIWORKDIR. When a site is flushed, Changi will write all queued articles to this file. If this field is left blank, then Changi will create UUCP spool files when flushing the site.

If the site is fed by a program, then this field is interpreted as the name of a program to be started when the site is flushed. If this is a batch feed (flag Tb), then it must contain a single %s, which will be converted to the path name of the batch file. If the site is flushed, then Changi will run the program concurrently. After the program has finished processing the batchfile, it must remove it. Changi will not flush a site unless the previous batch has been removed.

If the site is fed by a program but is not a batch feed, then Changi will call this program for each article and write the contents of the article to the program's standard input.

Site named ME

If the site is named ME, then the entry is handled in a special way. This entry should be the first and only one. If not given, it defaults to

ME:*,!control,!control.*,!junk,!local,!local.*/!local::
excl
If this list is given in the ME entry, then Changi will reject articles containing any of the specified names in the path header.

pattern
If a pattern list is specified in the ME entry, then this list is prepended to the pattern lists of all other entries. Usually this item will contain *,!control,!control.*,!junk,!local,!local.*, so that other sites will receive anything except control and junk groups unless they are explicitely specified.

dist
You may use the distribution list in the ME entry to reject specific distributions. For example, !local will reject local distributions from misconfigured sites.

Sample newsfeeds

If Changi can't find a file named newsfeeds in CHANGIWORKDIR, it will use the following default:
ME:*,!control,!control.*,!junk,!local,!local.*/!local::
<remote>::L:
where <remote> is the name of the site found in the environment, either NNTPNEIGHBOR or NNTPSERVER. This will store all locally posted articles in uucp spool files, where Chanx will find them for transmission to the remote host.

If you're exchanging news using UUPC/extended, then you should create the following newsfeeds file:

ME:*,!control,!control.*,!junk,!local,!local.*/!local::
<remote>::L,TU:

If you're connected to a push feed, then you can use rnews to transmit your local posts to the remote server:

ME:*,!control,!control.*,!junk,!local,!local.*/!local::
<remote>::L,Tp:rnews -H<remote>
Changi will call Rnews on each local post it receives and write the article immediately to the standard input of Rnews. In turn, Rnews will transmit the article to <remote> using the IHAVE protocol.
[ Top of Page | Previous Page | Next Page | Table of Contents ]


URL: changi/manual/newsfeed.html
Created: 3 August 1996
Revised: 21 December 1996
Author: harald@os2point.ping.de