Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[TUBEMQ-226] Add Windows startup scripts (#141)
Co-authored-by: Gabriel Zhou <gabrielzhou@tencent.com>
- Loading branch information
1 parent
6f914db
commit b38de8a
Showing
3 changed files
with
87 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
REM Licensed to the Apache Software Foundation (ASF) under one or more | ||
REM contributor license agreements. See the NOTICE file distributed with | ||
REM this work for additional information regarding copyright ownership. | ||
REM The ASF licenses this file to You under the Apache License, Version 2.0 | ||
REM (the "License"); you may not use this file except in compliance with | ||
REM the License. You may obtain a copy of the License at | ||
REM <p> | ||
REM http://www.apache.org/licenses/LICENSE-2.0 | ||
REM <p> | ||
REM Unless required by applicable law or agreed to in writing, software | ||
REM distributed under the License is distributed on an "AS IS" BASIS, | ||
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
REM See the License for the specific language governing permissions and | ||
REM limitations under the License. | ||
|
||
REM Windows Startup Script for Broker Node | ||
REM please do not change any command or variable in this script, check out | ||
REM env.cmd for details. | ||
|
||
setlocal | ||
call "%~dp0env.cmd" | ||
|
||
set BROKERMAIN=org.apache.tubemq.server.tools.BrokerStartup | ||
set BROKERCFG=%~dp0../conf/broker.ini | ||
|
||
echo on | ||
call %JAVA% %BROKER_JVM_OPTS% %GENERIC_ARGS% "%BROKERMAIN%" -f "%BROKERCFG%" | ||
endlocal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
REM Licensed to the Apache Software Foundation (ASF) under one or more | ||
REM contributor license agreements. See the NOTICE file distributed with | ||
REM this work for additional information regarding copyright ownership. | ||
REM The ASF licenses this file to You under the Apache License, Version 2.0 | ||
REM (the "License"); you may not use this file except in compliance with | ||
REM the License. You may obtain a copy of the License at | ||
REM <p> | ||
REM http://www.apache.org/licenses/LICENSE-2.0 | ||
REM <p> | ||
REM Unless required by applicable law or agreed to in writing, software | ||
REM distributed under the License is distributed on an "AS IS" BASIS, | ||
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
REM See the License for the specific language governing permissions and | ||
REM limitations under the License. | ||
|
||
REM Windows Startup Script about Environment Settings | ||
REM Java runtime evironment could be specified here. | ||
|
||
set BASE_DIR=%~dp0.. | ||
set CLASSPATH=%BASE_DIR%\lib\*;%BASE_DIR%\tubemq-server\target\*;%CLASSPATH% | ||
set GENERIC_ARGS="-Dtubemq.home=%BASE_DIR%" -cp "%CLASSPATH%" "-Dlog4j.configuration=file:%BASE_DIR%\conf\master.log4j.properties" | ||
|
||
REM If there's no system-wide JAVA_HOME or there's need to run on specific Java, | ||
REM please uncomment the following JAVA_HOME line, and specify the java home path. | ||
REM set JAVA_HOME=C:\Program Files\Java\jdk1.8.0_241 | ||
|
||
set JAVA="%JAVA_HOME%\bin\java" | ||
|
||
REM One may add extra Java runtime flags in addition to each role: Master or Broker | ||
set MASTER_JVM_OPTS=-Xmx1g -Xms256m -server | ||
set BROKER_JVM_OPTS=-Xmx1g -Xms512g -server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
REM Licensed to the Apache Software Foundation (ASF) under one or more | ||
REM contributor license agreements. See the NOTICE file distributed with | ||
REM this work for additional information regarding copyright ownership. | ||
REM The ASF licenses this file to You under the Apache License, Version 2.0 | ||
REM (the "License"); you may not use this file except in compliance with | ||
REM the License. You may obtain a copy of the License at | ||
REM <p> | ||
REM http://www.apache.org/licenses/LICENSE-2.0 | ||
REM <p> | ||
REM Unless required by applicable law or agreed to in writing, software | ||
REM distributed under the License is distributed on an "AS IS" BASIS, | ||
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
REM See the License for the specific language governing permissions and | ||
REM limitations under the License. | ||
|
||
REM Windows Startup Script for Master Node | ||
REM please do not change any command or variable in this script, check out | ||
REM env.cmd for details. | ||
|
||
setlocal | ||
call "%~dp0env.cmd" | ||
|
||
set MASTERMAIN=org.apache.tubemq.server.tools.MasterStartup | ||
set MASTERCFG=%~dp0..\conf\master.ini | ||
|
||
echo on | ||
call %JAVA% %MASTER_JVM_OPTS% %GENERIC_ARGS% "%MASTERMAIN%" -f "%MASTERCFG%" | ||
endlocal |