atlas-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sarath Subramanian <sarath.ku...@gmail.com>
Subject Re: Review Request 57941: [ATLAS-1685] : Fix coverity scan issues found in latest report
Date Mon, 27 Mar 2017 01:38:02 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/57941/
-----------------------------------------------------------

(Updated March 26, 2017, 6:38 p.m.)


Review request for atlas.


Changes
-------

Addressed review comments.


Bugs: ATLAS-1685
    https://issues.apache.org/jira/browse/ATLAS-1685


Repository: atlas


Description
-------

** CID 161144:  Null pointer dereferences  (NULL_RETURNS)
    /repository/src/main/java/org/apache/atlas/discovery/EntityDiscoveryService.java: 267
in org.apache.atlas.discovery.EntityDiscoveryService.searchUsingBasicQuery(java.lang.String,
java.lang.String, java.lang.String, int, int)()
    
    
    ________________________________________________________________________________________________________
    *** CID 161144:  Null pointer dereferences  (NULL_RETURNS)
    /repository/src/main/java/org/apache/atlas/discovery/EntityDiscoveryService.java: 267
in org.apache.atlas.discovery.EntityDiscoveryService.searchUsingBasicQuery(java.lang.String,
java.lang.String, java.lang.String, int, int)()
    261    
    262                 bindings.put("startIdx", params.offset());
    263                 bindings.put("endIdx", params.offset() + params.limit());
    264    
    265                 basicQuery += gremlinQueryProvider.getQuery(AtlasGremlinQuery.TO_RANGE_LIST);
    266    
    >>>     CID 161144:  Null pointer dereferences  (NULL_RETURNS)
    >>>     Assigning: "scriptEngine" = null return value from "getGremlinScriptEngine".
    267                 ScriptEngine scriptEngine = graph.getGremlinScriptEngine();
    268    
    269                 try {
    270                     Object result = graph.executeGremlinScript(scriptEngine, bindings,
basicQuery, false);
    271    
    272                     if (result instanceof List && CollectionUtils.isNotEmpty((List)
result)) {
    
    ** CID 161143:  Null pointer dereferences  (NULL_RETURNS)
    /graphdb/titan0/src/main/java/org/apache/atlas/repository/graphdb/titan0/Titan0Graph.java:
329 in org.apache.atlas.repository.graphdb.titan0.Titan0Graph.executeGremlinScript(java.lang.String)()
    
    
    ________________________________________________________________________________________________________
    *** CID 161143:  Null pointer dereferences  (NULL_RETURNS)
    /graphdb/titan0/src/main/java/org/apache/atlas/repository/graphdb/titan0/Titan0Graph.java:
329 in org.apache.atlas.repository.graphdb.titan0.Titan0Graph.executeGremlinScript(java.lang.String)()
    323    
    324         private Object executeGremlinScript(String gremlinQuery) throws ScriptException
{
    325             Object       result = null;
    326             ScriptEngine engine = getGremlinScriptEngine();
    327    
    328             try {
    >>>     CID 161143:  Null pointer dereferences  (NULL_RETURNS)
    >>>     Calling a method on null object "engine".
    329                 Bindings bindings = engine.createBindings();
    330    
    331                 bindings.put("g", getGraph());
    332    
    333                 result = engine.eval(gremlinQuery, bindings);
    334             } finally {


Diffs (updated)
-----

  graphdb/api/src/main/java/org/apache/atlas/repository/graphdb/AtlasGraph.java 1c75636 
  graphdb/titan0/src/main/java/org/apache/atlas/repository/graphdb/titan0/Titan0Graph.java
e114daa 
  graphdb/titan1/src/main/java/org/apache/atlas/repository/graphdb/titan1/Titan1Graph.java
e5a1d2c 
  intg/src/main/java/org/apache/atlas/AtlasErrorCode.java 4506187 
  repository/src/main/java/org/apache/atlas/discovery/EntityDiscoveryService.java 1cf4434

  repository/src/main/java/org/apache/atlas/discovery/EntityLineageService.java b81754d 
  repository/src/main/java/org/apache/atlas/discovery/graph/GraphBackedDiscoveryService.java
f84f405 
  repository/src/main/java/org/apache/atlas/services/MetricsService.java 3ef0138 
  repository/src/test/java/org/apache/atlas/services/MetricsServiceTest.java 1531c9c 
  webapp/src/main/java/org/apache/atlas/web/resources/ExportService.java 54faee0 


Diff: https://reviews.apache.org/r/57941/diff/2/

Changes: https://reviews.apache.org/r/57941/diff/1-2/


Testing
-------

mvn clean install suceeded.

Reactor Summary:

Apache Atlas Server Build Tools .................... SUCCESS [  0.633 s]
apache-atlas ....................................... SUCCESS [  4.491 s]
Apache Atlas Integration ........................... SUCCESS [ 32.816 s]
Apache Atlas Common ................................ SUCCESS [  9.632 s]
Apache Atlas Typesystem ............................ SUCCESS [ 51.112 s]
Apache Atlas Client ................................ SUCCESS [ 12.583 s]
Apache Atlas Server API ............................ SUCCESS [  5.022 s]
Apache Atlas Notification .......................... SUCCESS [ 26.358 s]
Apache Atlas Graph Database Projects ............... SUCCESS [  0.448 s]
Apache Atlas Graph Database API .................... SUCCESS [  3.493 s]
Graph Database Common Code ......................... SUCCESS [  3.935 s]
Apache Atlas Titan 1.0.0 GraphDB Impl .............. SUCCESS [ 23.265 s]
Shaded version of Apache hbase client .............. SUCCESS [  6.032 s]
Apache Atlas Titan 0.5.4 Graph DB Impl ............. SUCCESS [01:18 min]
Apache Atlas Graph Database Implementation Dependencies SUCCESS [  0.510 s]
Shaded version of Apache hbase server .............. SUCCESS [ 14.334 s]
Apache Atlas Repository ............................ SUCCESS [10:08 min]
Apache Atlas Authorization ......................... SUCCESS [  8.722 s]
Apache Atlas Business Catalog ...................... SUCCESS [ 22.054 s]
Apache Atlas UI .................................... SUCCESS [01:03 min]
Apache Atlas Web Application ....................... SUCCESS [06:16 min]
Apache Atlas Documentation ......................... SUCCESS [  6.352 s]
Apache Atlas FileSystem Model ...................... SUCCESS [  2.302 s]
Apache Atlas Plugin Classloader .................... SUCCESS [  6.466 s]
Apache Atlas Hive Bridge Shim ...................... SUCCESS [  3.912 s]
Apache Atlas Hive Bridge ........................... SUCCESS [07:49 min]
Apache Atlas Falcon Bridge Shim .................... SUCCESS [  3.756 s]
Apache Atlas Falcon Bridge ......................... SUCCESS [01:03 min]
Apache Atlas Sqoop Bridge Shim ..................... SUCCESS [  3.118 s]
Apache Atlas Sqoop Bridge .......................... SUCCESS [01:08 min]
Apache Atlas Storm Bridge Shim ..................... SUCCESS [  3.868 s]
Apache Atlas Storm Bridge .......................... SUCCESS [01:14 min]
Apache Atlas Distribution .......................... SUCCESS [  6.296 s]
------------------------------------------------------------------------
BUILD SUCCESS
------------------------------------------------------------------------
Total time: 34:24 min
Finished at: 2017-03-26T15:27:50-07:00
Final Memory: 991M/2682M
------------------------------------------------------------------------


Thanks,

Sarath Subramanian


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message