Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Dennis Prior

#1
I think there are missing som Repos...

[ERROR] Failed to execute goal on project empty: Could not resolve dependencies
for project org.netxms.report:empty:jar:1.0.0: Failure to find com.radensolution
s:nxreporting:jar:2.0.5 in https://repo.maven.apache.org/maven2 was cached in th
e local repository, resolution will not be reattempted until the update interval
of central has elapsed or updates are forced -> [Help 1]
#2
Hi all,

I try to pack my simple Report into a .jar -file using maven. My NetXMS Version is 2.0.5, also the Reporting Server.

Maven says:

[ERROR] Failed to execute goal on project dci: Could not resolve dependencies fo
r project org.netxms.report:dci:jar:1.0.0: Could not find artifact com.radensolu
tions:nxreporting:jar:2.0-SNAPSHOT -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal o
n project dci: Could not resolve dependencies for project org.netxms.report:dci:
jar:1.0.0: Could not find artifact com.radensolutions:nxreporting:jar:2.0-SNAPSH
OT

Maven cannot find the dependency com.radensolutions:nxreporting ... any help for this?
#3
General Support / Re: Install report server
October 22, 2015, 10:41:28 AM
Hello Alex,

can you upload the examples once again?
The projekt files in sample_reports.tar.gz do not work. Thank you.

Kind regards,
Dennis

Quote from: Alex Kirhenshtein on April 07, 2015, 08:51:10 PM
Hello.

Reporting module is still sort of work-in-progress, it will be finalised and fully documented with the 2.0 release.

In a meantime, I'll write some notes here.

Part 1 – setup

1) Enable support in netxms core, then restart netxmsd: nxdbmgr set EnableReportingServer 1

2) Unpack netxms-reporting-server-2.0-M2.zip into some folder, in this example - /opt/nxreporting

3) Create directory "conf"

4) Create logger configuration: conf/logback.xml (sample attached), detailed description here: http://logback.qos.ch/manual/configuration.html#syntax

5) Create configuration file for reporting server: conf/nxreporting.xml
<config>
  <workspace>/opt/nxreporting/workspace</workspace>
    <netxmsdConfig>/opt/netxms/etc/netxmsd.conf</netxmsdConfig>
    <datasources>
        <datasource>
            <id>secondary</id>
            <type>postgresql</type>
            <url>jdbc:postgresql://127.0.0.1/netxms</url>
            <username>netxms</username>
            <password>netxms</password>
        </datasource>
    </datasources>
    <smtp>
        <server>127.0.0.1</server>
        <from>[email protected]</from>
    </smtp>
    <netxms>
        <server>127.0.0.1</server>
        <login>admin</login>
        <password>netxms</password>
    </netxms>
</config>


In most cases (when reports are using only single datasource), setting "netxmsdConfig" is enough, database type and credentials will loaded automatically from netxmsd.conf.
"netxms" section of the config is required for reports, which load data not from SQL datasource, but using NetXMS API instead (connection is maintained by reporting server).

6) Create workspace directory (as set by "workspace" parameter), it will contain both report definitions and intermediate report data (in "output" directory).

7) Put report definition jars into workspace/definitions/:AirAlk:~() $ ls -al /opt/nxreporting/workspace/definitions/*.jar
-rw-r--r--  1 alk  wheel  3729 Mar 11 15:31 /opt/nxreporting/workspace/definitions/alarm-history-1.0.0.jar
-rw-r--r--  1 alk  wheel  5607 Mar 11 15:31 /opt/nxreporting/workspace/definitions/alarm-resolution-time-1.0.0.jar
-rw-r--r--  1 alk  wheel  4570 Mar 11 15:31 /opt/nxreporting/workspace/definitions/alarm-resolution-time-statistics-by-users-1.0.0.jar
-rw-r--r--  1 alk  wheel  4203 Mar 11 15:31 /opt/nxreporting/workspace/definitions/dci-1.0.0.jar
-rw-r--r--  1 alk  wheel  9968 Mar 11 15:31 /opt/nxreporting/workspace/definitions/epp-1.0.0.jar
...


8) Start reporting server:cd /opt/nxreporting
java -jar nxreporting-2.0-M2.jar


When started with "-jar" option, java will automatically find configuration files in conf/ and all libraries in lib/. However, you can run it differently (and omit "cd /opt/nxreporting"): java -cp /opt/nxreporting/lib/\*.jar:/opt/nxreporting/conf:/opt/nxreporting/nxreporting-2.0-M2.jar com.radensolutions.reporting.Launcher

or, if you are running windows: java -cp /opt/nxreporting/lib/\*.jar:/opt/nxreporting/conf:/opt/nxreporting/nxreporting-2.0-M2.jar com.radensolutions.reporting.Launcher


Resulting directory structure:/opt/nxreporting:
total 5728
drwxr-xr-x   6 alk  wheel      204 Apr  7 20:31 .
drwxr-xr-x  14 alk  wheel      476 Apr  3 20:07 ..
drwxr-xr-x   4 alk  wheel      136 Apr  7 20:31 conf
drwxr-xr-x  79 alk  wheel     2686 Jan 23 10:29 lib
-rw-r--r--   1 alk  wheel  2929061 Jan 23 10:29 nxreporting-2.0-M2.jar
drwxr-xr-x   4 alk  wheel      136 Mar 11 15:06 workspace

/opt/nxreporting/conf:
total 16
drwxr-xr-x  4 alk  wheel   136 Apr  7 20:31 .
drwxr-xr-x  6 alk  wheel   204 Apr  7 20:31 ..
-rw-r--r--  1 alk  wheel  1367 Apr  7 20:21 logback.xml
-rw-r--r--  1 alk  wheel   764 Apr  7 13:21 nxreporting.xml

/opt/nxreporting/lib:
total 109528
...

/opt/nxreporting/workspace:
total 0
drwxr-xr-x   4 alk  wheel   136 Mar 11 15:06 .
drwxr-xr-x   6 alk  wheel   204 Apr  7 20:31 ..
drwxr-xr-x  32 alk  wheel  1088 Mar 11 15:43 definitions
drwxr-xr-x   8 alk  wheel   272 Mar 11 15:42 output

/opt/nxreporting/workspace/definitions:
total 248
drwxr-xr-x  32 alk  wheel  1088 Mar 11 15:43 .
drwxr-xr-x   4 alk  wheel   136 Mar 11 15:06 ..
-rw-r--r--   1 alk  wheel  3729 Mar 11 15:31 alarm-history-1.0.0.jar
-rw-r--r--   1 alk  wheel  5607 Mar 11 15:31 alarm-resolution-time-1.0.0.jar
-rw-r--r--   1 alk  wheel  4570 Mar 11 15:31 alarm-resolution-time-statistics-by-users-1.0.0.jar
...

/opt/nxreporting/workspace/output:
total 0
drwxr-xr-x   8 alk  wheel  272 Mar 11 15:42 .
drwxr-xr-x   4 alk  wheel  136 Mar 11 15:06 ..
drwxr-xr-x   4 alk  wheel  136 Mar 11 15:44 01827cdb-cb23-4b06-b607-fd02c4279add
drwxr-xr-x   4 alk  wheel  136 Mar  7 22:04 52ce4398-a131-4a79-887e-672cc73d5d34
drwxr-xr-x   3 alk  wheel  102 Mar 11 15:44 8a7c025c-84c8-4914-b2bf-3b4cde27a224
...


You can download complete sample setup here (including two reports): https://www.dropbox.com/s/pcqtfqhnwnrseb9/nxreporting.tar.bz2?dl=0