id
stringlengths
7
14
test_class
dict
test_case
dict
focal_class
dict
focal_method
dict
repository
dict
146510094_333
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testWriteFailsWhenQueryIsSpecified() throws Exception {\n expectedException.expect(IllegalArgumentException.class);\n expectedException.expectMessage(\"specifying query name in data path is not supported for JDBC writable external tables\");\n context.setDataSour...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(JdbcAccessor.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(JdbcAccessor.class);", "type": "Logger", "var_name": "LOG" }, { "declarat...
{ "body": "@Override\n public boolean openForWrite() throws SQLException, SQLTimeoutException, ParseException, ClassNotFoundException {\n if (queryName != null) {\n throw new IllegalArgumentException(\"specifying query name in data path is not supported for JDBC writable external tables\");\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_299
{ "fields": [ { "declarator": "accessor", "modifier": "", "original_string": "AvroFileAccessor accessor;", "type": "AvroFileAccessor", "var_name": "accessor" }, { "declarator": "context", "modifier": "", "original_string": "RequestContext context;", "t...
{ "body": "@Test\n public void testInitialize() {\n accessor.initialize(context);\n Schema schema = (Schema) context.getMetadata();\n assertNotNull(schema);\n verifySchema(schema, \"example_schema\");\n }", "class_method_signature": "AvroFileAccessorTest.testInitialize()", "const...
{ "fields": [ { "declarator": "COMPRESSION_CODEC_OPTION = \"COMPRESSION_CODEC\"", "modifier": "private static final", "original_string": "private static final String COMPRESSION_CODEC_OPTION = \"COMPRESSION_CODEC\";", "type": "String", "var_name": "COMPRESSION_CODEC_OPTION" }, ...
{ "body": "@Override\n public void initialize(RequestContext requestContext) {\n super.initialize(requestContext);\n\n schema = avroUtilities.obtainSchema(context, configuration, hcfsType);\n }", "class_method_signature": "AvroFileAccessor.initialize(RequestContext requestContext)", "construct...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_348
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testGetConnectionPoolEnabledMaxConnOne() throws SQLException {\n expectedException.expect(SQLTransientConnectionException.class);\n expectedException.expectMessage(containsString(\" - Connection is not available, request timed out after \"));\n\n Driver mockDrive...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(ConnectionManager.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(ConnectionManager.class);", "type": "Logger", "var_name": "LOG" }, { ...
{ "body": "public Connection getConnection(String server, String jdbcUrl, Properties connectionConfiguration, boolean isPoolEnabled, Properties poolConfiguration, String qualifier) throws SQLException {\n\n Connection result;\n if (!isPoolEnabled) {\n LOG.debug(\"Requesting DriverManager.getC...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_78
{ "fields": [ { "declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"", "modifier": "private", "original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";", "type": "String", "var_name": "PROPERTY_KEY_...
{ "body": "@Test\n public void maskNonPrintable() {\n String input = \"\";\n String result = Utilities.maskNonPrintables(input);\n assertEquals(\"\", result);\n\n input = null;\n result = Utilities.maskNonPrintables(input);\n assertNull(result);\n\n input = \"Lucy i...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(Utilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);", "type": "Logger", "var_name": "LOG" }, { "declarator": "...
{ "body": "public static String maskNonPrintables(String input) {\n if (StringUtils.isEmpty(input)) {\n return input;\n }\n return input.replaceAll(\"[^a-zA-Z0-9_:/-]\", \".\");\n }", "class_method_signature": "Utilities.maskNonPrintables(String input)", "constructor": false, ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_124
{ "fields": [ { "declarator": "MINUTES = 60 * 1000L", "modifier": "private static final", "original_string": "private static final long MINUTES = 60 * 1000L;", "type": "long", "var_name": "MINUTES" }, { "declarator": "provider = null", "modifier": "private", ...
{ "body": "@Test\n public void getProxyUGIFromEmptyCache() throws Exception {\n UserGroupInformation ugi = cache.getUserGroupInformation(session, true);\n assertNotNull(ugi);\n verify(provider).createProxyUGI(\"the-user\", UserGroupInformation.getLoginUser());\n }", "class_method_signatur...
{ "fields": [ { "declarator": "NANOS_PER_MILLIS = 1000000", "modifier": "static final", "original_string": "static final int NANOS_PER_MILLIS = 1000000;", "type": "int", "var_name": "NANOS_PER_MILLIS" }, { "declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L", "modif...
{ "body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_97
{ "fields": [ { "declarator": "PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\"", "modifier": "private static final", "original_string": "private static final String PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\";", "type": "String"...
{ "body": "@Test\n public void testGlobalImpersonationPropertyTRUE() {\n System.setProperty(PROPERTY_KEY_USER_IMPERSONATION, \"TRUE\");\n assertTrue(secureLogin.isUserImpersonationEnabled(configuration));\n }", "class_method_signature": "SecureLoginTest.testGlobalImpersonationPropertyTRUE()", ...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecureLogin.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecureLogin.class);", "type": "Logger", "var_name": "LOG" }, { "declarator...
{ "body": "public boolean isUserImpersonationEnabled(Configuration configuration) {\n String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, \"false\"));\n return StringUtils.equalsIgnoreCase(va...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_173
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" } ...
{ "body": "@Test\n public void testGetProtocol() {\n ProfilesConf profilesConf = getProfilesConf(\"testGetProtocol\");\n assertEquals(\"bar\", profilesConf.getProtocol(\"foo\"));\n }", "class_method_signature": "ProfilesConfTest.testGetProtocol()", "constructor": false, "full_signature": "@T...
{ "fields": [ { "declarator": "EXTERNAL_PROFILES = \"pxf-profiles.xml\"", "modifier": "private final static", "original_string": "private final static String EXTERNAL_PROFILES = \"pxf-profiles.xml\";", "type": "String", "var_name": "EXTERNAL_PROFILES" }, { "declarator":...
{ "body": "@Override\n public String getProtocol(String profileName) {\n return getProfile(profileName).getProtocol();\n }", "class_method_signature": "ProfilesConf.getProtocol(String profileName)", "constructor": false, "full_signature": "@Override public String getProtocol(String profileName)", ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_309
{ "fields": [ { "declarator": "accessor", "modifier": "private", "original_string": "private Accessor accessor;", "type": "Accessor", "var_name": "accessor" }, { "declarator": "context", "modifier": "private", "original_string": "private RequestContext conte...
{ "body": "@Test\n public void testSkipHeaderCountIsNotANaturalNumber() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Property SKIP_HEADER_COUNT has incorrect value -5 : must be a non-negative integer\");\n\n context.setDataSource(\"/foo\");\n context.addOp...
{ "fields": [ { "declarator": "DEFAULT_BUFFER_SIZE = 8192", "modifier": "private static final", "original_string": "private static final int DEFAULT_BUFFER_SIZE = 8192;", "type": "int", "var_name": "DEFAULT_BUFFER_SIZE" }, { "declarator": "PXF_CHUNK_RECORD_READER_ENABLE...
{ "body": "@Override\n public void initialize(RequestContext context) {\n super.initialize(context);\n ((TextInputFormat) inputFormat).configure(jobConf);\n skipHeaderCount = context.getFragmentIndex() == 0\n ? context.getOption(\"SKIP_HEADER_COUNT\", 0, true)\n :...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_39
{ "fields": [ { "declarator": "gpCSV", "modifier": "private", "original_string": "private GreenplumCSV gpCSV;", "type": "GreenplumCSV", "var_name": "gpCSV" }, { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_str...
{ "body": "@Test\n public void testCsvOptionWithDelimiterInvalid() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"invalid DELIMITER character '\\\\\\\\'. Only single character is allowed for DELIMITER.\");\n gpCSV.withDelimiter(\"\\\\\\\\\");\n }", "class_meth...
{ "fields": [ { "declarator": "QUOTE = '\"'", "modifier": "private static final", "original_string": "private static final char QUOTE = '\"';", "type": "char", "var_name": "QUOTE" }, { "declarator": "ESCAPE = '\"'", "modifier": "private static final", "origi...
{ "body": "public GreenplumCSV withDelimiter(String delimiterString) {\n if (StringUtils.equalsIgnoreCase(\"OFF\", delimiterString)) {\n delimiter = null;\n } else if (StringUtils.isNotEmpty(delimiterString)) {\n validateSingleCharacter(delimiterString, \"DELIMITER\");\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_165
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void determineRemoteUser_IsGpdbUser_Kerberos_Impersonation_ServiceUser() throws Exception {\n expectScenario(true, true, true);\n filter.doFilter(mockServletRequest, mockServletResponse, mockFilterChain);\n verifyScenario(\"gpdb-user\", true);\n }", "class_method...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);", "type": "Logger", "var_name": "LOG" }, ...
{ "body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_132
{ "fields": [ { "declarator": "MINUTES = 60 * 1000L", "modifier": "private static final", "original_string": "private static final long MINUTES = 60 * 1000L;", "type": "long", "var_name": "MINUTES" }, { "declarator": "provider = null", "modifier": "private", ...
{ "body": "@Test\n public void getTwoProxyUGIsWithDifferentUsers() throws Exception {\n SessionId otherSession = new SessionId(0, \"txn-id\", \"different-user\", \"default\", false, UserGroupInformation.getLoginUser());\n UserGroupInformation proxyUGI1 = cache.getUserGroupInformation(session, true);\...
{ "fields": [ { "declarator": "NANOS_PER_MILLIS = 1000000", "modifier": "static final", "original_string": "static final int NANOS_PER_MILLIS = 1000000;", "type": "int", "var_name": "NANOS_PER_MILLIS" }, { "declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L", "modif...
{ "body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_81
{ "fields": [ { "declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"", "modifier": "private", "original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";", "type": "String", "var_name": "PROPERTY_KEY_...
{ "body": "@Test\n public void useStats() {\n RequestContext mockCtxSupporting = mock(RequestContext.class);\n when(mockCtxSupporting.getAggType()).thenReturn(EnumAggregationType.COUNT);\n when(mockCtxSupporting.getAccessor()).thenReturn(\"org.greenplum.pxf.api.utilities.UtilitiesTest$StatsAcc...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(Utilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);", "type": "Logger", "var_name": "LOG" }, { "declarator": "...
{ "body": "public static boolean aggregateOptimizationsSupported(RequestContext requestContext) {\n boolean isStatsAccessor = implementsInterface(requestContext.getAccessor(), StatsAccessor.class);\n /* Make sure filter is not present, aggregate operation supports optimization and accessor implements St...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_133
{ "fields": [ { "declarator": "MINUTES = 60 * 1000L", "modifier": "private static final", "original_string": "private static final long MINUTES = 60 * 1000L;", "type": "long", "var_name": "MINUTES" }, { "declarator": "provider = null", "modifier": "private", ...
{ "body": "@Test\n public void anySegmentIdIsValid() throws Exception {\n int crazySegId = Integer.MAX_VALUE;\n session = new SessionId(crazySegId, \"txn-id\", \"the-user\", \"default\");\n UserGroupInformation proxyUGI1 = cache.getUserGroupInformation(session, true);\n assertNotNull(pr...
{ "fields": [ { "declarator": "NANOS_PER_MILLIS = 1000000", "modifier": "static final", "original_string": "static final int NANOS_PER_MILLIS = 1000000;", "type": "int", "var_name": "NANOS_PER_MILLIS" }, { "declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L", "modif...
{ "body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_80
{ "fields": [ { "declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"", "modifier": "private", "original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";", "type": "String", "var_name": "PROPERTY_KEY_...
{ "body": "@Test\n public void useAggBridge() {\n RequestContext metaData = mock(RequestContext.class);\n when(metaData.getAccessor()).thenReturn(StatsAccessorImpl.class.getName());\n when(metaData.getAggType()).thenReturn(EnumAggregationType.COUNT);\n when(metaData.getAccessor()).thenR...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(Utilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);", "type": "Logger", "var_name": "LOG" }, { "declarator": "...
{ "body": "public static boolean aggregateOptimizationsSupported(RequestContext requestContext) {\n boolean isStatsAccessor = implementsInterface(requestContext.getAccessor(), StatsAccessor.class);\n /* Make sure filter is not present, aggregate operation supports optimization and accessor implements St...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_38
{ "fields": [ { "declarator": "gpCSV", "modifier": "private", "original_string": "private GreenplumCSV gpCSV;", "type": "GreenplumCSV", "var_name": "gpCSV" }, { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_str...
{ "body": "@Test\n public void testCsvOptionWithNewlineInvalid() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"invalid newline character '\\\\\\\\'. Only LF, CR, or CRLF are supported for newline.\");\n gpCSV.withNewline(\"\\\\\\\\\");\n }", "class_method_sig...
{ "fields": [ { "declarator": "QUOTE = '\"'", "modifier": "private static final", "original_string": "private static final char QUOTE = '\"';", "type": "char", "var_name": "QUOTE" }, { "declarator": "ESCAPE = '\"'", "modifier": "private static final", "origi...
{ "body": "public GreenplumCSV withNewline(String newline) {\n if (StringUtils.isNotEmpty(newline)) {\n // validate that it is \\n or \\r or \\r\\n\n // Greenplum only supports LF (Line feed, 0x0A), CR\n // (Carriage return, 0x0D), or CRLF (Carriage return plus line\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_164
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void determineRemoteUser_IsGpdbUser_Kerberos_Impersonation_NoServiceUser() throws Exception {\n expectScenario(true, true, false);\n filter.doFilter(mockServletRequest, mockServletResponse, mockFilterChain);\n verifyScenario(\"gpdb-user\", true);\n }", "class_met...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);", "type": "Logger", "var_name": "LOG" }, ...
{ "body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_308
{ "fields": [ { "declarator": "accessor", "modifier": "private", "original_string": "private Accessor accessor;", "type": "Accessor", "var_name": "accessor" }, { "declarator": "context", "modifier": "private", "original_string": "private RequestContext conte...
{ "body": "@Test\n public void testSkipHeaderCountIsNotANumber() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Property SKIP_HEADER_COUNT has incorrect value foo : must be a non-negative integer\");\n\n context.setDataSource(\"/foo\");\n context.addOption(\...
{ "fields": [ { "declarator": "DEFAULT_BUFFER_SIZE = 8192", "modifier": "private static final", "original_string": "private static final int DEFAULT_BUFFER_SIZE = 8192;", "type": "int", "var_name": "DEFAULT_BUFFER_SIZE" }, { "declarator": "PXF_CHUNK_RECORD_READER_ENABLE...
{ "body": "@Override\n public void initialize(RequestContext context) {\n super.initialize(context);\n ((TextInputFormat) inputFormat).configure(jobConf);\n skipHeaderCount = context.getFragmentIndex() == 0\n ? context.getOption(\"SKIP_HEADER_COUNT\", 0, true)\n :...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_172
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" } ...
{ "body": "@Test\n public void testUndefinedProfileWhenGettingProtocol() {\n expectedException.expect(ProfileConfException.class);\n expectedException.expectMessage(\"UndefinedProfile is not defined in profile/undefinedProfile/pxf-profiles.xml\");\n\n ProfilesConf profilesConf = getProfilesCon...
{ "fields": [ { "declarator": "EXTERNAL_PROFILES = \"pxf-profiles.xml\"", "modifier": "private final static", "original_string": "private final static String EXTERNAL_PROFILES = \"pxf-profiles.xml\";", "type": "String", "var_name": "EXTERNAL_PROFILES" }, { "declarator":...
{ "body": "@Override\n public String getProtocol(String profileName) {\n return getProfile(profileName).getProtocol();\n }", "class_method_signature": "ProfilesConf.getProtocol(String profileName)", "constructor": false, "full_signature": "@Override public String getProtocol(String profileName)", ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_79
{ "fields": [ { "declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"", "modifier": "private", "original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";", "type": "String", "var_name": "PROPERTY_KEY_...
{ "body": "@Test\n public void parseFragmentMetadata() throws Exception {\n RequestContext metaData = mock(RequestContext.class);\n ByteArrayOutputStream bas = new ByteArrayOutputStream();\n ObjectOutputStream os = new ObjectOutputStream(bas);\n os.writeLong(10);\n os.writeLong(1...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(Utilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);", "type": "Logger", "var_name": "LOG" }, { "declarator": "...
{ "body": "public static FragmentMetadata parseFragmentMetadata(RequestContext context) {\n if (context.getFragmentMetadata() == null) {\n return new FragmentMetadata(0, 0, HOSTS);\n }\n try (ObjectInputStream objectStream =\n new ObjectInputStream(new ByteArrayInpu...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_125
{ "fields": [ { "declarator": "MINUTES = 60 * 1000L", "modifier": "private static final", "original_string": "private static final long MINUTES = 60 * 1000L;", "type": "long", "var_name": "MINUTES" }, { "declarator": "provider = null", "modifier": "private", ...
{ "body": "@Test\n public void getSameUGITwiceUsesCache() throws Exception {\n UserGroupInformation ugi1 = cache.getUserGroupInformation(session, false);\n UserGroupInformation ugi2 = cache.getUserGroupInformation(session, false);\n assertEquals(ugi1, ugi2);\n verify(provider, times(1))...
{ "fields": [ { "declarator": "NANOS_PER_MILLIS = 1000000", "modifier": "static final", "original_string": "static final int NANOS_PER_MILLIS = 1000000;", "type": "int", "var_name": "NANOS_PER_MILLIS" }, { "declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L", "modif...
{ "body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_96
{ "fields": [ { "declarator": "PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\"", "modifier": "private static final", "original_string": "private static final String PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\";", "type": "String"...
{ "body": "@Test\n public void testGlobalImpersonationPropertyFalse() {\n System.setProperty(PROPERTY_KEY_USER_IMPERSONATION, \"foo\");\n assertFalse(secureLogin.isUserImpersonationEnabled(configuration));\n }", "class_method_signature": "SecureLoginTest.testGlobalImpersonationPropertyFalse()", ...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecureLogin.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecureLogin.class);", "type": "Logger", "var_name": "LOG" }, { "declarator...
{ "body": "public boolean isUserImpersonationEnabled(Configuration configuration) {\n String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, \"false\"));\n return StringUtils.equalsIgnoreCase(va...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_349
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testGetConnectionPoolEnabledWithPoolProps() throws SQLException {\n Driver mockDriver = mock(Driver.class);\n when(DriverManager.getDriver(\"test-url\")).thenReturn(mockDriver);\n when(mockDriver.connect(anyString(), anyObject())).thenReturn(mockConnection);\n\n ...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(ConnectionManager.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(ConnectionManager.class);", "type": "Logger", "var_name": "LOG" }, { ...
{ "body": "public Connection getConnection(String server, String jdbcUrl, Properties connectionConfiguration, boolean isPoolEnabled, Properties poolConfiguration, String qualifier) throws SQLException {\n\n Connection result;\n if (!isPoolEnabled) {\n LOG.debug(\"Requesting DriverManager.getC...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_277
{ "fields": [ { "declarator": "reader", "modifier": "", "original_string": "ChunkReader reader;", "type": "ChunkReader", "var_name": "reader" }, { "declarator": "mockStream", "modifier": "", "original_string": "DFSInputStream mockStream;", "type": "DFS...
{ "body": "@Test\n public void readEmptyFile() throws Exception {\n\t\treader = new ChunkReader(mockStream);\n\t\twhen( mockStream.read( (byte [])Mockito.anyObject()) ).thenReturn(0);\n\n\t\tWritable out = new ChunkWritable();\n\t\tint maxBytesToConsume = 1024*1024;\n\t\tassertEquals(0, reader.readLine(out, maxByt...
{ "fields": [ { "declarator": "DEFAULT_BUFFER_SIZE = 64 * 1024", "modifier": "public static final", "original_string": "public static final int DEFAULT_BUFFER_SIZE = 64 * 1024;", "type": "int", "var_name": "DEFAULT_BUFFER_SIZE" }, { "declarator": "bufferSize = DEFAULT_B...
{ "body": "public int readLine(Writable str, int maxBytesToConsume) throws IOException {\n ChunkWritable cw = (ChunkWritable) str;\n List<Node> list = new LinkedList<Node>();\n\n boolean newLine = false; // length of terminating newline\n long bytesConsumed = 0;\n\n do {\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_332
{ "fields": [ { "declarator": "SQL = \"SELECT id, cdate, amt, grade, b FROM sales\"", "modifier": "private static final", "original_string": "private static final String SQL = \"SELECT id, cdate, amt, grade, b FROM sales\";", "type": "String", "var_name": "SQL" }, { "de...
{ "body": "@Test\n public void testNamedQueryColumnProjection() throws Exception {\n // id = 1\n context.setFilterString(\"a0c20s1d1o5\");\n context.getTupleDescription().get(1).setProjected(false);\n context.getTupleDescription().get(3).setProjected(false);\n context.getTupleDes...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SQLQueryBuilder.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SQLQueryBuilder.class);", "type": "Logger", "var_name": "LOG" }, { "de...
{ "body": "public String buildSelectQuery() {\n StringBuilder sb = new StringBuilder(\"SELECT \")\n .append(buildColumnsQuery())\n .append(\" FROM \")\n .append(getSource());\n\n // Insert regular WHERE constraints\n buildWhereSQL(sb);\n\n // In...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_298
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "resolve...
{ "body": "@Test\n public void testGetFields_Primitive_RepeatedInt() throws IOException {\n List<Type> columns = new ArrayList<>();\n columns.add(new PrimitiveType(Type.Repetition.REPEATED, PrimitiveTypeName.INT32, \"repeatedInt\"));\n schema = new MessageType(\"TestProtobuf.RepeatedIntMessage...
{ "fields": [ { "declarator": "TIMESTAMP_PATTERN = Pattern.compile(\"[+-]\\\\d{2}(:\\\\d{2})?$\")", "modifier": "public static final", "original_string": "public static final Pattern TIMESTAMP_PATTERN = Pattern.compile(\"[+-]\\\\d{2}(:\\\\d{2})?$\");", "type": "Pattern", "var_name": ...
{ "body": "@Override\n public void initialize(RequestContext requestContext) {\n super.initialize(requestContext);\n this.columnDescriptors = context.getTupleDescription();\n }", "class_method_signature": "ParquetResolver.initialize(RequestContext requestContext)", "constructor": false, "ful...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_109
{ "fields": [ { "declarator": "serverName", "modifier": "private", "original_string": "private String serverName;", "type": "String", "var_name": "serverName" }, { "declarator": "configuration", "modifier": "private", "original_string": "private Configuratio...
{ "body": "@Test\n public void testReloginFromKeytabNoopTGTValidForLongTime() throws KerberosAuthException {\n user.setLogin(mockLoginContext);\n PowerMockito.mockStatic(KerberosUtil.class);\n when(KerberosUtil.hasKerberosKeyTab(subject)).thenReturn(true);\n when(KerberosUtil.getKrb5Log...
{ "fields": [ { "declarator": "LOGIN_FAILURE = \"Login failure\"", "modifier": "private static final", "original_string": "private static final String LOGIN_FAILURE = \"Login failure\";", "type": "String", "var_name": "LOGIN_FAILURE" }, { "declarator": "LOG = LoggerFact...
{ "body": "public static void reloginFromKeytab(String serverName, LoginSession loginSession) throws KerberosAuthException {\n\n UserGroupInformation ugi = loginSession.getLoginUser();\n\n if (ugi.getAuthenticationMethod() != UserGroupInformation.AuthenticationMethod.KERBEROS ||\n !ugi.is...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_55
{ "fields": [], "file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/filter/ToStringTreeVisitorTest.java", "identifier": "ToStringTreeVisitorTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testGetStringBuilder() throws Exception {\n String filterString = \"a1c25s10d2016-01-03o4\";\n Node root = new FilterParser().parse(filterString);\n\n ToStringTreeVisitor visitor = new ToStringTreeVisitor();\n new TreeTraverser().traverse(root, visitor);\n...
{ "fields": [ { "declarator": "sb = new StringBuilder()", "modifier": "private final", "original_string": "private final StringBuilder sb = new StringBuilder();", "type": "StringBuilder", "var_name": "sb" } ], "file": "server/pxf-api/src/main/java/org/greenplum/pxf/api/filter...
{ "body": "protected StringBuilder getStringBuilder() {\n return sb;\n }", "class_method_signature": "ToStringTreeVisitor.getStringBuilder()", "constructor": false, "full_signature": "protected StringBuilder getStringBuilder()", "identifier": "getStringBuilder", "invocations": [], "modifiers": "...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_220
{ "fields": [ { "declarator": "parameters", "modifier": "private", "original_string": "private MultivaluedMap<String, String> parameters;", "type": "MultivaluedMap<String, String>", "var_name": "parameters" }, { "declarator": "parser", "modifier": "private", ...
{ "body": "@Test\n public void testWireFormatAndFormatArePresent() {\n // wire format\n parameters.putSingle(\"X-GP-FORMAT\", \"TEXT\");\n // data format\n parameters.putSingle(\"X-GP-OPTIONS-FORMAT\", \"foobar\");\n RequestContext context = parser.parseRequest(mockRequestHeaders...
{ "fields": [ { "declarator": "TRUE_LCASE = \"true\"", "modifier": "private static final", "original_string": "private static final String TRUE_LCASE = \"true\";", "type": "String", "var_name": "TRUE_LCASE" }, { "declarator": "FALSE_LCASE = \"false\"", "modifier":...
{ "body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_365
{ "fields": [], "file": "server/pxf-jdbc/src/test/java/org/greenplum/pxf/plugins/jdbc/utils/HiveJdbcUtilsTest.java", "identifier": "HiveJdbcUtilsTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testImpersonationPropertyAfterHash() throws Exception {\n String url = \"jdbc:hive2://server:10000/default#questionMarkProperty=questionMarkValue;hive.server2.proxy.user=bar\";\n assertEquals(\"jdbc:hive2://server:10000/default;hive.server2.proxy.user=foo#questionMarkPr...
{ "fields": [ { "declarator": "HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\"", "modifier": "private static final", "original_string": "private static final String HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\";", "type": "String", "var_name": "HIVE_UR...
{ "body": "public static String updateImpersonationPropertyInHiveJdbcUrl(String url, String user) {\n String suffix, prefix = null;\n int terminatorIndex = findTerminatorIndex(url, 0, TERMINATORS_TWO_CHARS);\n\n // impersonation property might already be in the URL\n int impersonationPrope...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_43
{ "fields": [ { "declarator": "columnDescriptors", "modifier": "private", "original_string": "private List<ColumnDescriptor> columnDescriptors;", "type": "List<ColumnDescriptor>", "var_name": "columnDescriptors" }, { "declarator": "treeTraverser", "modifier": "pri...
{ "body": "@Test\n public void testGetColumnDescriptors() {\n ColumnPredicateBuilder columnPredicateBuilder = new ColumnPredicateBuilder(columnDescriptors);\n assertSame(columnDescriptors, columnPredicateBuilder.getColumnDescriptors());\n }", "class_method_signature": "ColumnPredicateBuilderTest...
{ "fields": [ { "declarator": "quoteString", "modifier": "private final", "original_string": "private final String quoteString;", "type": "String", "var_name": "quoteString" }, { "declarator": "columnDescriptors", "modifier": "private final", "original_strin...
{ "body": "protected List<ColumnDescriptor> getColumnDescriptors() {\n return columnDescriptors;\n }", "class_method_signature": "ColumnPredicateBuilder.getColumnDescriptors()", "constructor": false, "full_signature": "protected List<ColumnDescriptor> getColumnDescriptors()", "identifier": "getColum...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_236
{ "fields": [ { "declarator": "PRUNER = new SupportedOperatorPruner(SUPPORTED_OPERATORS)", "modifier": "private static final", "original_string": "private static final TreeVisitor PRUNER = new SupportedOperatorPruner(SUPPORTED_OPERATORS);", "type": "TreeVisitor", "var_name": "PRUNER"...
{ "body": "@Test\n public void testFilterWithIncompatiblePredicate() throws Exception {\n // ((_1_ LIKE row1 AND _2_ < 999) AND _1_ = seq)\n Filter filter = helper(\"a1c25s4drow1o7a2c23s3d999o1l0a1c25s3dseqo5l0\", tupleDescription);\n assertNotNull(filter);\n assertTrue(filter instanceo...
{ "fields": [ { "declarator": "OPERATORS_MAP =\n Collections.unmodifiableMap(new HashMap<Operator, CompareFilter.CompareOp>() {{\n put(Operator.LESS_THAN, CompareFilter.CompareOp.LESS); // \"<\"\n put(Operator.GREATER_THAN, CompareFilter.CompareOp.GREATER); // \">\"\...
{ "body": "private ByteArrayComparable getComparator(int type, OperandNode data) {\n ByteArrayComparable result;\n switch (DataType.get(type)) {\n case TEXT:\n result = new BinaryComparator(Bytes.toBytes(data.toString()));\n break;\n case SMALLINT:\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_373
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "dbProdu...
{ "body": "@Test\n public void testLeftBoundedInclusive() {\n IntPartition partition = new IntPartition(COL_RAW, 0L, null);\n String constraint = partition.toSqlConstraint(QUOTE, dbProduct);\n\n assertEquals(COL + \" >= 0\", constraint);\n }", "class_method_signature": "IntPartitionTest.t...
{ "fields": [ { "declarator": "serialVersionUID = 0L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 0L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "boundaries", "modifier": "private f...
{ "body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n\n return generateRangeConstraint(\n quoteString + column + quoteString,\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_148
{ "fields": [ { "declarator": "mockContext", "modifier": "", "original_string": "RequestContext mockContext;", "type": "RequestContext", "var_name": "mockContext" }, { "declarator": "inputBuilder", "modifier": "", "original_string": "BridgeInputBuilder input...
{ "body": "@Test\n /*\n * Test makeInput method: small \\n terminated input\n */\n public void makeInput() throws Exception {\n\n byte[] data = new byte[]{\n (int) 'a',\n (int) 'b',\n (int) 'c',\n (int) 'd',\n (int) '\\n',...
{ "fields": [ { "declarator": "protocolData", "modifier": "private final", "original_string": "private final RequestContext protocolData;", "type": "RequestContext", "var_name": "protocolData" }, { "declarator": "LOG = LogFactory.getLog(BridgeInputBuilder.class)", ...
{ "body": "public List<OneField> makeInput(DataInput inputStream) throws Exception {\n if (protocolData.getOutputFormat() == OutputFormat.TEXT) {\n // Avoid copying the bytes from the inputStream directly. This\n // code used to use the Text class to read bytes until a line\n /...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_14
{ "fields": [], "file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/model/BasePluginTest.java", "identifier": "BasePluginTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testDefaults() {\n BasePlugin basePlugin = new BasePlugin();\n assertFalse(basePlugin.isInitialized());\n }", "class_method_signature": "BasePluginTest.testDefaults()", "constructor": false, "full_signature": "@Test public void testDefaults()", "identifier": ...
{ "fields": [ { "declarator": "configurationFactory", "modifier": "protected", "original_string": "protected ConfigurationFactory configurationFactory;", "type": "ConfigurationFactory", "var_name": "configurationFactory" }, { "declarator": "LOG = LoggerFactory.getLogger...
{ "body": "public final boolean isInitialized() {\n return initialized;\n }", "class_method_signature": "BasePlugin.isInitialized()", "constructor": false, "full_signature": "public final boolean isInitialized()", "identifier": "isInitialized", "invocations": [], "modifiers": "public final", "...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_261
{ "fields": [ { "declarator": "context", "modifier": "private", "original_string": "private RequestContext context;", "type": "RequestContext", "var_name": "context" }, { "declarator": "schema", "modifier": "private", "original_string": "private Schema schem...
{ "body": "@Test\n public void testObtainSchema_OnWrite_WithUserProvidedSchema_Binary_FullPathToLocalFile_Spaces() {\n context.setRequestType(RequestContext.RequestType.WRITE_BRIDGE);\n context.addOption(\"SCHEMA\", avroDirectory + \"user provided.avro\");\n\n schema = avroUtilities.obtainSche...
{ "fields": [ { "declarator": "COMMON_NAMESPACE = \"public.avro\"", "modifier": "private static", "original_string": "private static String COMMON_NAMESPACE = \"public.avro\";", "type": "String", "var_name": "COMMON_NAMESPACE" }, { "declarator": "fileSearcher", "m...
{ "body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_324
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void getDelimiterCode() {\n\n //Default delimiter code should be 44(comma)\n Integer delimiterCode = hiveClientWrapper.getDelimiterCode(null);\n char defaultDelim = ',';\n assertEquals((int) delimiterCode, (int) defaultDelim);\n\n //Some serdes use FIELD...
{ "fields": [ { "declarator": "instance = new HiveClientWrapper()", "modifier": "private static final", "original_string": "private static final HiveClientWrapper instance = new HiveClientWrapper();", "type": "HiveClientWrapper", "var_name": "instance" }, { "declarator"...
{ "body": "public Integer getDelimiterCode(StorageDescriptor sd) {\n Integer delimiterCode;\n\n String delimiter = getSerdeParameter(sd, serdeConstants.FIELD_DELIM);\n if (delimiter != null) {\n delimiterCode = (int) delimiter.charAt(0);\n return delimiterCode;\n }\n\...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_353
{ "fields": [], "file": "server/pxf-jdbc/src/test/java/org/greenplum/pxf/plugins/jdbc/utils/HiveJdbcUtilsTest.java", "identifier": "HiveJdbcUtilsTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testURLWithoutImpersonationPropertyAndWithHash() throws Exception {\n String url = \"jdbc:hive2://server:10000/default;foo=bar;saslQop=auth-conf#hive.property=value\";\n assertEquals(\"jdbc:hive2://server:10000/default;foo=bar;saslQop=auth-conf;hive.server2.proxy.user=f...
{ "fields": [ { "declarator": "HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\"", "modifier": "private static final", "original_string": "private static final String HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\";", "type": "String", "var_name": "HIVE_UR...
{ "body": "public static String updateImpersonationPropertyInHiveJdbcUrl(String url, String user) {\n String suffix, prefix = null;\n int terminatorIndex = findTerminatorIndex(url, 0, TERMINATORS_TWO_CHARS);\n\n // impersonation property might already be in the URL\n int impersonationPrope...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_216
{ "fields": [ { "declarator": "parameters", "modifier": "private", "original_string": "private MultivaluedMap<String, String> parameters;", "type": "MultivaluedMap<String, String>", "var_name": "parameters" }, { "declarator": "parser", "modifier": "private", ...
{ "body": "@Test\n public void testWireFormatIsAbsent() {\n RequestContext context = parser.parseRequest(mockRequestHeaders, RequestType.FRAGMENTER);\n assertEquals(OutputFormat.TEXT, context.getOutputFormat());\n assertNull(context.getFormat());\n }", "class_method_signature": "HttpReque...
{ "fields": [ { "declarator": "TRUE_LCASE = \"true\"", "modifier": "private static final", "original_string": "private static final String TRUE_LCASE = \"true\";", "type": "String", "var_name": "TRUE_LCASE" }, { "declarator": "FALSE_LCASE = \"false\"", "modifier":...
{ "body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_63
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" } ], "file": "server/pxf-api/src/...
{ "body": "@Test\n public void testPruningLeftNodeDuringBefore() {\n Node root = new Node();\n Node left = new Node();\n root.setLeft(left);\n TreeVisitor visitor = mock(TreeVisitor.class);\n\n // l0\n // |\n // -----------\n //...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(TreeTraverser.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(TreeTraverser.class);", "type": "Logger", "var_name": "LOG" } ], "file": "serv...
{ "body": "public Node traverse(Node node, TreeVisitor... visitors) {\n\n if (ArrayUtils.isEmpty(visitors)) {\n throw new IllegalArgumentException(\"You need to provide at least one visitor for this traverser\");\n }\n\n Node result = node;\n for (TreeVisitor visitor : visitors)...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_304
{ "fields": [ { "declarator": "fragmenter", "modifier": "private", "original_string": "private Fragmenter fragmenter;", "type": "Fragmenter", "var_name": "fragmenter" }, { "declarator": "context", "modifier": "private", "original_string": "private RequestCon...
{ "body": "@Test\n public void testInvalidInputPathIgnored() throws Exception {\n context.addOption(\"IGNORE_MISSING_PATH\", \"true\");\n context.setDataSource(\"/tmp/non-existent-path-on-disk/*.csv\");\n\n fragmenter.initialize(context);\n\n List<Fragment> fragmentList = fragmenter.get...
{ "fields": [], "file": "server/pxf-hdfs/src/main/java/org/greenplum/pxf/plugins/hdfs/HdfsFileFragmenter.java", "identifier": "HdfsFileFragmenter", "interfaces": "", "methods": [ { "class_method_signature": "HdfsFileFragmenter.HdfsFileFragmenter()", "constructor": true, "full_signature":...
{ "body": "@Override\n public List<Fragment> getFragments() throws Exception {\n String fileName = hcfsType.getDataUri(jobConf, context);\n Path path = new Path(fileName);\n\n PxfInputFormat pxfInputFormat = new PxfInputFormat();\n PxfInputFormat.setInputPaths(jobConf, path);\n\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_241
{ "fields": [ { "declarator": "context", "modifier": "private", "original_string": "private RequestContext context;", "type": "RequestContext", "var_name": "context" }, { "declarator": "schema", "modifier": "private", "original_string": "private Schema schem...
{ "body": "@Test\n public void testObtainSchema_OnRead_WithUserProvidedSchema_Json_HCFS() {\n avroUtilities = new AvroUtilities((file) -> dontFindLocalFile());\n context.setRequestType(RequestContext.RequestType.READ_BRIDGE);\n context.addOption(\"SCHEMA\", avroDirectory + \"user-provided.avsc...
{ "fields": [ { "declarator": "COMMON_NAMESPACE = \"public.avro\"", "modifier": "private static", "original_string": "private static String COMMON_NAMESPACE = \"public.avro\";", "type": "String", "var_name": "COMMON_NAMESPACE" }, { "declarator": "fileSearcher", "m...
{ "body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_168
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n @SuppressWarnings(\"unchecked\")\n public void cleansUGICacheWhenTheFilterExecutionThrowsAnUndeclaredThrowableException() throws Exception {\n expectedException.expect(ServletException.class);\n expectScenario(false, false, false);\n doThrow(UndeclaredThrowableException.c...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);", "type": "Logger", "var_name": "LOG" }, ...
{ "body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_34
{ "fields": [ { "declarator": "gpCSV", "modifier": "private", "original_string": "private GreenplumCSV gpCSV;", "type": "GreenplumCSV", "var_name": "gpCSV" }, { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_str...
{ "body": "@Test\n public void testToCsvDoesNotAddPrefixAndSuffixWhenSkipIfQuotingIsNotNeeded() {\n String input = \"aábcdefghijklmnñopqrstuvwxyz\";\n\n assertSame(input, gpCSV.toCsvField(input, false, false, true));\n assertSame(input, gpCSV.toCsvField(input, false, true, true));\n ass...
{ "fields": [ { "declarator": "QUOTE = '\"'", "modifier": "private static final", "original_string": "private static final char QUOTE = '\"';", "type": "char", "var_name": "QUOTE" }, { "declarator": "ESCAPE = '\"'", "modifier": "private static final", "origi...
{ "body": "public String toCsvField(String s, boolean prependQuoteChar, boolean appendQuoteChar) {\n return toCsvField(s, prependQuoteChar, appendQuoteChar, false);\n }", "class_method_signature": "GreenplumCSV.toCsvField(String s, boolean prependQuoteChar, boolean appendQuoteChar)", "constructor": fals...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_187
{ "fields": [ { "declarator": "response = null", "modifier": "", "original_string": "MetadataResponse response = null;", "type": "MetadataResponse", "var_name": "response" } ], "file": "server/pxf-service/src/test/java/org/greenplum/pxf/service/MetadataResponseFormatterTest.j...
{ "body": "@Test\n public void formatResponseString() throws Exception {\n List<Metadata> metadataList = new ArrayList<Metadata>();\n List<Metadata.Field> fields = new ArrayList<Metadata.Field>();\n Metadata.Item itemName = new Metadata.Item(\"default\", \"table1\");\n Metadata metadata...
{ "fields": [ { "declarator": "LOG = LogFactory.getLog(MetadataResponseFormatter.class)", "modifier": "private static final", "original_string": "private static final Log LOG = LogFactory.getLog(MetadataResponseFormatter.class);", "type": "Log", "var_name": "LOG" } ], "file":...
{ "body": "public static MetadataResponse formatResponse(List<Metadata> metadataList, String path) throws IOException {\n /* print the fragment list to log when in debug level */\n if (LOG.isDebugEnabled()) {\n MetadataResponseFormatter.printMetadata(metadataList, path);\n }\n\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_312
{ "fields": [ { "declarator": "hiveColumn", "modifier": "", "original_string": "FieldSchema hiveColumn;", "type": "FieldSchema", "var_name": "hiveColumn" }, { "declarator": "typesMappings = {\n /* hive type -> gpdb type */\n {\"tinyint\", \"int2\"}...
{ "body": "@Test\n public void mapHiveTypeUnsupported() throws Exception {\n\n hiveColumn = new FieldSchema(\"complex\", \"someTypeWeDontSupport\", null);\n\n try {\n HiveUtilities.mapHiveType(hiveColumn);\n fail(\"unsupported type\");\n } catch (UnsupportedTypeException ...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(HiveUtilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(HiveUtilities.class);", "type": "Logger", "var_name": "LOG" } ], "file": "serv...
{ "body": "public static Metadata.Field mapHiveType(FieldSchema hiveColumn) throws UnsupportedTypeException {\n String fieldName = hiveColumn.getName();\n String hiveType = hiveColumn.getType(); // Type name and modifiers if any\n String hiveTypeName; // Type name\n String[] modifiers = nu...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_257
{ "fields": [ { "declarator": "context", "modifier": "private", "original_string": "private RequestContext context;", "type": "RequestContext", "var_name": "context" }, { "declarator": "schema", "modifier": "private", "original_string": "private Schema schem...
{ "body": "@Test\n public void testObtainSchema_OnWrite_WithUserProvidedSchema_Binary_HCFS_Spaces() {\n avroUtilities = new AvroUtilities((file) -> dontFindLocalFile());\n context.setRequestType(RequestContext.RequestType.WRITE_BRIDGE);\n context.addOption(\"SCHEMA\", avroDirectory + \"user pr...
{ "fields": [ { "declarator": "COMMON_NAMESPACE = \"public.avro\"", "modifier": "private static", "original_string": "private static String COMMON_NAMESPACE = \"public.avro\";", "type": "String", "var_name": "COMMON_NAMESPACE" }, { "declarator": "fileSearcher", "m...
{ "body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_22
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "context...
{ "body": "@Test\n public void testStatsSampleRatioFailsOnZero() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Wrong value '0.0'. STATS-SAMPLE-RATIO must be a value between 0.0001 and 1.0\");\n context.setStatsSampleRatio(0);\n }", "class_method_signature": "...
{ "fields": [ { "declarator": "requestType", "modifier": "private", "original_string": "private RequestType requestType;", "type": "RequestType", "var_name": "requestType" }, { "declarator": "accessor", "modifier": "private", "original_string": "private Stri...
{ "body": "public void setStatsSampleRatio(float statsSampleRatio) {\n this.statsSampleRatio = statsSampleRatio;\n if (statsSampleRatio < 0.0001 || statsSampleRatio > 1.0) {\n throw new IllegalArgumentException(\n \"Wrong value '\"\n + statsSample...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_191
{ "fields": [ { "declarator": "response = null", "modifier": "", "original_string": "MetadataResponse response = null;", "type": "MetadataResponse", "var_name": "response" } ], "file": "server/pxf-service/src/test/java/org/greenplum/pxf/service/MetadataResponseFormatterTest.j...
{ "body": "@Test\n public void formatResponseStringNull() throws Exception {\n List<Metadata> metadataList = null;\n response = MetadataResponseFormatter.formatResponse(metadataList, \"path.file\");\n String expected = new String(\"{\\\"PXFMetadata\\\":[]}\");\n\n assertEquals(expected,...
{ "fields": [ { "declarator": "LOG = LogFactory.getLog(MetadataResponseFormatter.class)", "modifier": "private static final", "original_string": "private static final Log LOG = LogFactory.getLog(MetadataResponseFormatter.class);", "type": "Log", "var_name": "LOG" } ], "file":...
{ "body": "public static MetadataResponse formatResponse(List<Metadata> metadataList, String path) throws IOException {\n /* print the fragment list to log when in debug level */\n if (LOG.isDebugEnabled()) {\n MetadataResponseFormatter.printMetadata(metadataList, path);\n }\n\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_345
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testMaskPassword () {\n assertEquals(\"********\", ConnectionManager.maskPassword(\"12345678\"));\n assertEquals(\"\", ConnectionManager.maskPassword(\"\"));\n assertEquals(\"\", ConnectionManager.maskPassword(null));\n }", "class_method_signature": "Connect...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(ConnectionManager.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(ConnectionManager.class);", "type": "Logger", "var_name": "LOG" }, { ...
{ "body": "public static String maskPassword(String password) {\n return password == null ? \"\" : StringUtils.repeat(\"*\", password.length());\n }", "class_method_signature": "ConnectionManager.maskPassword(String password)", "constructor": false, "full_signature": "public static String maskPassword...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_200
{ "fields": [ { "declarator": "parameters", "modifier": "private", "original_string": "private MultivaluedMap<String, String> parameters;", "type": "MultivaluedMap<String, String>", "var_name": "parameters" }, { "declarator": "parser", "modifier": "private", ...
{ "body": "@Test\n public void undefinedServer() {\n parameters.remove(\"X-GP-OPTIONS-SERVER\");\n RequestContext context = parser.parseRequest(mockRequestHeaders, RequestType.FRAGMENTER);\n assertEquals(\"default\", context.getServerName());\n }", "class_method_signature": "HttpRequestPa...
{ "fields": [ { "declarator": "TRUE_LCASE = \"true\"", "modifier": "private static final", "original_string": "private static final String TRUE_LCASE = \"true\";", "type": "String", "var_name": "TRUE_LCASE" }, { "declarator": "FALSE_LCASE = \"false\"", "modifier":...
{ "body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_129
{ "fields": [ { "declarator": "MINUTES = 60 * 1000L", "modifier": "private static final", "original_string": "private static final long MINUTES = 60 * 1000L;", "type": "long", "var_name": "MINUTES" }, { "declarator": "provider = null", "modifier": "private", ...
{ "body": "@Test\n public void getTwoUGIsWithDifferentTransactionsForSameUser() throws Exception {\n SessionId otherSession = new SessionId(0, \"txn-id-2\", \"the-user\", \"default\", false, UserGroupInformation.getLoginUser());\n UserGroupInformation ugi1 = cache.getUserGroupInformation(session, fal...
{ "fields": [ { "declarator": "NANOS_PER_MILLIS = 1000000", "modifier": "static final", "original_string": "static final int NANOS_PER_MILLIS = 1000000;", "type": "int", "var_name": "NANOS_PER_MILLIS" }, { "declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L", "modif...
{ "body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_75
{ "fields": [ { "declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"", "modifier": "private", "original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";", "type": "String", "var_name": "PROPERTY_KEY_...
{ "body": "@Test\n public void byteArrayToOctalStringNull() throws Exception {\n StringBuilder sb = null;\n byte[] bytes = \"nofink\".getBytes();\n\n Utilities.byteArrayToOctalString(bytes, sb);\n\n assertNull(sb);\n\n sb = new StringBuilder();\n bytes = null;\n\n U...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(Utilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);", "type": "Logger", "var_name": "LOG" }, { "declarator": "...
{ "body": "public static void byteArrayToOctalString(byte[] bytes, StringBuilder sb) {\n if ((bytes == null) || (sb == null)) {\n return;\n }\n\n sb.ensureCapacity(sb.length()\n + (bytes.length * 5 /* characters per byte */));\n for (int b : bytes) {\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_294
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "resolve...
{ "body": "@Test\n public void testGetFields_Primitive() throws IOException {\n schema = getParquetSchemaForPrimitiveTypes(Type.Repetition.OPTIONAL, true);\n // schema has changed, set metadata again\n context.setMetadata(schema);\n context.setTupleDescription(getColumnDescriptorsFromSc...
{ "fields": [ { "declarator": "TIMESTAMP_PATTERN = Pattern.compile(\"[+-]\\\\d{2}(:\\\\d{2})?$\")", "modifier": "public static final", "original_string": "public static final Pattern TIMESTAMP_PATTERN = Pattern.compile(\"[+-]\\\\d{2}(:\\\\d{2})?$\");", "type": "Pattern", "var_name": ...
{ "body": "@Override\n public void initialize(RequestContext requestContext) {\n super.initialize(requestContext);\n this.columnDescriptors = context.getTupleDescription();\n }", "class_method_signature": "ParquetResolver.initialize(RequestContext requestContext)", "constructor": false, "ful...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_152
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void throwsWhenRequiredUserIdHeaderIsEmpty() throws Exception {\n expectedException.expect(IllegalArgumentException.class);\n expectedException.expectMessage(\"Header X-GP-USER is empty in the request\");\n when(mockServletRequest.getHeader(\"X-GP-USER\")).thenReturn(...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);", "type": "Logger", "var_name": "LOG" }, ...
{ "body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_386
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "dbProdu...
{ "body": "@Test\n public void testSpecialDateValue() {\n DatePartition partition = new DatePartition(COL_RAW, LocalDate.parse(\"0001-01-01\"), LocalDate.parse(\"1970-01-02\"));\n String constraint = partition.toSqlConstraint(QUOTE, dbProduct);\n\n assertEquals(\n COL + \" >= da...
{ "fields": [ { "declarator": "serialVersionUID = 0L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 0L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "boundaries", "modifier": "private f...
{ "body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n if (dbProduct == null) {\n throw new RuntimeException(String.format(\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_369
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "dbProdu...
{ "body": "@Test\n public void testNormal() {\n IntPartition partition = new IntPartition(COL_RAW, 0L, 1L);\n String constraint = partition.toSqlConstraint(QUOTE, dbProduct);\n\n assertEquals(COL + \" >= 0 AND \" + COL + \" < 1\", constraint);\n }", "class_method_signature": "IntPartition...
{ "fields": [ { "declarator": "serialVersionUID = 0L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 0L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "boundaries", "modifier": "private f...
{ "body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n\n return generateRangeConstraint(\n quoteString + column + quoteString,\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_410
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" } ], "file": "server/pxf-s3/src/t...
{ "body": "@Test\n public void testFailsOnOpenForWrite() {\n thrown.expect(UnsupportedOperationException.class);\n thrown.expectMessage(\"S3 Select does not support writing\");\n new S3SelectAccessor().openForWrite();\n }", "class_method_signature": "S3SelectAccessorTest.testFailsOnOpenFo...
{ "fields": [ { "declarator": "COMPRESSION_TYPE = \"COMPRESSION_CODEC\"", "modifier": "public static final", "original_string": "public static final String COMPRESSION_TYPE = \"COMPRESSION_CODEC\";", "type": "String", "var_name": "COMPRESSION_TYPE" }, { "declarator": "F...
{ "body": "@Override\n public boolean openForWrite() {\n throw new UnsupportedOperationException(\"S3 Select does not support writing\");\n }", "class_method_signature": "S3SelectAccessor.openForWrite()", "constructor": false, "full_signature": "@Override public boolean openForWrite()", "identifi...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_59
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" } ], "file": "server/pxf-api/src/...
{ "body": "@Test\n public void testChainingVisitors() {\n TreeVisitor visitor1 = mock(TreeVisitor.class);\n TreeVisitor visitor2 = mock(TreeVisitor.class);\n TreeVisitor visitor3 = mock(TreeVisitor.class);\n\n Node l0 = new Node();\n l0.setLeft(new Node());\n l0.setRight(n...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(TreeTraverser.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(TreeTraverser.class);", "type": "Logger", "var_name": "LOG" } ], "file": "serv...
{ "body": "public Node traverse(Node node, TreeVisitor... visitors) {\n\n if (ArrayUtils.isEmpty(visitors)) {\n throw new IllegalArgumentException(\"You need to provide at least one visitor for this traverser\");\n }\n\n Node result = node;\n for (TreeVisitor visitor : visitors)...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_105
{ "fields": [ { "declarator": "session", "modifier": "private", "original_string": "private LoginSession session, sessionFoo, sessionBar;", "type": "LoginSession", "var_name": "session" }, { "declarator": "ugiFoo", "modifier": "private", "original_string": "...
{ "body": "@Test\n public void testToString() {\n session = new LoginSession(\"config\", \"principal\", \"keytab\", ugiFoo, subjectFoo, 1);\n assertEquals(\"LoginSession[config=config,principal=principal,keytab=keytab,kerberosMinMillisBeforeRelogin=1]\", session.toString());\n }", "class_method_...
{ "fields": [ { "declarator": "configDirectory", "modifier": "private", "original_string": "private String configDirectory;", "type": "String", "var_name": "configDirectory" }, { "declarator": "principalName", "modifier": "private", "original_string": "priva...
{ "body": "@Override\n public String toString() {\n return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)\n .append(\"config\", configDirectory)\n .append(\"principal\", principalName)\n .append(\"keytab\", keytabPath)\n .append(\"kerb...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_390
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "context...
{ "body": "@Test\n public void testPartitionByFormatInvalid() {\n thrown.expect(IllegalArgumentException.class);\n\n context.addOption(\"PARTITION_BY\", \"level-enum\");\n new JdbcPartitionFragmenter().initialize(context);\n }", "class_method_signature": "JdbcPartitionFragmenterTest.testP...
{ "fields": [ { "declarator": "pxfHosts = {\"localhost\"}", "modifier": "private static final", "original_string": "private static final String[] pxfHosts = {\"localhost\"};", "type": "String[]", "var_name": "pxfHosts" }, { "declarator": "partitionType", "modifier...
{ "body": "@Override\n public void initialize(RequestContext context) {\n super.initialize(context);\n\n String partitionByOption = context.getOption(\"PARTITION_BY\");\n if (partitionByOption == null) return;\n\n try {\n String[] partitionBy = partitionByOption.split(\":\");...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_406
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" } ], "file": "server/pxf-s3/src/t...
{ "body": "@Test\n public void testQuoteEscapeCharacter() {\n RequestContext context = getDefaultRequestContext();\n context.addOption(\"ESCAPE\", \"\\\"\");\n InputSerialization inputSerialization =\n new S3SelectAccessor().getInputSerialization(context);\n assertEquals(...
{ "fields": [ { "declarator": "COMPRESSION_TYPE = \"COMPRESSION_CODEC\"", "modifier": "public static final", "original_string": "public static final String COMPRESSION_TYPE = \"COMPRESSION_CODEC\";", "type": "String", "var_name": "COMPRESSION_TYPE" }, { "declarator": "F...
{ "body": "InputSerialization getInputSerialization(RequestContext context) {\n InputSerialization inputSerialization = new InputSerialization();\n\n // We need to infer the format name from the profile (i.e. s3:parquet\n // would return parquet for the format)\n String format = context.in...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_113
{ "fields": [ { "declarator": "serverName", "modifier": "private", "original_string": "private String serverName;", "type": "String", "var_name": "serverName" }, { "declarator": "configuration", "modifier": "private", "original_string": "private Configuratio...
{ "body": "@Test\n public void testReloginFromKeytabValidTGTWillExpireSoon() throws Exception {\n user.setLogin(mockLoginContext);\n PowerMockito.mockStatic(KerberosUtil.class);\n when(KerberosUtil.hasKerberosKeyTab(subject)).thenReturn(true);\n when(KerberosUtil.getKrb5LoginModuleName(...
{ "fields": [ { "declarator": "LOGIN_FAILURE = \"Login failure\"", "modifier": "private static final", "original_string": "private static final String LOGIN_FAILURE = \"Login failure\";", "type": "String", "var_name": "LOGIN_FAILURE" }, { "declarator": "LOG = LoggerFact...
{ "body": "public static void reloginFromKeytab(String serverName, LoginSession loginSession) throws KerberosAuthException {\n\n UserGroupInformation ugi = loginSession.getLoginUser();\n\n if (ugi.getAuthenticationMethod() != UserGroupInformation.AuthenticationMethod.KERBEROS ||\n !ugi.is...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_328
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void getTableMetadataWithMultipleTables() throws Exception {\n\n fetcher = new HiveMetadataFetcher(context, mockConfigurationFactory, fakeHiveClientWrapper);\n\n String tablePattern = \"*\";\n String dbPattern = \"*\";\n String dbName = \"default\";\n St...
{ "fields": [ { "declarator": "DELIM_FIELD = \"DELIMITER\"", "modifier": "private static final", "original_string": "private static final String DELIM_FIELD = \"DELIMITER\";", "type": "String", "var_name": "DELIM_FIELD" }, { "declarator": "LOG = LogFactory.getLog(HiveMe...
{ "body": "@Override\n public List<Metadata> getMetadata(String pattern) throws Exception {\n\n boolean ignoreErrors = false;\n List<Metadata.Item> tblsDesc = hiveClientWrapper.extractTablesFromPattern(client, pattern);\n\n if (tblsDesc == null || tblsDesc.isEmpty()) {\n LOG.warn(\"...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_282
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testReadFromEmptyFileFileAsRow() throws Exception {\n prepareTest(\"csv/empty.csv\", true);\n\n OneRow oneRow = accessor.readNextObject();\n assertNull(oneRow);\n }", "class_method_signature": "QuotedLineBreakAccessorTest.testReadFromEmptyFileFileAsRow()", ...
{ "fields": [ { "declarator": "fileAsRow", "modifier": "private", "original_string": "private boolean fileAsRow;", "type": "boolean", "var_name": "fileAsRow" }, { "declarator": "firstLine", "modifier": "private", "original_string": "private boolean firstLine...
{ "body": "@Override\n public OneRow readNextObject() throws IOException {\n if (super.readNextObject() == null) /* check if working segment */ {\n return null;\n }\n\n String nextLine = readLine();\n if (nextLine == null) /* EOF */ {\n return null;\n }\n\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_6
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "factory...
{ "body": "@Test\n public void testConfigurationsLoadedFromMultipleFilesForDefaultServerWithCustomName() {\n Configuration configuration = factory.initConfiguration(\"default\", \"my-fancy-server-name\", \"dummy\", null);\n\n assertEquals(\"blue\", configuration.get(\"test.blue\"));\n assertEq...
{ "fields": [ { "declarator": "instance = new BaseConfigurationFactory()", "modifier": "private static final", "original_string": "private static final BaseConfigurationFactory instance = new BaseConfigurationFactory();", "type": "BaseConfigurationFactory", "var_name": "instance" ...
{ "body": "@Override\n public Configuration initConfiguration(String configDirectory, String serverName, String userName, Map<String, String> additionalProperties) {\n // start with built-in Hadoop configuration that loads core-site.xml\n LOG.debug(\"Initializing configuration for server {}\", server...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_18
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "context...
{ "body": "@Test\n public void testInvalidServerName() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Invalid server name 'foo,bar'\");\n context.setServerName(\"foo,bar\");\n }", "class_method_signature": "RequestContextTest.testInvalidServerName()", "const...
{ "fields": [ { "declarator": "requestType", "modifier": "private", "original_string": "private RequestType requestType;", "type": "RequestType", "var_name": "requestType" }, { "declarator": "accessor", "modifier": "private", "original_string": "private Stri...
{ "body": "public void setServerName(String serverName) {\n if (StringUtils.isNotBlank(serverName)) {\n\n if (!Utilities.isValidRestrictedDirectoryName(serverName)) {\n throw new IllegalArgumentException(String.format(\"Invalid server name '%s'\", serverName));\n }\n\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_144
{ "fields": [ { "declarator": "UN_SUPPORTED_TYPE = -1", "modifier": "private static final", "original_string": "private static final int UN_SUPPORTED_TYPE = -1;", "type": "int", "var_name": "UN_SUPPORTED_TYPE" }, { "declarator": "output = null", "modifier": "priva...
{ "body": "@Test\n public void testFillGPDBWritable() throws Exception {\n RequestContext context = new RequestContext();\n\n addColumn(context, 0, DataType.INTEGER, \"col0\");\n addColumn(context, 1, DataType.FLOAT8, \"col1\");\n addColumn(context, 2, DataType.REAL, \"col2\");\n ...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(BridgeOutputBuilder.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(BridgeOutputBuilder.class);", "type": "Logger", "var_name": "LOG" }, { ...
{ "body": "void fillGPDBWritable(List<OneField> recFields) throws BadRecordException {\n int size = recFields.size();\n if (size == 0) { // size 0 means the resolver couldn't deserialize any\n // of the record fields\n throw new BadRecordException(\"No fields in record\");\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_266
{ "fields": [ { "declarator": "context", "modifier": "private", "original_string": "private RequestContext context;", "type": "RequestContext", "var_name": "context" }, { "declarator": "schema", "modifier": "private", "original_string": "private Schema schem...
{ "body": "@Test\n public void testObtainSchema_OnWrite_WithUserProvidedSchema_Json_OnClasspath() {\n context.setRequestType(RequestContext.RequestType.WRITE_BRIDGE);\n context.addOption(\"SCHEMA\", \"avro/user-provided.avsc\");\n\n schema = avroUtilities.obtainSchema(context, configuration, h...
{ "fields": [ { "declarator": "COMMON_NAMESPACE = \"public.avro\"", "modifier": "private static", "original_string": "private static String COMMON_NAMESPACE = \"public.avro\";", "type": "String", "var_name": "COMMON_NAMESPACE" }, { "declarator": "fileSearcher", "m...
{ "body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_289
{ "fields": [ { "declarator": "LOG", "modifier": "", "original_string": "Log LOG;", "type": "Log", "var_name": "LOG" }, { "declarator": "recordkeyAdapter", "modifier": "", "original_string": "RecordkeyAdapter recordkeyAdapter;", "type": "RecordkeyAdapt...
{ "body": "@Test\n public void convertKeyValueBadSecondValue() {\n boolean key = true;\n initRecordkeyAdapter();\n runConvertKeyValue(key, new BooleanWritable(key));\n String badKey = \"bad\";\n try {\n recordkeyAdapter.convertKeyValue(badKey);\n fail(\"conv...
{ "fields": [ { "declarator": "LOG = LogFactory.getLog(RecordkeyAdapter.class)", "modifier": "private static final", "original_string": "private static final Log LOG = LogFactory.getLog(RecordkeyAdapter.class);", "type": "Log", "var_name": "LOG" }, { "declarator": "extr...
{ "body": "public Writable convertKeyValue(Object key) {\n if (converter == null) {\n converter = initializeConverter(key);\n LOG.debug(\"converter initialized for type \" + key.getClass()\n + \" (key value: \" + key + \")\");\n }\n\n return converter.get(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_323
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void parseTableQualifiedName() {\n String name = \"not.orphan\";\n tblDesc = hiveClientWrapper.extractTableFromName(name);\n\n assertEquals(\"not\", tblDesc.getPath());\n assertEquals(\"orphan\", tblDesc.getName());\n }", "class_method_signature": "HiveCli...
{ "fields": [ { "declarator": "instance = new HiveClientWrapper()", "modifier": "private static final", "original_string": "private static final HiveClientWrapper instance = new HiveClientWrapper();", "type": "HiveClientWrapper", "var_name": "instance" }, { "declarator"...
{ "body": "public Metadata.Item extractTableFromName(String qualifiedName) {\n List<Metadata.Item> items = extractTablesFromPattern(null, qualifiedName);\n if (items.isEmpty()) {\n throw new IllegalArgumentException(\"No tables found\");\n }\n return items.get(0);\n }", "cl...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_13
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "factory...
{ "body": "@Test\n public void testConfigurationSetsSessionUser() throws IOException {\n Configuration configuration = factory.initConfiguration(\"default\", \"default\", \"dummy\", additionalProperties);\n File defaultServerDirectory = new File(serversDirectory, \"default\");\n\n assertEquals...
{ "fields": [ { "declarator": "instance = new BaseConfigurationFactory()", "modifier": "private static final", "original_string": "private static final BaseConfigurationFactory instance = new BaseConfigurationFactory();", "type": "BaseConfigurationFactory", "var_name": "instance" ...
{ "body": "@Override\n public Configuration initConfiguration(String configDirectory, String serverName, String userName, Map<String, String> additionalProperties) {\n // start with built-in Hadoop configuration that loads core-site.xml\n LOG.debug(\"Initializing configuration for server {}\", server...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_231
{ "fields": [ { "declarator": "tableName = \"fishy_HBase_table\"", "modifier": "static final", "original_string": "static final String tableName = \"fishy_HBase_table\";", "type": "String", "var_name": "tableName" }, { "declarator": "context", "modifier": "private...
{ "body": "@Test\n public void construction() throws Exception {\n prepareConstruction();\n HBaseAccessor accessor = new HBaseAccessor();\n accessor.initialize(context);\n PowerMockito.verifyNew(HBaseTupleDescription.class).withArguments(context);\n }", "class_method_signature": "H...
{ "fields": [ { "declarator": "SUPPORTED_OPERATORS =\n EnumSet.of(\n Operator.LESS_THAN,\n Operator.GREATER_THAN,\n Operator.LESS_THAN_OR_EQUAL,\n Operator.GREATER_THAN_OR_EQUAL,\n Operator.EQUALS,\n ...
{ "body": "@Override\n public void initialize(RequestContext requestContext) {\n super.initialize(requestContext);\n\n tupleDescription = new HBaseTupleDescription(context);\n split = null;\n scanStartKey = HConstants.EMPTY_START_ROW;\n scanEndKey = HConstants.EMPTY_END_ROW;\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_374
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "dbProdu...
{ "body": "@Test\n public void testEqualBoundaries() {\n IntPartition partition = new IntPartition(COL_RAW, 0L, 0L);\n String constraint = partition.toSqlConstraint(QUOTE, dbProduct);\n\n assertEquals(COL + \" = 0\", constraint);\n }", "class_method_signature": "IntPartitionTest.testEqual...
{ "fields": [ { "declarator": "serialVersionUID = 0L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 0L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "boundaries", "modifier": "private f...
{ "body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n\n return generateRangeConstraint(\n quoteString + column + quoteString,\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_118
{ "fields": [ { "declarator": "parser", "modifier": "@Mock private", "original_string": "@Mock private RequestParser parser;", "type": "RequestParser", "var_name": "parser" }, { "declarator": "fragmenterFactory", "modifier": "@Mock private", "original_string...
{ "body": "@SuppressWarnings(\"unchecked\")\n @Test\n public void getFragmentsResponseFromEmptyCache() throws Throwable {\n RequestContext context = new RequestContext();\n context.setTransactionId(\"XID-XYZ-123456\");\n context.setSegmentId(0);\n\n when(parser.parseRequest(headersFr...
{ "fields": [ { "declarator": "fragmenterFactory", "modifier": "private", "original_string": "private FragmenterFactory fragmenterFactory;", "type": "FragmenterFactory", "var_name": "fragmenterFactory" }, { "declarator": "fragmenterCacheFactory", "modifier": "priv...
{ "body": "@GET\n @Path(\"getFragments\")\n @Produces(\"application/json\")\n public Response getFragments(@Context final ServletContext servletContext,\n @Context final HttpHeaders headers)\n throws Throwable {\n\n LOG.debug(\"Received FRAGMENTER call\");\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_44
{ "fields": [ { "declarator": "filterParser", "modifier": "private", "original_string": "private FilterParser filterParser;", "type": "FilterParser", "var_name": "filterParser" }, { "declarator": "filter", "modifier": "private", "original_string": "private S...
{ "body": "@Test\n public void testNullFilterString() throws Exception {\n thrown.expect(FilterParser.FilterStringSyntaxException.class);\n thrown.expectMessage(\"filter parsing ended with no result\");\n\n filterParser.parse(null);\n }", "class_method_signature": "FilterParserTest.testNu...
{ "fields": [ { "declarator": "index", "modifier": "private", "original_string": "private int index;", "type": "int", "var_name": "index" }, { "declarator": "filterByteArr", "modifier": "private", "original_string": "private byte[] filterByteArr;", "ty...
{ "body": "public Node parse(String filterString) throws Exception {\n\n if (filterString == null) {\n throw new FilterStringSyntaxException(\"filter parsing ended with no result\");\n }\n\n return parse(filterString.getBytes(DEFAULT_CHARSET));\n }", "class_method_signature": "Fil...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_227
{ "fields": [ { "declarator": "parameters", "modifier": "private", "original_string": "private MultivaluedMap<String, String> parameters;", "type": "MultivaluedMap<String, String>", "var_name": "parameters" }, { "declarator": "parser", "modifier": "private", ...
{ "body": "@Test\n public void testEncodedHeaderValuesIsFalse() throws UnsupportedEncodingException {\n parameters.remove(\"X-GP-DATA-DIR\");\n parameters.putSingle(\"X-GP-DATA-DIR\", URLEncoder.encode(\"\\u0001\", \"UTF-8\"));\n parameters.putSingle(\"X-GP-ENCODED-HEADER-VALUES\", \"false\");...
{ "fields": [ { "declarator": "TRUE_LCASE = \"true\"", "modifier": "private static final", "original_string": "private static final String TRUE_LCASE = \"true\";", "type": "String", "var_name": "TRUE_LCASE" }, { "declarator": "FALSE_LCASE = \"false\"", "modifier":...
{ "body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_362
{ "fields": [], "file": "server/pxf-jdbc/src/test/java/org/greenplum/pxf/plugins/jdbc/utils/HiveJdbcUtilsTest.java", "identifier": "HiveJdbcUtilsTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testURLWithImpersonationPropertyAndQuestionMarkAndHash() throws Exception {\n String url = \"jdbc:hive2://server:10000/default;hive.server2.proxy.user=bar?hive.server2.proxy.user=bar#hive.server2.proxy.user=bar\";\n assertEquals(\"jdbc:hive2://server:10000/default;hive....
{ "fields": [ { "declarator": "HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\"", "modifier": "private static final", "original_string": "private static final String HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\";", "type": "String", "var_name": "HIVE_UR...
{ "body": "public static String updateImpersonationPropertyInHiveJdbcUrl(String url, String user) {\n String suffix, prefix = null;\n int terminatorIndex = findTerminatorIndex(url, 0, TERMINATORS_TWO_CHARS);\n\n // impersonation property might already be in the URL\n int impersonationPrope...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_52
{ "fields": [], "file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/filter/ScalarOperandNodeTest.java", "identifier": "ScalarOperandNodeTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testConstructor() {\n ScalarOperandNode scalarOperandNode = new ScalarOperandNode(DataType.INTEGER, \"5\");\n\n assertSame(DataType.INTEGER, scalarOperandNode.getDataType());\n assertEquals(\"5\", scalarOperandNode.getValue());\n }", "class_method_signature"...
{ "fields": [ { "declarator": "value", "modifier": "private final", "original_string": "private final String value;", "type": "String", "var_name": "value" } ], "file": "server/pxf-api/src/main/java/org/greenplum/pxf/api/filter/ScalarOperandNode.java", "identifier": "Scalar...
{ "body": "public String getValue() {\n return value;\n }", "class_method_signature": "ScalarOperandNode.getValue()", "constructor": false, "full_signature": "public String getValue()", "identifier": "getValue", "invocations": [], "modifiers": "public", "parameters": "()", "return": "String"...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_270
{ "fields": [ { "declarator": "context", "modifier": "private", "original_string": "private RequestContext context;", "type": "RequestContext", "var_name": "context" }, { "declarator": "schema", "modifier": "private", "original_string": "private Schema schem...
{ "body": "@Test\n public void testObtainSchema_OnWrite_WithUserProvidedSchema_Json_NotFound() {\n expectedException.expect(RuntimeException.class);\n expectedException.expectMessage(\"Failed to obtain Avro schema from 'user-provided.avsc'\");\n context.setRequestType(RequestContext.RequestTyp...
{ "fields": [ { "declarator": "COMMON_NAMESPACE = \"public.avro\"", "modifier": "private static", "original_string": "private static String COMMON_NAMESPACE = \"public.avro\";", "type": "String", "var_name": "COMMON_NAMESPACE" }, { "declarator": "fileSearcher", "m...
{ "body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_335
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testReadFromQueryFailsWhenServerDirectoryDoesNotExist() throws Exception {\n expectedException.expect(RuntimeException.class);\n expectedException.expectMessage(\"Failed to read text of query foo : File '/non-existing-directory/foo.sql' does not exist\");\n conte...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(JdbcAccessor.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(JdbcAccessor.class);", "type": "Logger", "var_name": "LOG" }, { "declarat...
{ "body": "@Override\n public boolean openForRead() throws SQLException, SQLTimeoutException, ParseException {\n if (statementRead != null && !statementRead.isClosed()) {\n return true;\n }\n\n Connection connection = super.getConnection();\n SQLQueryBuilder sqlQueryBuilder =...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_159
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void determineRemoteUser_IsServiceUser_NoKerberos_NoImpersonation_ServiceUser() throws Exception {\n expectScenario(false, false, true);\n filter.doFilter(mockServletRequest, mockServletResponse, mockFilterChain);\n // you would expect to find \"service-user\" here, a...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);", "type": "Logger", "var_name": "LOG" }, ...
{ "body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_122
{ "fields": [], "file": "server/pxf-service/src/test/java/org/greenplum/pxf/service/rest/VersionResourceTest.java", "identifier": "VersionResourceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void getProtocolVersion() throws Exception {\n\n VersionResource resource = new VersionResource();\n Response result = resource.getProtocolVersion();\n\n assertEquals(Response.Status.OK,\n Response.Status.fromStatusCode(result.getStatus()));\n as...
{ "fields": [ { "declarator": "LOG = LogFactory.getLog(VersionResource.class)", "modifier": "private static final", "original_string": "private static final Log LOG = LogFactory.getLog(VersionResource.class);", "type": "Log", "var_name": "LOG" } ], "file": "server/pxf-service...
{ "body": "@GET\n @Produces(\"application/json\")\n public Response getProtocolVersion() {\n\n ResponseBuilder b = Response.ok();\n b.entity(\"{ \\\"version\\\": \\\"\" + Version.PXF_PROTOCOL_VERSION + \"\\\"}\");\n b.type(MediaType.APPLICATION_JSON_TYPE);\n return b.build();\n }"...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_91
{ "fields": [ { "declarator": "PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\"", "modifier": "private static final", "original_string": "private static final String PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\";", "type": "String"...
{ "body": "@Test\n public void testSingleton() {\n assertSame(secureLogin, SecureLogin.getInstance());\n }", "class_method_signature": "SecureLoginTest.testSingleton()", "constructor": false, "full_signature": "@Test public void testSingleton()", "identifier": "testSingleton", "invocations": [ ...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecureLogin.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecureLogin.class);", "type": "Logger", "var_name": "LOG" }, { "declarator...
{ "body": "public static SecureLogin getInstance() {\n return instance;\n }", "class_method_signature": "SecureLogin.getInstance()", "constructor": false, "full_signature": "public static SecureLogin getInstance()", "identifier": "getInstance", "invocations": [], "modifiers": "public static", ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_319
{ "fields": [ { "declarator": "hiveColumn", "modifier": "", "original_string": "FieldSchema hiveColumn;", "type": "FieldSchema", "var_name": "hiveColumn" }, { "declarator": "typesMappings = {\n /* hive type -> gpdb type */\n {\"tinyint\", \"int2\"}...
{ "body": "@Test\n public void mapHiveTypeInvalidModifiers() throws Exception {\n String badHiveType = \"decimal(abc, xyz)\";\n hiveColumn = new FieldSchema(\"numericColumn\", badHiveType, null);\n try {\n HiveUtilities.mapHiveType(hiveColumn);\n fail(\"should fail with b...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(HiveUtilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(HiveUtilities.class);", "type": "Logger", "var_name": "LOG" } ], "file": "serv...
{ "body": "public static Metadata.Field mapHiveType(FieldSchema hiveColumn) throws UnsupportedTypeException {\n String fieldName = hiveColumn.getName();\n String hiveType = hiveColumn.getType(); // Type name and modifiers if any\n String hiveTypeName; // Type name\n String[] modifiers = nu...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_29
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" } ...
{ "body": "@Test\n public void testGetFragmentStatsIsUnsupported() throws Exception {\n expectedException.expect(UnsupportedOperationException.class);\n expectedException.expectMessage(\"Operation getFragmentStats is not supported\");\n\n new BaseFragmenter().getFragmentStats();\n }", "cl...
{ "fields": [ { "declarator": "fragments = new LinkedList<>()", "modifier": "protected", "original_string": "protected List<Fragment> fragments = new LinkedList<>();", "type": "List<Fragment>", "var_name": "fragments" } ], "file": "server/pxf-api/src/main/java/org/greenplum/p...
{ "body": "@Override\n public FragmentStats getFragmentStats() throws Exception {\n throw new UnsupportedOperationException(\"Operation getFragmentStats is not supported\");\n// long fragmentsNumber = fragments.size();\n// return new FragmentStats(fragmentsNumber,\n// FragmentSt...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_175
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" } ...
{ "body": "@Test\n public void testGetMissingProtocol() {\n ProfilesConf profilesConf = getProfilesConf(\"testGetProtocol\");\n assertNull(profilesConf.getProtocol(\"bar\"));\n }", "class_method_signature": "ProfilesConfTest.testGetMissingProtocol()", "constructor": false, "full_signature": ...
{ "fields": [ { "declarator": "EXTERNAL_PROFILES = \"pxf-profiles.xml\"", "modifier": "private final static", "original_string": "private final static String EXTERNAL_PROFILES = \"pxf-profiles.xml\";", "type": "String", "var_name": "EXTERNAL_PROFILES" }, { "declarator":...
{ "body": "@Override\n public String getProtocol(String profileName) {\n return getProfile(profileName).getProtocol();\n }", "class_method_signature": "ProfilesConf.getProtocol(String profileName)", "constructor": false, "full_signature": "@Override public String getProtocol(String profileName)", ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_163
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void determineRemoteUser_IsServiceUser_Kerberos_NoImpersonation_ServiceUser() throws Exception {\n expectScenario(true, false, true);\n filter.doFilter(mockServletRequest, mockServletResponse, mockFilterChain);\n verifyScenario(\"service-user\", false);\n }", "cl...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);", "type": "Logger", "var_name": "LOG" }, ...
{ "body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_358
{ "fields": [], "file": "server/pxf-jdbc/src/test/java/org/greenplum/pxf/plugins/jdbc/utils/HiveJdbcUtilsTest.java", "identifier": "HiveJdbcUtilsTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testURLWithImpersonationPropertyOnly() throws Exception {\n String url = \"jdbc:hive2://server:10000/default;hive.server2.proxy.user=bar\";\n assertEquals(\"jdbc:hive2://server:10000/default;hive.server2.proxy.user=foo\",\n HiveJdbcUtils.updateImpersonati...
{ "fields": [ { "declarator": "HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\"", "modifier": "private static final", "original_string": "private static final String HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\";", "type": "String", "var_name": "HIVE_UR...
{ "body": "public static String updateImpersonationPropertyInHiveJdbcUrl(String url, String user) {\n String suffix, prefix = null;\n int terminatorIndex = findTerminatorIndex(url, 0, TERMINATORS_TWO_CHARS);\n\n // impersonation property might already be in the URL\n int impersonationPrope...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_68
{ "fields": [], "file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/filter/ColumnIndexOperandNodeTest.java", "identifier": "ColumnIndexOperandNodeTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testConstructor() {\n ColumnIndexOperandNode columnIndexOperandNode = new ColumnIndexOperandNode(5);\n\n assertEquals(5, columnIndexOperandNode.index());\n assertNull(columnIndexOperandNode.getDataType());\n }", "class_method_signature": "ColumnIndexOperandN...
{ "fields": [ { "declarator": "index", "modifier": "private final", "original_string": "private final int index;", "type": "int", "var_name": "index" } ], "file": "server/pxf-api/src/main/java/org/greenplum/pxf/api/filter/ColumnIndexOperandNode.java", "identifier": "ColumnI...
{ "body": "public int index() {\n return index;\n }", "class_method_signature": "ColumnIndexOperandNode.index()", "constructor": false, "full_signature": "public int index()", "identifier": "index", "invocations": [], "modifiers": "public", "parameters": "()", "return": "int", "signature":...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_134
{ "fields": [ { "declarator": "MINUTES = 60 * 1000L", "modifier": "private static final", "original_string": "private static final long MINUTES = 60 * 1000L;", "type": "long", "var_name": "MINUTES" }, { "declarator": "provider = null", "modifier": "private", ...
{ "body": "@Test(expected = IOException.class)\n public void errorsThrownByCreatingAUgiAreNotCaught() throws Exception {\n when(provider.createProxyUGI(\"the-user\", UserGroupInformation.getLoginUser())).thenThrow(new IOException(\"test exception\"));\n cache.getUserGroupInformation(session, true);\n...
{ "fields": [ { "declarator": "NANOS_PER_MILLIS = 1000000", "modifier": "static final", "original_string": "static final int NANOS_PER_MILLIS = 1000000;", "type": "int", "var_name": "NANOS_PER_MILLIS" }, { "declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L", "modif...
{ "body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_87
{ "fields": [ { "declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"", "modifier": "private", "original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";", "type": "String", "var_name": "PROPERTY_KEY_...
{ "body": "@Test\n public void testSecurityIsDisabledOnNewConfiguration() {\n Configuration configuration = new Configuration();\n assertFalse(Utilities.isSecurityEnabled(configuration));\n }", "class_method_signature": "UtilitiesTest.testSecurityIsDisabledOnNewConfiguration()", "constructor":...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(Utilities.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);", "type": "Logger", "var_name": "LOG" }, { "declarator": "...
{ "body": "public static boolean isSecurityEnabled(Configuration configuration) {\n return SecurityUtil.getAuthenticationMethod(configuration) !=\n UserGroupInformation.AuthenticationMethod.SIMPLE;\n }", "class_method_signature": "Utilities.isSecurityEnabled(Configuration configuration)", ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_143
{ "fields": [], "file": "server/pxf-service/src/test/java/org/greenplum/pxf/service/utilities/AnalyzeUtilsTest.java", "identifier": "AnalyzeUtilsTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void getSampleFragments() throws Exception {\n // fragments less than threshold\n runGetSampleFragmentsTest(4, 100, 4, new int[] {0, 1, 2, 3});\n\n // fragments over threshold\n runGetSampleFragmentsTest(4, 2, 2, new int[]{0, 3});\n runGetSampleFragments...
{ "fields": [ { "declarator": "LOG = LogFactory.getLog(AnalyzeUtils.class)", "modifier": "private static final", "original_string": "private static final Log LOG = LogFactory.getLog(AnalyzeUtils.class);", "type": "Log", "var_name": "LOG" } ], "file": "server/pxf-service/src/m...
{ "body": "static public List<Fragment> getSampleFragments(List<Fragment> fragments,\n RequestContext context) {\n\n int listSize = fragments.size();\n int maxSize = context.getStatsMaxFragments();\n List<Fragment> samplingList = new ArrayList<Fr...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_1
{ "fields": [], "file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/io/BufferWritableTest.java", "identifier": "BufferWritableTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void append() throws Exception {\n String data1 = \"פרק ראשון ובו יסופר יסופר\";\n String data2 = \"פרק שני ובו יסופר יסופר\";\n\n BufferWritable bw1 = new BufferWritable(data1.getBytes());\n\n assertArrayEquals(data1.getBytes(), bw1.buf);\n\n bw1.append...
{ "fields": [ { "declarator": "buf = null", "modifier": "", "original_string": "byte[] buf = null;", "type": "byte[]", "var_name": "buf" } ], "file": "server/pxf-api/src/main/java/org/greenplum/pxf/api/io/BufferWritable.java", "identifier": "BufferWritable", "interfaces":...
{ "body": "public void append(byte[] app) {\n if (buf == null) {\n buf = app;\n return;\n }\n if (app == null) {\n return;\n }\n\n byte[] newbuf = new byte[buf.length + app.length];\n System.arraycopy(buf, 0, newbuf, 0, buf.length);\n S...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_285
{ "fields": [ { "declarator": "expectedException = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();", "type": "ExpectedException", "var_name": "expectedException" }, ...
{ "body": "@Test\n public void testReadFromSimpleCsvFile() throws Exception {\n prepareTest(\"csv/simple.csv\", false);\n\n OneRow oneRow = accessor.readNextObject();\n assertNotNull(oneRow);\n assertEquals(\"1,a,b\", oneRow.getData());\n\n oneRow = accessor.readNextObject();\n ...
{ "fields": [ { "declarator": "fileAsRow", "modifier": "private", "original_string": "private boolean fileAsRow;", "type": "boolean", "var_name": "fileAsRow" }, { "declarator": "firstLine", "modifier": "private", "original_string": "private boolean firstLine...
{ "body": "@Override\n public OneRow readNextObject() throws IOException {\n if (super.readNextObject() == null) /* check if working segment */ {\n return null;\n }\n\n String nextLine = readLine();\n if (nextLine == null) /* EOF */ {\n return null;\n }\n\n ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_401
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" } ], "file": "server/pxf-s3/src/t...
{ "body": "@Test\n public void testJSONInputSerializationWithLinesJsonType() {\n RequestContext context = getRequestContext(\"s3:json\");\n context.setFormat(\"json\");\n context.addOption(\"JSON-TYPE\", \"lines\");\n\n InputSerialization inputSerialization =\n new S3Sele...
{ "fields": [ { "declarator": "COMPRESSION_TYPE = \"COMPRESSION_CODEC\"", "modifier": "public static final", "original_string": "public static final String COMPRESSION_TYPE = \"COMPRESSION_CODEC\";", "type": "String", "var_name": "COMPRESSION_TYPE" }, { "declarator": "F...
{ "body": "InputSerialization getInputSerialization(RequestContext context) {\n InputSerialization inputSerialization = new InputSerialization();\n\n // We need to infer the format name from the profile (i.e. s3:parquet\n // would return parquet for the format)\n String format = context.in...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_48
{ "fields": [ { "declarator": "filterParser", "modifier": "private", "original_string": "private FilterParser filterParser;", "type": "FilterParser", "var_name": "filterParser" }, { "declarator": "filter", "modifier": "private", "original_string": "private S...
{ "body": "@Test\n public void parseLogicalOrOperator() throws Exception {\n // (_1_ = 0 OR _2_ > 3)\n filter = \"a1c20s1d0o5a2c20s1d3o2l1\";\n\n Node result = filterParser.parse(filter);\n assertNotNull(result);\n assertOperatorEquals(OR, result);\n assertEquals(2, result...
{ "fields": [ { "declarator": "index", "modifier": "private", "original_string": "private int index;", "type": "int", "var_name": "index" }, { "declarator": "filterByteArr", "modifier": "private", "original_string": "private byte[] filterByteArr;", "ty...
{ "body": "public Node parse(String filterString) throws Exception {\n\n if (filterString == null) {\n throw new FilterStringSyntaxException(\"filter parsing ended with no result\");\n }\n\n return parse(filterString.getBytes(DEFAULT_CHARSET));\n }", "class_method_signature": "Fil...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_114
{ "fields": [ { "declarator": "serverName", "modifier": "private", "original_string": "private String serverName;", "type": "String", "var_name": "serverName" }, { "declarator": "configuration", "modifier": "private", "original_string": "private Configuratio...
{ "body": "@Test\n public void testReloginFromKeytabThrowsExceptionOnLoginFailure() throws Exception {\n expectedException.expect(KerberosAuthException.class);\n expectedException.expectMessage(\"Login failure for principal: principal from keytab keytab\");\n\n user.setLogin(mockLoginContext);...
{ "fields": [ { "declarator": "LOGIN_FAILURE = \"Login failure\"", "modifier": "private static final", "original_string": "private static final String LOGIN_FAILURE = \"Login failure\";", "type": "String", "var_name": "LOGIN_FAILURE" }, { "declarator": "LOG = LoggerFact...
{ "body": "public static void reloginFromKeytab(String serverName, LoginSession loginSession) throws KerberosAuthException {\n\n UserGroupInformation ugi = loginSession.getLoginUser();\n\n if (ugi.getAuthenticationMethod() != UserGroupInformation.AuthenticationMethod.KERBEROS ||\n !ugi.is...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_397
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" } ], "file": "server/pxf-s3/src/t...
{ "body": "@Test\n public void testCompressionTypeBZIP2() {\n RequestContext context = getDefaultRequestContext();\n context.addOption(\"COMPRESSION_CODEC\", \"BZIP2\");\n\n InputSerialization inputSerialization =\n new S3SelectAccessor().getInputSerialization(context);\n ...
{ "fields": [ { "declarator": "COMPRESSION_TYPE = \"COMPRESSION_CODEC\"", "modifier": "public static final", "original_string": "public static final String COMPRESSION_TYPE = \"COMPRESSION_CODEC\";", "type": "String", "var_name": "COMPRESSION_TYPE" }, { "declarator": "F...
{ "body": "InputSerialization getInputSerialization(RequestContext context) {\n InputSerialization inputSerialization = new InputSerialization();\n\n // We need to infer the format name from the profile (i.e. s3:parquet\n // would return parquet for the format)\n String format = context.in...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_378
{ "fields": [ { "declarator": "thrown = ExpectedException.none()", "modifier": "@Rule\n public", "original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();", "type": "ExpectedException", "var_name": "thrown" }, { "declarator": "dbProdu...
{ "body": "@Test\n public void testExcluded2() {\n EnumPartition partition = new EnumPartition(COL_RAW, new String[]{\"enum1\", \"enum2\"});\n String constraint = partition.toSqlConstraint(QUOTE, dbProduct);\n\n assertEquals(\"( \\\"col\\\" <> 'enum1' AND \\\"col\\\" <> 'enum2' )\", constraint...
{ "fields": [ { "declarator": "serialVersionUID = 0L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 0L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "value", "modifier": "private final"...
{ "body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n\n StringBuilder sb = new StringBuilder();\n\n String quotedColumn = quoteString + ...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...
146510094_102
{ "fields": [ { "declarator": "PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\"", "modifier": "private static final", "original_string": "private static final String PROPERTY_KEY_USER_IMPERSONATION = \"pxf.service.user.impersonation.enabled\";", "type": "String"...
{ "body": "@Test\n public void testServerConfigurationImpersonationOverwritesGlobalTrue() {\n System.setProperty(PROPERTY_KEY_USER_IMPERSONATION, \"false\");\n configuration.set(\"pxf.service.user.impersonation\", \"true\");\n assertTrue(secureLogin.isUserImpersonationEnabled(configuration));\...
{ "fields": [ { "declarator": "LOG = LoggerFactory.getLogger(SecureLogin.class)", "modifier": "private static final", "original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecureLogin.class);", "type": "Logger", "var_name": "LOG" }, { "declarator...
{ "body": "public boolean isUserImpersonationEnabled(Configuration configuration) {\n String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, \"false\"));\n return StringUtils.equalsIgnoreCase(va...
{ "created": "8/28/2018 9:42:19 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 146510094, "size": null, "stargazer_count": null, "stars": 14, "updates": "2020-01-25T19:21:50+00:00", "url": "https://github.com/greenplum-db/pxf...