-
Notifications
You must be signed in to change notification settings - Fork 67
/
Copy pathlog4perl.schema
206 lines (161 loc) · 5.83 KB
/
log4perl.schema
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
#note, this is all experimental, work in progress
#not meant to be used for ANYTHING yet --kg 5/2004
#Usage:
# openldap:
# put "include /path/to/this/file" in your slapd.conf
# fedora-ds:
# run through migrate.pl
# rename to 99log4perl.ldif and copy to slapd-xxx/config/schema/
#
objectidentifier priventerprise 1.3.6.1.4.1
objectidentifier log4perl priventerprise:20422.1
objectidentifier myattrs log4perl:0
objectidentifier myobjs log4perl:1
objectidentifier syntaxes 1.3.6.1.4.1.1466.115.121.1
objectidentifier OIDsyntax syntaxes:38
objectidentifier ldapDN syntaxes:12
objectidentifier ia5 syntaxes:26
objectidentifier boolean syntaxes:7
#http://www.zytrax.com/tech/ia5.html
#IA5 or more properly now International Reference Alphabet No. 5 (IRA5) and
#previously International Alphabet No. 5 (ISO 646) is defined in
#ITU-T T.50 and is a 7-bit character code (but encoded as 8 bits).
#ASCII is the US implementation of IA5 - there are multiple
#other national versions.
#
#IA5 is almost the same as ASCII. There are only two printable differences
#- currency (hex 24 - decimal 36) and Equivalence (tilde) (hex 7E - decimal 126).
#
#Could also use
#DirectoryString (OID=1.3.6.1.4.1.1466.115.121.1.15)
#UTF-8 encoding of ISO-10646-1 (Latin-1) - a variable byte encoding system that
#includes IA5/ASCII as a subset. Allows matchingRules of caseIgnoreMatch
#and caseIgnoreSubstringsMatch.
attributetype ( myattrs:1 NAME ('log4perlClass' 'log4jClass')
DESC 'classname'
EQUALITY caseExactIA5Match
SYNTAX syntaxes:26 SINGLE-VALUE )
attributetype ( myattrs:11 NAME ('log4perlLayoutClass' 'log4jLayoutClass')
DESC 'classname'
EQUALITY caseExactIA5Match
SYNTAX ia5 SINGLE-VALUE )
#attributetype ( myattrs:3 NAME ('log4perlLayout' 'log4jLayout')
# DESC 'dn to layout'
# EQUALITY distinguishedNameMatch
# SYNTAX ldapDN SINGLE-VALUE)
attributetype ( myattrs:4 NAME ('log4perlConversionPattern' 'log4jConversionPattern')
DESC 'e.g. %t %p %m%n'
EQUALITY caseExactIA5Match
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:5 NAME 'log4perlfilename'
DESC 'filename for FileAppender'
EQUALITY caseExactIA5Match
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:6 NAME 'log4perlmode'
DESC 'for FileAppender: append (default), anything else clobbers'
EQUALITY caseExactIA5Match
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:7 NAME 'log4perlautoflush'
DESC 'FALSE is default, else use TRUE'
SYNTAX boolean SINGLE-VALUE )
#attributetype ( myattrs:8 NAME 'log4perlParam'
# DESC '1 is default, else use 0'
# EQUALITY distinguishedNameMatch
# SYNTAX ldapDN )
#
#attributetype ( myattrs:10 NAME 'log4perlvalue'
# DESC 'the value half of a name/value tuple'
# EQUALITY caseExactIA5Match
# SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:9 NAME 'log4perlstderr'
DESC 'print to stderr or not'
SYNTAX boolean SINGLE-VALUE )
attributetype ( myattrs:17 NAME 'log4perlCategoryName'
DESC 'e.g. foo.Bar.Twix'
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:12 NAME 'log4perlLevel'
DESC 'logging level, INFO, DEBUG, etc'
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:13 NAME 'log4perlAppenderName'
DESC 'name of the appender at this level of the DIT'
SYNTAX ia5 )
attributetype ( myattrs:14 NAME 'log4perlAppenderDN'
DESC 'if the appender is not at the same level of the DIT as the logger, then we use this to look it up'
SYNTAX ldapDN )
#could use nis.schema ipHostNumber,ipServicePort, but then
#would need a translation scheme?
attributetype ( myattrs:15 NAME 'log4perlPeerAddr'
DESC 'for the socket appender'
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:16 NAME 'log4perlPeerPort'
DESC 'for the socket appender'
SYNTAX ia5 SINGLE-VALUE )
attributetype ( myattrs:18 NAME 'log4perlThreshold'
DESC 'optional threshold for appenders'
SYNTAX ia5 SINGLE-VALUE )
# Object Class Definitions
# Can have 1 or more appenders, names or DNs, but how to specify
# that in this schema?
# The name is used to look up an appender by name at this level of the DIT
objectclass ( myobjs:11 NAME 'log4perlLogger' 'log4perlCategory'
DESC 'category/logger, e.g. log4perl.logger.Bar.Twix'
SUP top
STRUCTURAL
MUST (log4perlCategoryName $ log4perlLevel $ log4perlAppenderName )
MAY ( log4perlAppenderDN )
)
objectclass ( myobjs:13 NAME 'log4perlRootLogger'
DESC 'root logger, the name is only so we can find it in ldap'
SUP log4perlLogger
)
#DESC **MUST*** be before SUP!
#fedora-ds seems to ignore ABSTRACT, it has no problem instantiating an ABSTRACT class
#could also have optional dn pointing to layout class
objectclass ( myobjs:3
NAME 'log4perlAppender'
DESC 'A log4perl Appender'
SUP top
ABSTRACT
MUST ( name $ log4perlClass )
MAY ( log4perlThreshold )
)
objectclass ( myobjs:6
NAME 'log4perlFileAppender'
DESC 'logs to a file'
SUP log4perlAppender
STRUCTURAL
MUST ( log4perlfilename $ log4perlmode )
MAY ( log4perlautoflush )
)
#DEBUG: MAY umask --how to do octal?
objectclass ( myobjs:10 NAME 'log4perlSocketAppender'
DESC 'log4perl socket appender'
SUP log4perlAppender
STRUCTURAL
MUST ( log4perlPeerAddr $ log4perlPeerPort )
)
objectclass ( myobjs:14 NAME 'log4perlTestBufferAppender'
DESC 'for unit tests'
SUP log4perlAppender
STRUCTURAL
)
objectclass ( myobjs:4 NAME 'log4perlLayout'
DESC 'A log4perl simple Layout'
SUP top
ABSTRACT
MUST ( name $ log4perlLayoutClass )
)
objectclass ( myobjs:5 NAME 'log4perlPatternLayout'
DESC 'A log4perl PatternLayout'
SUP log4perlLayout
STRUCTURAL
MUST ( log4perlConversionPattern )
)
#objectclass ( myobjs:7
# NAME 'log4perlParam'
# SUP top
# AUXILIARY
# DESC 'a name/value tuple'
# MUST ( name $ log4perlvalue )
#
# )