Subversion Repositories DevTools

Rev

Rev 5634 | Rev 5958 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
13 rsolanki 1
<%
2
'=====================================================
3
'					CONFIG FILE
4
'=====================================================
5
%>
6
<%
7
' -- VARIABLE DEFINITION ------------------------------
8
Dim OraSession, OraDatabase		' DB connection
9
Dim QUERIES_PATH
10
Dim SCRIPT_NAME
15 rsolanki 11
Dim TNS_NAME, DB_AUTHENTICATION
13 rsolanki 12
Dim APP_ROOT
17 rsolanki 13
Dim rootPath
14
Dim scriptName
4807 dpurdie 15
Dim SMTP_HOST
5634 dpurdie 16
Dim archive_server              ' Machine name
17
Dim HTTP_PKG_ARCHIVE            ' http and Machine name
18
Dim dpkg_archiveURL             ' http path to dpkg_archive with /
19
Dim release_archiveURL          ' http path to releases with /
5355 dpurdie 20
Dim ACCESS_MANAGER_URL
21
Dim RELEASE_MANAGER_URL
5642 dpurdie 22
Dim DEPLOYMENT_MANAGER_URL
23
Dim PRODUCTION_MANAGER_URL
5355 dpurdie 24
Dim strRelativePath             ' Rel Path from script to URL
25
Dim managerSuiteBase            ' Url to the base of the Manager Suite
26
Dim FavIcon                     ' Favorite Icon
27
Dim RmDebug                     ' Debug Display
28
 
13 rsolanki 29
' -----------------------------------------------------
30
%>
31
<%
32
' -- DATABASE CONNECTIONS -----------------------------
33
'Set OraSession = CreateObject("OracleInProcServer.XOraSession")
31 ghuddy 34
'OraSession.CreateDatabasePool 1,10,100, Application("TNS_NAME"), Application("DEPLOYMENT_MANAGER_LOGIN"), 0
13 rsolanki 35
'Set OraDatabase = OraSession.GetDatabaseFromPool(10)
36
 
37
Set OraSession = CreateObject("OracleInProcServer.XOraSession")
38
Set OraDatabase = OraSession.OpenDatabase( Application("TNS_NAME"), Application("DEPLOYMENT_MANAGER_LOGIN"), Cint(0))
39
' -----------------------------------------------------
40
%>
41
<%
5355 dpurdie 42
' -- Basic Functions ----------------------------------
43
' --------------------------------------------------------------------------------------
44
' Determine if a variable or Const exists and is not empty
45
'   Use to check if a vbscript variable has been declared and contains a non-empty value
46
Function isDefined( var)
47
    If (not IsEmpty(Eval(var))) AND Eval(var & " <> """"") Then
48
        isDefined = TRUE
49
    Else
50
        isDefined = FALSE
51
   End If
52
End Function
53
 
4807 dpurdie 54
'--------------------------------------------------------------------------------------
55
'Returns the server of the package archive
56
Function Get_Mail_Server()
57
   Dim sqry: sqry = "SELECT * FROM RELEASE_MANAGER.BUILD_SERVICE_CONFIG WHERE SERVICE='MAIL SERVER'"
58
   Dim rsTemp
59
   Set rsTemp = OraDatabase.DbCreateDynaset( sqry , cint(0) )
60
   Get_Mail_Server = rsTemp("config")
61
   rsTemp.Close()
62
   Set rsTemp = Nothing
63
End Function
5355 dpurdie 64
'--------------------------------------------------------------------------------------
5634 dpurdie 65
'Returns the server of the package archive
66
Function Get_Archive_Server()
67
   Dim sqry: sqry = "SELECT * FROM RELEASE_MANAGER.BUILD_SERVICE_CONFIG WHERE SERVICE='ARCHIVE SERVER'"
68
   Dim rsTemp
69
   Set rsTemp = OraDatabase.DbCreateDynaset( sqry , cint(0) )
70
   Get_Archive_Server = rsTemp("config")
71
   rsTemp.Close()
72
   Set rsTemp = Nothing
73
End Function
74
'--------------------------------------------------------------------------------------
5355 dpurdie 75
'Return a relative path to the server base. Used for relative pathing to 'images'
76
'Assumes server base is two directores below the web serve root (ManageSuite/Release_Manager)
77
Function GetPathToBase()
78
    Dim url,depth,rv,ii
79
    url = request.servervariables("URL")
80
    depth =  len(url) - len(replace(url, "/", ""))
81
    rv = ""
82
    For ii = 4 To depth
83
        rv = rv & "../"
84
    Next
85
    GetPathToBase = rv
86
End Function
87
 
88
' Return a URL to the base of the Manager suite
89
' Assumes this is one directory down from the web server root
90
Function GetManagerSuiteBase
91
    Dim data
92
    data = Split(request.servervariables("URL"),"/")
93
    GetManagerSuiteBase =  "/" & data(1)
94
End Function
95
 
13 rsolanki 96
' -- CONFIGURATIONS -----------------------------------
97
Const APPLICATION_ID = 1  			' Stored in Deployment Manager, [APPLICATIONS] table
98
APP_ROOT = Server.MapPath(".")
31 ghuddy 99
TNS_NAME = Application("TNS_NAME") '"RELEASEM"
15 rsolanki 100
DB_AUTHENTICATION = Application("DEPLOYMENT_MANAGER_LOGIN") '"release_manager_devl/release_manager_devl"								' DEVL schema
13 rsolanki 101
QUERIES_PATH = APP_ROOT &"\queries"
17 rsolanki 102
scriptName = Mid(Request.ServerVariables("SCRIPT_NAME"), InStrRev(Request.ServerVariables("SCRIPT_NAME"), "/") + 1 )
103
rootPath = Left( Server.MapPath( scriptName ), InStrRev(Server.MapPath( scriptName ), "\") )
4807 dpurdie 104
SMTP_HOST = Get_Mail_Server()
3947 dpurdie 105
Const ADMIN_EMAIL = "VixIT@vixtechnology.com"
13 rsolanki 106
Const enumDB_PERMISSION_TYPE_VISIBLE = 1		' Stored in Access Manager, [Permission_Types] table
107
Const enumDB_PERMISSION_TYPE_ACTIVE = 2			' Stored in Access Manager, [Permission_Types] table
108
Const enumRELEASES_DAYS_BACK_IN_TIME = 7		' Number of days back in time searching for released products
5355 dpurdie 109
 
110
strRelativePath = GetPathToBase()
111
managerSuiteBase = GetManagerSuiteBase()
112
ACCESS_MANAGER_URL      = ManagerSuiteBase & "/Access_Manager"
113
RELEASE_MANAGER_URL     = ManagerSuiteBase & "/Release_Manager"
5642 dpurdie 114
DEPLOYMENT_MANAGER_URL  = ManagerSuiteBase & "/Deployment_Manager"
115
PRODUCTION_MANAGER_URL  = ManagerSuiteBase & "/Production_Manager"
5634 dpurdie 116
 
117
archive_server = Get_Archive_Server()
118
HTTP_PKG_ARCHIVE        = "http://" & archive_server
119
dpkg_archiveURL         = HTTP_PKG_ARCHIVE & "/dpkg_archive/"
120
release_archiveURL      = HTTP_PKG_ARCHIVE & "/releases/"
121
 
5371 dpurdie 122
FavIcon = strRelativePath & "favicons/DM" & Application("FavIconSuffix") & ".png"
5355 dpurdie 123
 
13 rsolanki 124
' -----------------------------------------------------
125
%>
126
<%
127
' -- VARIABLE INITIALISATION --------------------------
128
SCRIPT_NAME = Mid(Request.ServerVariables("SCRIPT_NAME"), InStrRev(Request.ServerVariables("SCRIPT_NAME"), "/") + 1 )
129
Const enumDB_DIFF_NO_CHANGE = 0
130
Const enumDB_DIFF_UPDATED = 2
131
Const enumDB_DIFF_NEW = 1
132
Const enumDB_DIFF_REMOVED = -1
29 jtweddle 133
Const enumDB_FILTER_COMMENTS = "Filter Comments"
134
Const enumDB_FILTER_ISSUES = "Filter Issues"
13 rsolanki 135
Const enumPRODUCTS_BASE_VIEW_ID = 5					' Release Manager products base view id
23 rsolanki 136
Const enumAUTOPRODUCTS_BASE_VIEW_ID = 2602					' Release Manager auto_products base view id
13 rsolanki 137
' -----------------------------------------------------
138
%>
139
<%
140
' -- CONSTANTS ----------------------------------------
141
Const enumDB_DEFAULT_EMPTY = -1
142
Const enumISSUES_STATE_FIXED = 1
143
Const enumCLEARQUEST_DEVI_ID = 4
23 rsolanki 144
Const enumJIRA_ID = 6
13 rsolanki 145
Const enumISSUES_STATE_IMPORTED = 0
146
Const enumDB_YES = "Y"
147
Const enumDB_NO = "N"
148
Const enumDEFAULT = "default"
149
Const enumCOOKIE_NAME = "DeploymentManager"
150
Const enumSEPARATOR_LABEL = "SEPARATOR_LABLE"
151
Const enumDB_ALL_DATA = 0
152
Const SPACER = "<img src='images/spacer.gif' width='1' height='1'>"
153
Const enumMSSQL_ERROR = "<img src='icons/i_no_db_connection.gif' width='16' height='17' hspace='2' border='0' align='absmiddle' title='3rd party database is off-line'><SPAN class='body_txtr'>Information not currently available.</SPAN>"
154
Const enumSESSION_COPY_TYPE = "COPY_TYPE"
155
Const enumSESSION_COPY_ITEMS = "COPY_ITEMS"
156
Const enumSESSION_COPY_FROM = "COPY_FROM"
157
Const enumLOADING = "Loading..."
4807 dpurdie 158
Const enum_MSG_ERROR    = "msg_error.asp"
159
Const enum_RELMGR_ERRDESCRIPTION = "RELMGR_ERRDESCRIPTION"		' session variable where long error message is stored before display to user
13 rsolanki 160
' -- ACTION TRAIL -------------------------------------
161
Const enumAT_EVENT_COMMENT 	= 0
162
Const enumAT_EVENT_ADDED 	= 1
163
Const enumAT_EVENT_MODIFIED = 2
164
Const enumAT_EVENT_REMOVED 	= 3
165
' -----------------------------------------------------
166
%>
167
<%
168
' -- OO4O ---------------------------------------------
169
const ORATYPE_VARCHAR2 = 1
170
const ORATYPE_NUMBER = 2
171
const ORATYPE_SINT = 3
172
const ORATYPE_FLOAT = 4
173
const ORATYPE_STRING = 5
174
const ORATYPE_VARCHAR = 9
175
const ORATYPE_DATE = 12
176
const ORATYPE_UINT = 68
177
const ORATYPE_RAW = 95
178
const ORATYPE_CHAR = 96
179
const ORATYPE_CHARZ = 97
180
const ORATYPE_MLSLABEL = 105
181
const ORATYPE_OBJECT = 108
182
const ORATYPE_REF = 110
183
const ORATYPE_CLOB = 112
184
const ORATYPE_BLOB = 113
185
const ORATYPE_BFILE = 114
186
const ORATYPE_VARRAY = 247
187
const ORATYPE_TABLE = 248
188
const ORATYPE_CURSOR = 102
189
 
4807 dpurdie 190
const ORALOB_ONE_PIECE = 0 
191
const ORALOB_FIRST_PIECE = 1 
192
const ORALOB_NEXT_PIECE = 2 
193
const ORALOB_LAST_PIECE = 3
13 rsolanki 194
 
4807 dpurdie 195
Const ORALOB_SUCCESS = 0
196
Const ORALOB_NEED_DATA = 99
197
Const ORALOB_NODATA = 100
198
 
31 ghuddy 199
const ORAPARM_INPUT=1
200
const ORAPARM_OUTPUT=2
13 rsolanki 201
const ORAPARM_BOTH=3
202
 
203
const ORADYN_DEFAULT=&H0&
204
' -----------------------------------------------------
205
%>
206
<%
207
' -- ERROR MESSAGES -----------------------------------
208
' -----------------------------------------------------
209
%>
210
<%
211
' -- ICONS --------------------------------------------
212
' -- ICONS SMALL --------------------------------------
213
' -----------------------------------------------------
214
' -- Other Configuration -----------------------------
215
Const enum_RELMGR_COOKIE_DOMAIN = "RELMGR_USER_COOKIES"
216
Const COOKIE_HIDE_FILES_FILTER = "COOKIE_HIDE_FILES_FILTER"
217
Const COOKIE_HIDE_DEPS_FILTER = "COOKIE_HIDE_DEPS_FILTER"
218
Const COOKIE_HIDE_DIFF_FILTER = "COOKIE_HIDE_DIFF_FILTER"
219
Const COOKIE_RELMGR_SHOW_VIEW = "COOKIE_RELMGR_SHOW_VIEW"
220
Const COOKIE_RELEASE_MANAGER_MEMORY = "RELEASE_MANAGER_MEMORY"
221
Const COOKIE_PATCH_OPTIONS_FILTER = "COOKIE_PATCH_OPTIONS_FILTER"
222
%>