From nobody Sun Apr 30 12:04:57 2023 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Q8Q560QD8z47k3b; Sun, 30 Apr 2023 12:04:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Q8Q5571k9z4KBV; Sun, 30 Apr 2023 12:04:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682856298; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9Uyr4l9GkLyK6dGM+SwIMS4UvNIAeSrZRqG3pUkXNfI=; b=b3T9wisPCBPbHq4oJzKiJZPwz2lRJDvofNp9KwsdnKwiLonSQr4+F5xw2zLO4DNENjIEw4 W4kHqtxaNTBTfgLzQ5lCwQc2Gxm9Ybl6rTTu+p6mUpoiAas5fPn6SbLE3EpDnxJwjYKSDL y/Ba3gdSCmpOIeAsSN+1uQwjFFDRng2UB0EA+qOngBDpHXHjhTQDKKSDtvOZgGwO3zdD6x a2ZL9rI5XirPwBGl3rWyKQax9oDd4rRzMHBD/ywKXKXeS9amY6p5BpOeYET6j5ydaMZOn7 kAap3X6a6A3okkS9M5zMhyMrxiQoSr3FzTCpq0pp5lC2IvIhFdlOIS0zXiNmUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682856298; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9Uyr4l9GkLyK6dGM+SwIMS4UvNIAeSrZRqG3pUkXNfI=; b=LZAt/q5nyc4tw84Vz6awIubDEgqwbZ5zN8jBxYicwCGoTfa+VMYd7HWAPU8AP4DcqiD5Y/ elesV0uSCmIvX+ZPGe8qkQ4wP+qslQEYUvyflcXspYVQvb/B/PBzhzoKIYMgb2vLTdZFy1 UuMN9s333NsjR8jSwkuBP9I52maBkKJYdMGgQ199utOKBXKhL3zloRohPHdtBkXir1N0lg vkhbrfyaG1kN/WtVnG3IWrOX8qwkIKxzqHg5/CswaK1YteE3OJCGnhWDK8uJ+NYP9Jk1oa mA5PmNbett6gsVL/SYMTeG/G2ocOqOlkdnIYDzdggsDAxnu3w7lDgKL7rbAHKA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1682856298; a=rsa-sha256; cv=none; b=kOo4xABP2OmFloMUjH5oHC0cnt/ahEfGelWjoUB0hOBMSnnsWgHrZACYkX8SRmSQxFMiWj XJP1GWrvylefvKltVPztROu4Xts4lFzcpGPzUixzfQzlty2oQ++yN3GouYYsnz2BWfS5eq 6g1E26H0qEHL5OdmjWjkxgtwohCG4aSkywj9q9gzwBnWsILvQ9nF0Z9UJDQ0B1Pyo/evN9 hddSTJcIU8vf3eXf2PzI4JWs5QYChlsunquYiyb3Wia5C4Ti468rESZfbpiLp4dY6F/N25 eQpMW9Q2mUc+FC3lvpIonAgMic9sMCCHwWl7InnLJWrovpLMFioYq2f2jaULcA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Q8Q5564N7zNWh; Sun, 30 Apr 2023 12:04:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 33UC4vTi084956; Sun, 30 Apr 2023 12:04:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 33UC4voo084955; Sun, 30 Apr 2023 12:04:57 GMT (envelope-from git) Date: Sun, 30 Apr 2023 12:04:57 GMT Message-Id: <202304301204.33UC4voo084955@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: =?utf-8?Q?Fernando=20Apestegu=C3=ADa?= Subject: git: a6345cef112d - main - net/activemq: update to 5.18.1 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: fernape X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a6345cef112d74fd440a25cdbb68733fe1bf6c4d Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by fernape: URL: https://cgit.FreeBSD.org/ports/commit/?id=a6345cef112d74fd440a25cdbb68733fe1bf6c4d commit a6345cef112d74fd440a25cdbb68733fe1bf6c4d Author: James Elstone AuthorDate: 2023-04-29 18:06:44 +0000 Commit: Fernando ApesteguĂ­a CommitDate: 2023-04-30 11:59:53 +0000 net/activemq: update to 5.18.1 Reporter becomes maintainer. Already maintainer of some ports. Makefile: * Bumped to version 5.18.1 * Added maintainer information * Specified version of openJDK to use * Updated initial audit.log and activemq.log to match thoses set in /etc/rc.conf * Removed .orig file deletion of non-existant file distinfo: * Updated checksum for new distfile files/activemq: (activemq rc.d startup file) * Added explict JAVA_HOME path to use, and defaulted to java/openjdk18 * Added rc.conf tunable to allow the full java command to be echoed on stdout on service start (debuging for people not so familiar with activemq and how it is envoked) * Added audit logging to be turned on by default, with explaination in rc file. * Added Jolokia configuration file path to activemq invokation, supressing null pointer error on start-up PR: 271100 Reported by: james@elstone.net --- net/activemq/Makefile | 8 +++--- net/activemq/distinfo | 6 ++--- net/activemq/files/activemq.in | 57 ++++++++++++++++++++++++++++++++++-------- 3 files changed, 55 insertions(+), 16 deletions(-) diff --git a/net/activemq/Makefile b/net/activemq/Makefile index 6d85ef5be430..953c048cb821 100644 --- a/net/activemq/Makefile +++ b/net/activemq/Makefile @@ -1,11 +1,11 @@ PORTNAME= activemq -PORTVERSION= 5.17.2 +PORTVERSION= 5.18.1 CATEGORIES= net java MASTER_SITES= APACHE/${PORTNAME}/${PORTVERSION} DISTNAME= apache-${PORTNAME}-${PORTVERSION} EXTRACT_SUFX= -bin.tar.gz -MAINTAINER= ports@FreeBSD.org +MAINTAINER= james@elstone.net COMMENT= Messaging and Integration Patterns provider WWW= https://activemq.apache.org @@ -15,6 +15,7 @@ LICENSE_FILE= ${WRKSRC}/LICENSE USES= cpe CPE_VENDOR= apache USE_JAVA= yes +JAVA_VERSION= 18 USE_RC_SUBR= activemq NO_ARCH= yes @@ -30,7 +31,8 @@ PORTEXAMPLES= * OPTIONS_DEFINE= DOCS EXAMPLES do-install: - ${RM} ${WRKSRC}/conf/log4j.properties.orig + @${REINPLACE_CMD} -i '' -e 's|$\{sys:activemq.data\}\/audit.log|\$\{sys:activemq.logs\}\/audit.log|g' ${WRKSRC}/conf/log4j2.properties + @${REINPLACE_CMD} -i '' -e 's|$\{sys:activemq.data\}\/activemq.log|\$\{sys:activemq.logs\}\/activemq.log|g' ${WRKSRC}/conf/log4j2.properties @${MKDIR} ${STAGEDIR}${ETCDIR} cd ${WRKSRC}/conf && for f in *; do \ ${INSTALL_DATA} ${WRKSRC}/conf/$$f ${STAGEDIR}${ETCDIR}/$$f.sample; \ diff --git a/net/activemq/distinfo b/net/activemq/distinfo index 71379e3fc510..1b9119985556 100644 --- a/net/activemq/distinfo +++ b/net/activemq/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1668099098 -SHA256 (apache-activemq-5.17.2-bin.tar.gz) = 4216387240ef38e912f88162c52e26128f0f72d15910852d12eb0a7845819195 -SIZE (apache-activemq-5.17.2-bin.tar.gz) = 48943814 +TIMESTAMP = 1682592741 +SHA256 (apache-activemq-5.18.1-bin.tar.gz) = fedd7bde9af5babaeb072bf7aeb2065d9021c26163ded639c87a32d673795472 +SIZE (apache-activemq-5.18.1-bin.tar.gz) = 49261889 diff --git a/net/activemq/files/activemq.in b/net/activemq/files/activemq.in index cc399619b130..10a7d237e5bc 100644 --- a/net/activemq/files/activemq.in +++ b/net/activemq/files/activemq.in @@ -10,19 +10,40 @@ # # activemq_enable (bool): Set to NO by default. # Set it to YES to enable activemq. +# # activemq_user (username): Set to activemq by default. # Set it to required username. +# # activemq_group (group): Set to activemq by default. # Set it to required group. +# # activemq_classpath (path): Set to %%DATADIR%% by default. # Set it to java classes directory. +# # activemq_home (path): Set to %%DATADIR%% by default. # Set it to java home directory. +# # activemq_javargs (args): Set to -Xmx256M by default. # See java -h for available arguments. +# # activemq_stop_timeout (num): Set to "10" by default. # Set the timeout in seconds to shutdown. # +# activemq_java_home (path): Set the path to the jvm to use. +# Set to openJDK18 by default. +# +# activemq_debug_precmd (bool): Give java command line that +# will be run, when started for debugging outside +# of being demonised. Helpful for people new to +# activemq. +# +# activemq_audit_log (bool): Enable audit logging by default. +# In production, you will have to evaluate enabling +# this option (set to NO to disable), as it has +# disk I/O and storage implications which may +# impact expected performance. By disabling the +# audit log, security logging maybe reduced +# depending on your configuration. . /etc/rc.subr @@ -42,24 +63,37 @@ load_rc_config $name : ${activemq_javargs:='-Xmx512M -Dorg.apache.activemq.UseDedicatedTaskRunner=true -Djava.util.logging.config.file=logging.properties -Dcom.sun.management.jmxremote'} : ${activemq_stop_timeout:="10"} : ${activemq_hostname:=`/bin/hostname`} +: ${activemq_java_home:='%%LOCALBASE%%/openjdk18/bin/java'} +: ${activemq_debug_precmd:=NO} +: ${activemq_audit_log:=YES} pidfile=/var/run/${name}.pid required_files="%%ETCDIR%%/activemq.xml" jar_file="%%DATADIR%%/bin/activemq.jar" -java_options=" -server -jar ${activemq_javargs} \ - -Dactivemq.classpath=${activemq_classpath} \ - -Dactivemq.conf=${activemq_conf} \ - -Dactivemq.data=${activemq_data} \ - -Dactivemq.logs=${activemq_logs} \ - -Dactivemq.home=${activemq_home} \ - -Dactivemq.base=${activemq_home} \ - -Dactivemq.hostname=${activemq_hostname}" -java_command="%%LOCALBASE%%/bin/java ${java_options} ${jar_file}" +activemq_audit_args="" +if checkyesno activemq_audit_log; then + activemq_audit_args="-Dorg.apache.activemq.audit=true" +fi + +jolokia_conf="file:${activemq_conf}/jolokia-access.xml" + +java_options="-server -jar ${activemq_javargs} \ +-Dactivemq.classpath=${activemq_classpath} \ +-Dactivemq.conf=${activemq_conf} \ +-Dactivemq.data=${activemq_data} \ +-Dactivemq.logs=${activemq_logs} \ +-Dactivemq.home=${activemq_home} \ +-Dactivemq.base=${activemq_home} \ +-Djolokia.conf=${jolokia_conf} \ +${activemq_audit_args} \ +-Dactivemq.hostname=${activemq_hostname}" + +java_command="${activemq_java_home} ${java_options} ${jar_file}" command="/usr/sbin/daemon" -command_args="-f -p ${pidfile} ${java_command} start" +command_args="-p ${pidfile} -o ${activemq_logs}/daemon.log ${java_command} start" start_precmd="activemq_precmd" status_cmd="activemq_status" stop_cmd="activemq_stop" @@ -69,6 +103,9 @@ activemq_precmd() { chown ${activemq_user}:${activemq_group} ${pidfile} /usr/bin/install -d -m 0750 -o ${activemq_user} -g ${activemq_group} ${activemq_logs} /usr/bin/install -d -m 0750 -o ${activemq_user} -g ${activemq_group} ${activemq_data} + if checkyesno activemq_debug_precmd; then + echo "Starting with Java command: ${java_command}" + fi } activemq_stop() {