Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
Openfire
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Openfire
Commits
9b34bc69
Commit
9b34bc69
authored
Dec 21, 2017
by
Greg Thomas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OF-1404: add the MS SQL Server drivers to the distribution.
parent
0b5ba6cf
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
39 additions
and
27 deletions
+39
-27
mssql-jdbc-6.2.2.jre7.jar
build/lib/dist/mssql-jdbc-6.2.2.jre7.jar
+0
-0
versions.txt
build/lib/versions.txt
+1
-0
database.html
documentation/docs/database.html
+19
-24
setup-datasource-standard.jsp
src/web/setup/setup-datasource-standard.jsp
+9
-2
pom.xml
xmppserver/pom.xml
+10
-1
No files found.
build/lib/dist/mssql-jdbc-6.2.2.jre7.jar
0 → 100644
View file @
9b34bc69
File added
build/lib/versions.txt
View file @
9b34bc69
...
...
@@ -70,6 +70,7 @@ mina-filter-compression.jar | Apache Mina 2.0.7
mina-integration-beans.jar | Apache Mina 2.0.7 | Apache 2.0
mina-integration-jmx.jar | Apache Mina 2.0.7 | Apache 2.0
mina-integration-ognl.jar | Apache Mina 2.0.7 | Apache 2.0
mssql-jdbc-6.2.2.jre7.jar | 6.2.2.jre7 | MIT
javassist.jar | 3.11.0.GA (Apache Mina 2.0.7) | Apache 2.0
ognl.jar | 3.0.5 (Apache Mina 2.0.7) | Apache 2.0
mysql.jar | 5.1.42 | GPL
...
...
documentation/docs/database.html
View file @
9b34bc69
...
...
@@ -26,17 +26,12 @@ database, you must setup and manage an external database for the application.
This document provides setup instructions for all of the currently supported databases.
</p>
<p>
JDBC
2.0
drivers are required for Openfire to communicate with your database. Suggested
JDBC drivers are required for Openfire to communicate with your database. Suggested
drivers for particular databases are noted below where applicable. Openfire bundles JDBC
drivers for MySQL, Postgres, Microsoft SQL Server, and HSQLDB.
</p>
<p>
For a full list of available JDBC drivers, please see:
<a
href=
"http://industry.java.sun.com/products/jdbc/drivers"
>
http://industry.java.sun.com/products/jdbc/drivers
</a>
.
</p>
<p>
All database schemas can be found in the
<tt>
resources/database
</tt>
directory of the
All supported database schemas can be found in the
<tt>
resources/database
</tt>
directory of the
Openfire installation.
</p>
...
...
@@ -50,7 +45,7 @@ Choose your database from the list below for setup details:
<ul>
<li>
<a
href=
"#mysql"
>
MySQL
</a>
<li>
<a
href=
"#oracle"
>
Oracle
</a>
<li>
<a
href=
"#sqlserver"
>
Microsoft SQLServer
</a>
<li>
<a
href=
"#sqlserver"
>
Microsoft SQL
Server
</a>
<li>
<a
href=
"#postgres"
>
PostgreSQL
</a>
<li>
<a
href=
"#db2"
>
IBM DB2
</a>
<li>
<a
href=
"#hsql"
>
HSQLDB
</a>
...
...
@@ -153,24 +148,30 @@ Choose your database from the list below for setup details:
That will import the schema file. Your database is now setup.
</p>
</ul>
<p><h2><a
name=
"sqlserver"
>
SQL Server
</a></h2><p>
<p><h2><a
name=
"sqlserver"
>
Microsoft
SQL Server
</a></h2><p>
<ul>
<p><b>
SQL Server
</b></p>
<b>
JDBC Drivers
</b><p>
Openfire includes the
<a
href=
"http://www.freetds.org/"
>
Free TDS
</a>
JDBC driver, which
is the recommended way to connect to SQL Server databases. To
connect to SQL Server, simply use the following values in the Openfire
web-based setup tool:
<p>
Openfire bundles two SQL Server compatible JDBC drivers.
<ul>
<li>
The
<a
href=
"http://www.freetds.org/"
>
Free TDS JDBC driver
</a></li>
<ul>
<li>
driver --
<tt>
net.sourceforge.jtds.jdbc.Driver
</tt>
<li>
server --
<tt>
jdbc:jtds:sqlserver://[host-name]:[port-number]/[database-name];appName=jiv
e
</tt>
<li>
server --
<tt>
jdbc:jtds:sqlserver://[host-name]:[port-number]/[database-name];appName=Openfir
e
</tt>
</ul>
<li>
The
<a
href=
"https://docs.microsoft.com/en-us/sql/connect/jdbc/microsoft-jdbc-driver-for-sql-server"
>
Microsoft JDBC driver
</a></li>
<ul>
<li>
driver --
<tt>
com.microsoft.sqlserver.jdbc.SQLServerDriver
</tt>
<li>
server --
<tt>
jdbc:sqlserver://[host-name]:[port-number];databaseName=[database-name];applicationName=Openfire
</tt>
</ul>
</ul>
You can use either of these, but the Microsoft driver is more up to date.
<p>
where
[host-name] is the host name or IP address of your database server,
and [port-number] is the port that SQL
Server is listening on (normally 1433)
For the above server settings,
[host-name] is the host name or IP address of your database server,
[port-number] is the port that SQL
Server is listening on (normally 1433)
and [database-name] is the name of the database (this parameter is optional).
<p><b>
Setup Instructions
</b><p>
...
...
@@ -181,12 +182,6 @@ Choose your database from the list below for setup details:
<li>
Create a user to access the database if you do not already have one you'd
like to use. Consider making the default database for the user be the
one you created in step 1.
<li>
Open the Query Analyser and connect to the server.
<li>
Select the database you want to use for Openfire
from the DB drop down (the one you created in step 1 if you're using a new database).
<li>
Open the openfire_sqlserver.sql file.
<li>
Press F5 to run the script. The script will run and create the
necessary tables.
<li>
Proceed to the Openfire setup tool and use the appropriate JDBC settings
when prompted.
</ol>
...
...
src/web/setup/setup-datasource-standard.jsp
View file @
9b34bc69
...
...
@@ -240,9 +240,10 @@
List
<
String
[]
>
presets
=
new
ArrayList
<
String
[]
>
();
presets
.
add
(
new
String
[]{
"MySQL"
,
"com.mysql.jdbc.Driver"
,
"jdbc:mysql://[host-name]:3306/[database-name]?rewriteBatchedStatements=true"
});
presets
.
add
(
new
String
[]{
"Oracle"
,
"oracle.jdbc.driver.OracleDriver"
,
"jdbc:oracle:thin:@[host-name]:1521:[SID]"
});
presets
.
add
(
new
String
[]{
"Microsoft SQL
Server"
,
"net.sourceforge.jtds.jdbc.Driver"
,
"jdbc:jtds:sqlserver://[host-name]/[database-name];appName=jiv
e"
});
presets
.
add
(
new
String
[]{
"Microsoft SQL
Server (legacy)"
,
"net.sourceforge.jtds.jdbc.Driver"
,
"jdbc:jtds:sqlserver://[host-name]/[database-name];appName=Openfir
e"
});
presets
.
add
(
new
String
[]{
"PostgreSQL"
,
"org.postgresql.Driver"
,
"jdbc:postgresql://[host-name]:5432/[database-name]"
});
presets
.
add
(
new
String
[]{
"IBM DB2"
,
"com.ibm.db2.jcc.DB2Driver"
,
"jdbc:db2://[host]:50000/[database-name]"
});
presets
.
add
(
new
String
[]{
"Microsoft SQL Server"
,
"com.microsoft.sqlserver.jdbc.SQLServerDriver"
,
"jdbc:sqlserver://[host-name]:1433;databaseName=[database-name];applicationName=Openfire"
});
%>
<script
language=
"JavaScript"
type=
"text/javascript"
>
var
data
=
new
Array
();
...
...
@@ -275,8 +276,14 @@ function checkSubmit() {
<option
value=
""
><fmt:message
key=
"setup.datasource.standard.pick_database"
/>
<%
for
(
int
i
=
0
;
i
<
presets
.
size
();
i
++)
{
String
[]
data
=
presets
.
get
(
i
);
final
String
selected
;
if
(
data
[
1
].
equals
(
driver
)
)
{
selected
=
"SELECTED"
;
}
else
{
selected
=
""
;
}
%>
<option
value=
"
<%=
i
%>
"
>
•
<%=
data
[
0
]
%>
<option
value=
"
<%=
i
%>
"
<%=
selected
%>
>
•
<%=
data
[
0
]
%>
<%
}
%>
</select>
</td>
...
...
xmppserver/pom.xml
View file @
9b34bc69
...
...
@@ -414,7 +414,16 @@
<artifactId>
postgresql
</artifactId>
<version>
42.1.4.jre7
</version>
</dependency>
<dependency>
<groupId>
net.sourceforge.jtds
</groupId>
<artifactId>
jtds
</artifactId>
<version>
1.3.1
</version>
</dependency>
<dependency>
<groupId>
com.microsoft.sqlserver
</groupId>
<artifactId>
mssql-jdbc
</artifactId>
<version>
6.2.2.jre7
</version>
</dependency>
<!-- Test Scope -->
<dependency>
<groupId>
junit
</groupId>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment