[ 
https://issues.apache.org/jira/browse/AMBARI-12685?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14663223#comment-14663223
 ] 

Jonathan Hurley commented on AMBARI-12685:
------------------------------------------

Examples of bridged log statements:

{code}
[EL Warning]: 2015-08-08 22:03:53.215--ServerSession(563080372)-- Reverting the 
lazy setting on the OneToOne or ManyToOne attribute [executionCommand] for the 
entity class [class 
org.apache.ambari.server.orm.entities.HostRoleCommandEntity] since weaving was 
not enabled or did not occur.
[EL Info]: 2015-08-08 22:03:53.374--ServerSession(563080372)-- 
file:/Users/jhurley/src/hwx/ambari/ambari-server/target/classes/_ambari-server_nonJtaDataSource=1538908809_url=jdbc:postgresql://localhost/ambari_user=ambari-server
 login successful
...
[EL Debug]: 2015-08-08 
22:17:34.305--ServerSession(1653567754)--Connection(2013352132)--Thread(Thread[qtp-ambari-agent-57,5,main])--
 SELECT definition_id, cluster_id, component_name, definition_name, 
description, ENABLED, HASH, ignore_host, label, schedule_interval, scope, 
service_name, alert_source, source_type FROM alert_definition WHERE 
(((service_name = ?) AND (component_name = ?)) AND (cluster_id = ?))
        bind => [YARN, RESOURCEMANAGER, 2]
[EL Debug]: 2015-08-08 
22:17:34.306--ServerSession(1653567754)--Connection(761406242)--Thread(Thread[qtp-ambari-agent-57,5,main])--
 SELECT definition_id, cluster_id, component_name, definition_name, 
description, ENABLED, HASH, ignore_host, label, schedule_interval, scope, 
service_name, alert_source, source_type FROM alert_definition WHERE 
(((service_name = ?) AND (component_name = ?)) AND (cluster_id = ?))
        bind => [ZOOKEEPER, ZOOKEEPER_SERVER, 2]
[EL Debug]: 2015-08-08 
22:17:34.307--ServerSession(1653567754)--Connection(941036240)--Thread(Thread[qtp-ambari-agent-57,5,main])--
 SELECT definition_id, cluster_id, component_name, definition_name, 
description, ENABLED, HASH, ignore_host, label, schedule_interval, scope, 
service_name, alert_source, source_type FROM alert_definition WHERE 
((((service_name IN (?,?,?,?)) AND (scope = ?)) AND (cluster_id = ?)) AND 
(component_name IS NULL))
        bind => [ZOOKEEPER, MAPREDUCE2, HDFS, YARN, SERVICE, 2]
{code}

> EclipseLink stdout Log Statements Fill Up Disk Space
> ----------------------------------------------------
>
>                 Key: AMBARI-12685
>                 URL: https://issues.apache.org/jira/browse/AMBARI-12685
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 2.0.0
>            Reporter: Jonathan Hurley
>            Assignee: Jonathan Hurley
>            Priority: Critical
>             Fix For: 2.1.1
>
>
> EclipseLink's default logger logs to standard output. Since Ambari redirects 
> stdout to a file, this means that all EclipseLink statements are captured in 
> {{ambari-server.out}}.
> On some systems with latency problems, EclipseLink will log retry attempts:
> {code}
> ...
> [EL Info]: 2015-07-21 04:52:51.346--UnitOfWork(506587476)--Communication 
> failure detected when attempting to perform read query outside of a 
> transaction. Attempting to retry query. Error was: Exception 
> [EclipseLink-4002] (Eclipse Persistence Services - 2.5.2.v20140319-9ad6abd): 
> org.eclipse.persistence.exceptions.DatabaseException
> Internal Exception: org.postgresql.util.PSQLException: The connection attempt 
> failed.
> Error Code: 0
> Query: ReadAllQuery(name="HostEntity.findByHostName" 
> referenceClass=HostEntity sql="SELECT host_id, cpu_count, cpu_info, 
> discovery_status, host_attributes, host_name, ipv4, ipv6, 
> last_registration_time, os_arch, os_info, os_type, ph_cpu_count, 
> public_host_name, rack_info, total_mem FROM hosts WHERE (host_name = ?)").
> [EL Severe]: 2015-07-21 04:52:51.347--ServerSession(1225946600)--Exception 
> [EclipseLink-4002] (Eclipse Persistence Services - 2.5.2.v20140319-9ad6abd): 
> org.eclipse.persistence.exceptions.DatabaseException
> Internal Exception: org.postgresql.util.PSQLException: Connection refused. 
> Check that the hostname and port are correct and that the postmaster is 
> accepting TCP/IP connections.
> Error Code: 0
> ...
> {code} 
> Since this log is not rolling, it can fill up the disk.
> There is no log4j bridge for EclipseLink. This Jira will track the creation 
> of an slf4j bridge that will log all SQL statements to a separate, rolling 
> logger. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to