Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1a4VGe-00045S-59 for pgsql-jdbc@arkaria.postgresql.org; Thu, 03 Dec 2015 14:53:56 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1a4VGd-0001DR-Np for pgsql-jdbc@arkaria.postgresql.org; Thu, 03 Dec 2015 14:53:55 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1a4VGd-0001DL-0t for pgsql-jdbc@postgresql.org; Thu, 03 Dec 2015 14:53:55 +0000 Received: from mail-wm0-x235.google.com ([2a00:1450:400c:c09::235]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84) (envelope-from ) id 1a4VGY-0002c1-Au for pgsql-jdbc@postgresql.org; Thu, 03 Dec 2015 14:53:54 +0000 Received: by wmww144 with SMTP id w144so25501080wmw.0 for ; Thu, 03 Dec 2015 06:53:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; bh=romqtBHAvfy/TXsv4zlC3zgR4XwnbgCkhK7yqoa6/h8=; b=p9gYBynBhO+yHnycl2+lnfDEPSP1IAujQOJoUo3SQniPvXAGdUrR8C/bDho1fPUx2E kiP9K6/ROqo7IhCPaJWcVNC9530hjQyoHCGZ3xZiEKdLBl3jvPXsYs900rBlhgMjibUY QdX84YSDxrHgZ+KpiGNsWsZ3OmLyTYbJ7mFKqmdsQIHLaChCMRJLP7b1bd9/7v9aUaDW ANunSinSGls+OO9JTAqlVHHh0AiVpqZM3wybHBFdYHBcySQo1O6vzBmaDrJ9w1reAbC0 TxZkgi8Gyik7nxmvg652giXWiJ1u8DnSX5xoLcR3r924926FJFV15VeOYuQ7Mt+P+zcP qGqA== X-Received: by 10.194.243.201 with SMTP id xa9mr11773926wjc.122.1449154428890; Thu, 03 Dec 2015 06:53:48 -0800 (PST) Received: from [192.168.1.66] (123.209.115.89.rev.vodafone.pt. [89.115.209.123]) by smtp.gmail.com with ESMTPSA id bg10sm7881100wjb.46.2015.12.03.06.53.47 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 03 Dec 2015 06:53:47 -0800 (PST) Content-Type: multipart/alternative; boundary="Apple-Mail=_984C5B56-2717-462F-BD6C-9E791E664F37" Mime-Version: 1.0 (Mac OS X Mail 9.1 \(3096.5\)) Subject: Re: user can't access own database after creation From: Nuno Zimas In-Reply-To: Date: Thu, 3 Dec 2015 14:53:46 +0000 Cc: List Message-Id: <3DA4A9D2-41B3-4899-836B-809C72CDCEB6@gmail.com> References: <25B91293-CCF8-42D9-B4ED-19DF36AA881C@gmail.com> <00A2FA5A-3C2A-40CD-9174-EBCC14164B74@gmail.com> <6B5C6030-ABBE-4283-9195-8E4D3E031261@gmail.com> <9C9EB124-5C7C-48B3-BF8D-52B8A7A88F36@gmail.com> <8DC65D5F-EC46-449D-A9B3-486EDD05C17E@gmail.com> <44d99a13-6cd0-4f20-8f0b-227d36f13c67@typeapp.com> <2E9B7FDD-3038-4B5A-9310-5EA98DD0602B@gmail.com> To: Edson Richter X-Mailer: Apple Mail (2.3096.5) X-Pg-Spam-Score: -1.7 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org --Apple-Mail=_984C5B56-2717-462F-BD6C-9E791E664F37 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 I=E2=80=99ve replaced postgresql-9.4-1201.jdbc4.jar with = postgresql-9.4-1206.jdbc42.jar, then renamed it back to = postgresql-9.4-1201.jdbc4.jar so that the application could see it. As suggested buy Edson, I=E2=80=99ve passed an argument to the jdbc URL = to increase verbosity, but without success. 2015-12-03 14:47:22,540 INFO [benexus.nzimas.com-startStop-1] = log.Log4jLogger - # init "benexus" 2015-12-03 14:47:23,027 WARN [benexus.nzimas.com-startStop-1] = log.Log4jLogger - the entity manager of "benexus" has not been = initialized 2015-12-03 14:47:23,028 ERROR [benexus.nzimas.com-startStop-1] = log.Log4jLogger - smartdoc postgres = jdbc:postgresql://10.10.10.100:5432/benexus?loglevel=3D2 2015-12-03 14:47:23,600 INFO [benexus.nzimas.com-startStop-1] = log.Log4jLogger - # init template "Task" 2015-12-03 14:47:24,833 INFO [benexus.nzimas.com-startStop-1] = log.Log4jLogger - # init template "CashTracker" 2015-12-03 14:47:26,170 INFO [main] impl.StdSchedulerFactory - Using = default implementation for ThreadExecutor 2015-12-03 14:47:26,177 INFO [main] simpl.SimpleThreadPool - Job = execution threads will=20 > On 3 Dec 2015, at 14:28, Edson Richter = wrote: >=20 > Well, I don't use JDBC methods directly - just like the OP, I do use = JPA for database access, and set "Target Database" to PostgreSQL - IN = THIS SPECIFIC CASE - is enough so it will not throw any errors. >=20 > I would still put by coins in generating a verbose log. OP shall be = facing other issue, not a JDBC issue at all. >=20 > I've more than 7 years working with PgSQL, JPA and JDBC, and found = only one "prepared statment" glitch with JDBC+timezone+DST, which can be = easly solved with "prepareThreshold=3D0" in connection string - I don't = even think it is a JDBC issue, but a server side prepared statements = issue. > All other issues I've faced so far were caused by my own mistakes on = setting configuration parameters. >=20 > Atenciosamente, >=20 > Edson Carlos Ericksson Richter > Em 03/12/2015 12:19, Dave Cramer escreveu: >> However if the appserver attempts to use a jdk 1.8 JDBC method it = will fail miserably. As long as you stay to jdk 1.6 methods you will be = fine with those JVM's >>=20 >> Dave Cramer >>=20 >> davec@postgresintl.com >> www.postgresintl.com >> On 3 December 2015 at 09:15, Edson Richter > wrote: >> This is the same I use in production servers either with JDK 1.7_80 = and 1.8_65. >> Also, postgresql-9.3-1101.jdbc41.jar works well with both Java = versions. >>=20 >> Atenciosamente, >>=20 >> Edson Carlos Ericksson Richter >> Em 03/12/2015 11:57, Nuno Zimas escreveu: >>> The jar is named postgresql-9.4-1201.jdbc4.jar >>>=20 >>> Nuno. >>>=20 >>> -- >>> Nuno Zimas >>> Systems Administrator & Web Developer >>>=20 >>> T: +44 20 3289 1162 >>> T: +351 244 204 857 >>>=20 >>>> On 3 Dec 2015, at 13:27, Dave Cramer < = pg@fastcrypt.com > = wrote: >>>>=20 >>>> OK, so what version of the postgresql driver are you using. It = should have a 42 in the name if you are using java 8 >>>>=20 >>>> Dave Cramer >>>>=20 >>>> davec@postgresintl.com >>>> www.postgresintl.com >>>> On 3 December 2015 at 08:25, Nuno Zimas < = nzimas@gmail.com > = wrote: >>>> We're using the same Java version on both the local windows machine = and the remote Ubuntu server. >>>>=20 >>>> JRE 1.8.0_65. >>>>=20 >>>> On 3 Dec 2015, at 12:30, Dave Cramer > wrote: >>>> If I had to guess what was wrong here I'd look at whether you have = the right jar for the java version you are using. It will fail silently = if not >>>>=20 >>>> Dave Cramer=20 >>>>=20 >>>> davec@postgresintl.com = >>>> www.postgresintl.com = >>>> On 3 December 2015 at 07:26, Edson Richter < = edsonrichter@hotmail.com = > wrote:=20 >>>> You can add additional logging JPA and JDBC specific:=20 >>>>=20 >>>> JPA:=20 >>>> With EclipseLink, I do use the following property:=20 >>>>=20 >>>> =20= >>>>=20 >>>> You can set it at runtime, but you should look at it - and also = check if your provider has similar = option.=20 >>>> In my application, I've left all defaults in configuration file = (persistence.xml), and just adjust the custom properties at runtime.=20 >>>>=20 >>>> JDBC:=20 >>>> You can add higher logging for jdbc itself with=20 >>>>=20 >>>> jdbc:postgresql:// 10.10.10.100:5432/benexus?loglevel=3D2 = =20 >>>>=20 >>>>=20 >>>> Double check configuration:=20 >>>> Just in case, to make connections out of 127.0.0.1 you must = configure postgres with "listen_address =3D '10.10.10.100' or = listen_address=3D'*' and port =3D '5432' in postgresql.conf; also in = pg_hba.conf you must have the line "host all all 10.10.10.99/32 = md5".=20 >>>>=20 >>>>=20 >>>> Atenciosamente, >>>>=20 >>>> Edson Carlos Ericksson Richter >>>> Em 03/12/2015 09:56, Nuno Zimas escreveu:=20 >>>>> This is as much as I can get from the application log. >>>>> Relevant bit is shown in bold. >>>>>=20 >>>>> 2015-12-03 11:51:26,821 INFO [main] log.Log4jLogger - 2Next 1.0.0 = start >>>>> 2015-12-03 11:51:26,823 INFO [main] log.Log4jLogger - = copyright(c) the flabser team 2015. All Right Reserved >>>>> 2015-12-03 11:51:26,824 INFO [main] log.Log4jLogger - OS: Linux = 2.6.32-34-pve(amd64), jvm: 1.8.0_65 >>>>> 2015-12-03 11:51:26,878 INFO [main] log.Log4jLogger - initialize = runtime environment >>>>> 2015-12-03 11:51:28,160 INFO [main] log.Log4jLogger - webServer = will use port: 8080 >>>>> 2015-12-03 11:51:28,680 INFO [main] log.Log4jLogger - mailAgent = will redirect some messages to host: smtp.mail.ru >>>>> 2015-12-03 11:51:28,682 DEBUG [main] log.Log4jLogger - build: = 11:44 3-December-2015 >>>>> 2015-12-03 11:51:28,690 DEBUG [main] log.Log4jLogger - init = webserver ... >>>>> 2015-12-03 11:51:29,429 INFO [main] log.Log4jLogger - load = "benexus( benexus.nzimas.com )" >>>>> 2015-12-03 11:51:29,701 INFO [main] log.Log4jLogger - load = "FlabserPromo( flabser.com )"=20 >>>>> 2015-12-03 11:51:29,767 DEBUG [main] log.Log4jLogger - register = REST handler "flabserpromo.rest.Service" >>>>> 2015-12-03 11:51:29,776 INFO [main] log.Log4jLogger - load "Task" >>>>> 2015-12-03 11:51:29,813 DEBUG [main] log.Log4jLogger - register = REST handler "task.rest.IssueService" >>>>> 2015-12-03 11:51:29,831 DEBUG [main] log.Log4jLogger - register = REST handler "task.rest.TagService" >>>>> 2015-12-03 11:51:29,837 INFO [main] log.Log4jLogger - load = "administrator(helloadmin.info )" >>>>> 2015-12-03 11:51:29,845 INFO [main] log.Log4jLogger - load = "CashTracker" >>>>> 2015-12-03 11:51:29,860 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.AccountService" >>>>> 2015-12-03 11:51:29,863 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.BudgetService" >>>>> 2015-12-03 11:51:29,865 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.CategoryService" >>>>> 2015-12-03 11:51:29,868 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.CostCenterService" >>>>> 2015-12-03 11:51:29,870 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.DashboardService" >>>>> 2015-12-03 11:51:29,872 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.ReportsService" >>>>> 2015-12-03 11:51:29,874 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.TagService" >>>>> 2015-12-03 11:51:29,876 DEBUG [main] log.Log4jLogger - register = REST handler "cashtracker.rest.TransactionService" >>>>> 2015-12-03 11:51:29,913 INFO [main] log.Log4jLogger - load = "ImmigrationService(aikonamedia.kz )" >>>>> 2015-12-03 11:51:29,979 DEBUG [main] log.Log4jLogger - register = REST handler "immigrationservice.rest.Service" >>>>> 2015-12-03 11:51:30,057 INFO [main] log.Log4jLogger - webserver = start ( 10.10.10.99:8080 ) >>>>> 2015-12-03 11:51:33,913 INFO [ flabser.com = -startStop-1] log.Log4jLogger - # init = "FlabserPromo" >>>>> 2015-12-03 11:51:35,192 INFO [aikonamedia.kz-startStop-1] = log.Log4jLogger - # init "ImmigrationService" >>>>> 2015-12-03 11:51:36,478 INFO [ helloadmin.info = -startStop-1] log.Log4jLogger - # init = "administrator" >>>>> 2015-12-03 11:51:37,080 INFO [benexus.nzimas.com = -startStop-1] log.Log4jLogger - # init = "benexus" >>>>> 2015-12-03 11:51:37,616 WARN [benexus.nzimas.com = -startStop-1] log.Log4jLogger - the entity = manager of "benexus" has not been initialized >>>>> 2015-12-03 11:51:37,617 ERROR [benexus.nzimas.com = -startStop-1] log.Log4jLogger - smartdoc = postgres jdbc:postgresql://10.10.10.100:5432/benexus = >>>>> 2015-12-03 11:51:38,217 INFO [ benexus.nzimas.com = -startStop-1] log.Log4jLogger - # init = template "Task" >>>>> 2015-12-03 11:51:39,508 INFO [ benexus.nzimas.com = -startStop-1] log.Log4jLogger - # init = template "CashTracker" >>>>> 2015-12-03 11:51:40,859 INFO [main] impl.StdSchedulerFactory - = Using default implementation for ThreadExecutor >>>>> 2015-12-03 11:51:40,866 INFO [main] simpl.SimpleThreadPool - Job = execution threads will use class loader of thread: main >>>>> 2015-12-03 11:51:40,929 INFO [main] core.SchedulerSignalerImpl - = Initialized Scheduler Signaller of type: class = org.quartz.core.SchedulerSignalerImpl >>>>> 2015-12-03 11:51:40,931 INFO [main] core.QuartzScheduler - Quartz = Scheduler v.2.1.7 created. >>>>> 2015-12-03 11:51:40,934 INFO [main] simpl.RAMJobStore - = RAMJobStore initialized. >>>>> 2015-12-03 11:51:40,937 INFO [main] core.QuartzScheduler - = Scheduler meta-data: Quartz = Scheduler (v2.1.7) 'DefaultQuartzScheduler' with instanceId = 'NON_CLUSTERED' >>>>> Scheduler class: 'org.quartz.core.QuartzScheduler' - running = locally. >>>>> NOT STARTED. >>>>> Currently in standby mode. >>>>> Number of jobs executed: 0 >>>>> Using thread pool 'org.quartz.simpl.SimpleThreadPool' - with 10 = threads. >>>>> Using job-store 'org.quartz.simpl.RAMJobStore' - which does not = support persistence. and is not clustered. >>>>>=20 >>>>> 2015-12-03 11:51:40,938 INFO [main] impl.StdSchedulerFactory - = Quartz scheduler 'DefaultQuartzScheduler' initialized from default = resource file in Quartz package: 'quartz.properties' >>>>> 2015-12-03 11:51:40,939 INFO [main] impl.StdSchedulerFactory - = Quartz scheduler version: 2.1.7 >>>>> 2015-12-03 11:51:40,964 INFO [main] core.QuartzScheduler - = Scheduler DefaultQuartzScheduler_$_NON_CLUSTERED started. >>>>> 2015-12-03 11:51:40,986 DEBUG [Thread-6] log.Log4jLogger - add = context "Task/1o7r2598w77d0w13" application... >>>>> 2015-12-03 11:51:41,072 DEBUG [Thread-6] log.Log4jLogger - = register REST handler "task.rest.IssueService" >>>>> 2015-12-03 11:51:41,074 DEBUG [Thread-6] log.Log4jLogger - = register REST handler "task.rest.TagService" >>>>> 2015-12-03 11:51:41,122 INFO [Thread-6] log.Log4jLogger - users = contexts are ready >>>>> 2015-12-03 11:52:00,061 INFO [DefaultQuartzScheduler_Worker-1] = log.Log4jLogger - start temp file cleaner tasks >>>>> 2015-12-03 11:52:00,082 INFO [DefaultQuartzScheduler_Worker-2] = log.Log4jLogger - start database remover task >>>>>=20 >>>>>=20 >>>>>=20 >>>>>> On 2 Dec 2015, at 22:17, Dave Cramer < = pg@fastcrypt.com > = wrote: >>>>>>=20 >>>>>> Yes, JDBC is still involved. I'd say there is a mistake in the = JPA config >>>>>>=20 >>>>>> Dave Cramer=20 >>>>>>=20 >>>>>> davec@postgresintl.com = >>>>>> www.postgresintl.com = >>>>>> On 2 December 2015 at 17:15, Nuno Zimas < = nzimas@gmail.com > = wrote:=20 >>>>>> The programmer says that she relies on JPA to establish the = connection, but I suppose that JDBC is still involved, otherwise i = can=E2=80=99t see how java would talk to postgresql.=20 >>>>>> Unless JPA does so directly. >>>>>> Like I said, Java really isn=E2=80=99t my thing. >>>>>>=20 >>>>>>=20 >>>>>>=20 >>>>>>> On 2 Dec 2015, at 22:05, Nuno Zimas < = nzimas@gmail.com > = wrote: >>>>>>>=20 >>>>>>>=20 >>>>>>> Thanks a lot, everyone (and specially Dave Cramer). >>>>>>> Now I know the issue is not JDBC related. >>>>>>> Not sure of this is good news for me, though :) >>>>>>>=20 >>>>>>> I=E2=80=99d think that the application needs to be amended. >>>>>>> Still, this does not account for the fact that it works on a = local win machine. >>>>>>>=20 >>>>>>> As you can see, Dave=E2=80=99s little program connects like a = charm, >>>>>>>=20 >>>>>>> 2015-12-02 17:00:22 EST [2408-1] postgres@postgres LOG: = duration: 16.239 ms parse : SET extra_float_digits =3D 3 >>>>>>> 2015-12-02 17:00:22 EST [2408-2] postgres@postgres LOG: = duration: 0.023 ms bind : SET extra_float_digits =3D 3 >>>>>>> 2015-12-02 17:00:22 EST [2408-3] postgres@postgres LOG: = duration: 0.031 ms execute : SET extra_float_digits =3D 3 >>>>>>> 2015-12-02 17:00:22 EST [2408-4] postgres@postgres LOG: = duration: 0.217 ms parse = : select 1 >>>>>>> 2015-12-02 17:00:22 EST [2408-5] postgres@postgres LOG: = duration: 0.100 ms bind : select 1 >>>>>>> 2015-12-02 17:00:22 EST [2408-6] postgres@postgres LOG: = duration: 0.953 ms execute : select 1 >>>>>>>=20 >>>>>>>=20 >>>>>>>=20 >>>>>>>> On 2 Dec 2015, at 21:45, Dave Cramer < = pg@fastcrypt.com > = wrote: >>>>>>>>=20 >>>>>>>> log_min_duration >>>>>>>=20 >>>>>>=20 >>>>>>=20 >>>>>=20 >>>>=20 >>>>=20 >>>>=20 >>>=20 >>=20 >>=20 >=20 --Apple-Mail=_984C5B56-2717-462F-BD6C-9E791E664F37 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8
I=E2=80=99ve = replaced postgresql-9.4-1201.jdbc4.jar with postgresql-9.4-1206.jdbc42.jar, then renamed it back = to postgresql-9.4-1201.jdbc4.jar so that = the application could see it.

As suggested buy = Edson, I=E2=80=99ve passed an argument to the jdbc URL to increase = verbosity, but without success.

2015-12-03 = 14:47:22,540 INFO  [benexus.nzimas.com-startStop-1] log.Log4jLogger - # init = "benexus"
2015-12-03 = 14:47:23,027 WARN  [benexus.nzimas.com-startStop-1] log.Log4jLogger - the = entity manager of "benexus" has not been initialized
2015-12-03 = 14:47:23,028 ERROR [benexus.nzimas.com-startStop-1] log.Log4jLogger - = smartdoc postgres = jdbc:postgresql://10.10.10.100:5432/benexus?loglevel=3D2
2015-12-03 = 14:47:23,600 INFO  [benexus.nzimas.com-startStop-1] log.Log4jLogger - # init = template "Task"
2015-12-03 14:47:24,833 INFO  [benexus.nzimas.com-startStop-1] log.Log4jLogger - # init = template "CashTracker"
2015-12-03 14:47:26,170 INFO  [main] = impl.StdSchedulerFactory - Using default implementation for = ThreadExecutor
2015-12-03 14:47:26,177 INFO  [main] = simpl.SimpleThreadPool - Job execution threads = will 

On 3 Dec 2015, at 14:28, Edson Richter <edsonrichter@hotmail.com> wrote:

=20 =20
Well, I don't use JDBC methods directly - just like the OP, I do use JPA for database access, and set "Target Database" to PostgreSQL - IN THIS SPECIFIC CASE - is enough so it will not throw any = errors.

I would still put by coins in generating a verbose log. OP shall be facing other issue, not a JDBC issue at all.

I've more than 7 years working with PgSQL, JPA and JDBC, and found only one "prepared statment" glitch with JDBC+timezone+DST, which can be easly solved with "prepareThreshold=3D0" in connection string = - I don't even think it is a JDBC issue, but a server side prepared statements issue.
All other issues I've faced so far were caused by my own mistakes on setting configuration parameters.

Atenciosamente,

Edson Carlos Ericksson Richter
Em 03/12/2015 12:19, Dave Cramer escreveu:
However if the appserver attempts to = use a jdk 1.8 JDBC method it will fail miserably. As long as you stay to jdk 1.6 methods you will be fine with those JVM's


On 3 December 2015 at 09:15, Edson Richter <edsonrichter@hotmail.com> wrote:
This = is the same I use in production servers either with JDK 1.7_80 and 1.8_65.
Also, postgresql-9.3-1101.jdbc41.jar works well with both Java versions.

Atenciosamente,

Edson Carlos Ericksson Richter
Em 03/12/2015 11:57, Nuno Zimas = escreveu:
The jar is named postgresql-9.4-1201.jdbc4.jar

Nuno.

--
Nuno Zimas
Systems Administrator & Web Developer

T: +351 244 204 = 857

On 3 Dec 2015, at 13:27, Dave = Cramer <pg@fastcrypt.com> wrote:

OK, so what = version of the postgresql driver are you using. It should have a 42 in the name if you are using java 8


On 3 December 2015 at 08:25, Nuno Zimas <nzimas@gmail.com> wrote:

We're using the same Java version on both the local windows machine and the remote Ubuntu server.

JRE 1.8.0_65.

On 3 Dec 2015, at 12:30, Dave Cramer <pg@fastcrypt.com> wrote:
= If I had to guess what was wrong here I'd look at whether you have the right jar for the java version you are using. It will fail silently if not =


On 3 December 2015 at 07:26, Edson Richter <edsonrichter@hotmail.com><= /span> wrote:
You can add additional logging JPA and JDBC specific:

JPA:
With EclipseLink, I do use the following property:

=       <property = name=3D"eclipselink.logging.level" value=3D"DEBUG"/> =

You can set it at runtime, but you should look at it - and also check if your provider has similar option.
In my application, I've left all defaults in configuration file (persistence.xml), and just adjust the custom properties at runtime.

JDBC:
You can add higher logging for jdbc itself with

jdbc:postgresql:// 10.10.10.100:5432/benexus?loglevel=3D2


Double check = configuration:
Just in case, to make connections out of 127.0.0.1 you must configure postgres with "listen_address =3D '10.10.10.100' or listen_address=3D'*' and port =3D '5432' = in postgresql.conf; also in pg_hba.conf you must have the line "host all all = 10.10.10.99/32 md5".


Atenciosamente,

Edson Carlos Ericksson Richter
= Em 03/12/2015 09:56, Nuno Zimas escreveu:
= This is as much as I can get from the application log.
= Relevant bit is shown in bold. =
=
=
= 2015-12-03 11:51:26,821 INFO =  [main] = log.Log4jLogger - 2Next 1.0.0 start
= 2015-12-03 11:51:26,823 INFO =  [main] = log.Log4jLogger - copyright(c) the flabser team 2015. All Right Reserved
= 2015-12-03 11:51:26,824 INFO =  [main] = log.Log4jLogger - OS: Linux = 2.6.32-34-pve(amd64), jvm: 1.8.0_65
= 2015-12-03 11:51:26,878 INFO =  [main] = log.Log4jLogger - initialize runtime environment =
= 2015-12-03 11:51:28,160 INFO =  [main] = log.Log4jLogger - webServer will use port: 8080
= 2015-12-03 11:51:28,680 INFO =  [main] = log.Log4jLogger - mailAgent will redirect some messages to host: smtp.mail.ru
= 2015-12-03 11:51:28,682 DEBUG [main] = log.Log4jLogger - build: 11:44 = 3-December-2015
= 2015-12-03 11:51:28,690 DEBUG [main] = log.Log4jLogger - init webserver ...
= 2015-12-03 11:51:29,429 INFO =  [main] = log.Log4jLogger - load "benexus( benexus.nzimas.com)"
= 2015-12-03 11:51:29,701 INFO =  [main] = log.Log4jLogger - load "FlabserPromo( flabser.com)"
= 2015-12-03 11:51:29,767 DEBUG [main] = log.Log4jLogger - register REST handler = "flabserpromo.rest.Service"
= 2015-12-03 11:51:29,776 INFO =  [main] = log.Log4jLogger - load "Task"
= 2015-12-03 11:51:29,813 DEBUG [main] = log.Log4jLogger - register REST handler = "task.rest.IssueService"
= 2015-12-03 11:51:29,831 DEBUG [main] = log.Log4jLogger - register REST handler = "task.rest.TagService"
= 2015-12-03 11:51:29,837 INFO =  [main] = log.Log4jLogger - load = "administrator( helloadmin.info)"
= 2015-12-03 11:51:29,845 INFO =  [main] = log.Log4jLogger - load "CashTracker"
= 2015-12-03 11:51:29,860 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.AccountService"
= 2015-12-03 11:51:29,863 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.BudgetService"
= 2015-12-03 11:51:29,865 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.CategoryService"
= 2015-12-03 11:51:29,868 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.CostCenterService"
= 2015-12-03 11:51:29,870 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.DashboardService"
= 2015-12-03 11:51:29,872 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.ReportsService"
= 2015-12-03 11:51:29,874 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.TagService"
= 2015-12-03 11:51:29,876 DEBUG [main] = log.Log4jLogger - register REST handler = "cashtracker.rest.TransactionService"
= 2015-12-03 11:51:29,913 INFO =  [main] = log.Log4jLogger - load = "ImmigrationService( aikonamedia.kz)"
= 2015-12-03 11:51:29,979 DEBUG [main] = log.Log4jLogger - register REST handler = "immigrationservice.rest.Service"
= 2015-12-03 11:51:30,057 INFO =  [main] = log.Log4jLogger - webserver start ( 10.10.10.99:8080)
=
= 2015-12-03 11:51:33,913 INFO  [ = flabser.com-startStop-1] = log.Log4jLogger - # init "FlabserPromo"
= 2015-12-03 11:51:35,192 INFO =  [aikonamedia.kz-startStop-1] = log.Log4jLogger - # init = "ImmigrationService"
= 2015-12-03 11:51:36,478 INFO  [ = helloadmin.info-startStop-1] = log.Log4jLogger - # init = "administrator"
= 2015-12-03 11:51:37,080 INFO  [benexus.nzimas.com-startStop-1] = log.Log4jLogger - # init "benexus"
= 2015-12-03 11:51:37,616 WARN  [benexus.nzimas.com-startStop-1] = log.Log4jLogger - the entity manager of "benexus" has not been = initialized
= 2015-12-03 11:51:37,617 ERROR [benexus.nzimas.com-startStop-1] = log.Log4jLogger - smartdoc postgres = jdbc:postgresql://10.10.10.100:5432/benexus
= 2015-12-03 11:51:38,217 INFO  [ = benexus.nzimas.com-startStop-1] = log.Log4jLogger - # init template "Task"
= 2015-12-03 11:51:39,508 INFO  [ = benexus.nzimas.com-startStop-1] = log.Log4jLogger - # init template "CashTracker"
= 2015-12-03 11:51:40,859 INFO =  [main] = impl.StdSchedulerFactory - Using default implementation for ThreadExecutor
= 2015-12-03 11:51:40,866 INFO =  [main] = simpl.SimpleThreadPool - Job execution threads will use class loader of thread: main =
= 2015-12-03 11:51:40,929 INFO =  [main] = core.SchedulerSignalerImpl - Initialized Scheduler Signaller of type: class = org.quartz.core.SchedulerSignalerImpl
= 2015-12-03 11:51:40,931 INFO =  [main] = core.QuartzScheduler - Quartz Scheduler v.2.1.7 created. =
= 2015-12-03 11:51:40,934 INFO =  [main] = simpl.RAMJobStore - RAMJobStore initialized. =
= 2015-12-03 11:51:40,937 INFO =  [main] = core.QuartzScheduler - Scheduler meta-data: Quartz Scheduler (v2.1.7) = 'DefaultQuartzScheduler' with instanceId = 'NON_CLUSTERED'
=   Scheduler class: = 'org.quartz.core.QuartzScheduler' - running locally. =
=   NOT STARTED. =
=   Currently in standby mode.
=   Number of jobs executed: 0 =
=   Using thread pool = 'org.quartz.simpl.SimpleThreadPool' - with 10 threads. =
=   Using job-store = 'org.quartz.simpl.RAMJobStore' - which does not support persistence. and is not clustered. =
=
= 2015-12-03 11:51:40,938 INFO =  [main] = impl.StdSchedulerFactory - Quartz scheduler = 'DefaultQuartzScheduler' initialized from default resource file in Quartz package: = 'quartz.properties'
= 2015-12-03 11:51:40,939 INFO =  [main] = impl.StdSchedulerFactory - Quartz scheduler version: 2.1.7
= 2015-12-03 11:51:40,964 INFO =  [main] = core.QuartzScheduler - Scheduler = DefaultQuartzScheduler_$_NON_CLUSTERED started. =
= 2015-12-03 11:51:40,986 DEBUG [Thread-6] = log.Log4jLogger - add context = "Task/1o7r2598w77d0w13" application...
= 2015-12-03 11:51:41,072 DEBUG [Thread-6] = log.Log4jLogger - register REST handler = "task.rest.IssueService"
= 2015-12-03 11:51:41,074 DEBUG [Thread-6] = log.Log4jLogger - register REST handler = "task.rest.TagService"
= 2015-12-03 11:51:41,122 INFO =  [Thread-6] = log.Log4jLogger - users contexts are ready
= 2015-12-03 11:52:00,061 INFO =  [DefaultQuartzScheduler_Worker-1] = log.Log4jLogger - start temp file cleaner tasks
= 2015-12-03 11:52:00,082 INFO =  [DefaultQuartzScheduler_Worker-2] = log.Log4jLogger - start database remover task =
=
=

=
= On 2 Dec 2015, at 22:17, Dave Cramer < pg@fastcrypt.com> wrote:

=
Yes, JDBC is still involved. I'd say there is a mistake in the JPA config =


On 2 December 2015 at 17:15, Nuno Zimas = <nzimas@gmail.com> wrote:
= The programmer says that she relies on JPA to establish the connection, but I suppose that JDBC is still involved, otherwise i can=E2=80=99t = see how java would talk to = postgresql. 
= Unless JPA does so directly. =
= Like I said, Java really isn=E2=80= =99t my thing. =
=
=
=
=

=
= On 2 Dec 2015, at 22:05, Nuno Zimas < nzimas@gmail.com> wrote:

=

=
Thanks a lot, everyone (and specially Dave Cramer). =
Now I know the issue is not JDBC related.
Not sure of this is good news for me, though :) =

I=E2=80=99d = think that the application needs to be amended. =
Still, this does not account for the fact that it works on a local win machine. =

As you can see, Dave=E2=80=99= s little program connects like a charm, =

2015-12-02 17:00:22 EST [2408-1] = postgres@postgres LOG: =  duration: 16.239 ms  parse = <unnamed>: SET = extra_float_digits =3D 3
2015-12-02 17:00:22 EST [2408-2] = postgres@postgres LOG: =  duration: 0.023 ms =  bind = <unnamed>: SET = extra_float_digits =3D 3
2015-12-02 17:00:22 EST [2408-3] = postgres@postgres LOG: =  duration: 0.031 ms  execute = <unnamed>: SET = extra_float_digits =3D 3
2015-12-02 17:00:22 EST [2408-4] = postgres@postgres LOG: =  duration: 0.217 ms  parse = <unnamed>: select 1 =
2015-12-02 17:00:22 EST [2408-5] = postgres@postgres LOG: =  duration: 0.100 ms =  bind = <unnamed>: select 1 =
2015-12-02 17:00:22 EST [2408-6] = postgres@postgres LOG: =  duration: 0.953 ms  execute = <unnamed>: select 1 =



=
= On 2 Dec 2015, at 21:45, Dave Cramer < pg@fastcrypt.com> wrote:

= log_min_duration












= --Apple-Mail=_984C5B56-2717-462F-BD6C-9E791E664F37--