docstring_tokens
list | code_tokens
list |
---|---|
[
"get",
"the",
"code",
"unit",
"immediately",
"following",
"the",
"specified",
"code",
"unit"
] |
[
"private",
"code",
"unit",
"get",
"next",
"code",
"unit",
"(",
"code",
"unit",
"cu",
")",
"{",
"code",
"unit",
"next",
"=",
"null",
";",
"try",
"{",
"address",
"next",
"addr",
"=",
"cu",
"get",
"max",
"address",
"(",
")",
"add",
"no",
"wrap",
"(",
"1",
")",
";",
"if",
"(",
"next",
"addr",
"!",
"=",
"null",
")",
"{",
"next",
"=",
"cu",
"get",
"program",
"(",
")",
"get",
"listing",
"(",
")",
"get",
"code",
"unit",
"at",
"(",
"next",
"addr",
")",
";",
"}",
"return",
"next",
";",
"}",
"catch",
"(",
"address",
"overflow",
"exception",
"e",
")",
"{",
"/",
"/",
"don",
"'",
"t",
"care",
"}",
"return",
"null",
";",
"}"
] |
[
"serialize",
"the",
"given",
"key"
] |
[
"public",
"byte",
"[",
"]",
"raw",
"key",
"(",
"final",
"k",
"key",
")",
"{",
"try",
"{",
"return",
"key",
"serde",
"serializer",
"(",
")",
"serialize",
"(",
"topic",
",",
"key",
")",
";",
"}",
"catch",
"(",
"final",
"class",
"cast",
"exception",
"e",
")",
"{",
"final",
"string",
"key",
"class",
"=",
"key",
"=",
"=",
"null",
"?",
"\"",
"unknown",
"because",
"key",
"is",
"null",
"\"",
":",
"key",
"get",
"class",
"(",
")",
"get",
"name",
"(",
")",
";",
"throw",
"new",
"streams",
"exception",
"(",
"string",
"format",
"(",
"\"",
"a",
"serializer",
"(",
"%",
"s",
")",
"is",
"not",
"compatible",
"to",
"the",
"actual",
"key",
"type",
"\"",
"+",
"\"",
"(",
"key",
"type",
":",
"%",
"s",
")",
"change",
"the",
"default",
"serdes",
"in",
"stream",
"config",
"or",
"\"",
"+",
"\"",
"provide",
"correct",
"serdes",
"via",
"method",
"parameters",
"\"",
",",
"key",
"serializer",
"(",
")",
"get",
"class",
"(",
")",
"get",
"name",
"(",
")",
",",
"key",
"class",
")",
",",
"e",
")",
";",
"}",
"}"
] |
[
"negate",
"all",
"counters"
] |
[
"public",
"void",
"negation",
"(",
")",
"{",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"counters",
"length",
";",
"i",
"+",
"+",
")",
"{",
"counters",
"[",
"i",
"]",
"=",
"-",
"counters",
"[",
"i",
"]",
";",
"}",
"}"
] |
[
"return",
"the",
"sort",
"definition",
"for",
"this",
"holder"
] |
[
"public",
"sort",
"definition",
"get",
"sort",
"(",
")",
"{",
"return",
"this",
"sort",
";",
"}"
] |
[
"session",
"tokens",
"can",
"read",
"the",
"landsat",
"bucket",
"without",
"problems"
] |
[
"protected",
"void",
"verify",
"restricted",
"permissions",
"(",
"final",
"s",
"3",
"a",
"file",
"system",
"delegated",
"f",
"s",
")",
"throws",
"exception",
"{",
"read",
"landsat",
"metadata",
"(",
"delegated",
"f",
"s",
")",
";",
"}"
] |
[
"the",
"registered",
"service",
"instance",
"is",
"health",
"or",
"not"
] |
[
"default",
"boolean",
"is",
"healthy",
"(",
")",
"{",
"return",
"true",
";",
"}"
] |
[
"fetches",
"the",
"config",
"this",
"object",
"uses"
] |
[
"private",
"config",
"extractor",
"get",
"config",
"(",
")",
"{",
"return",
"config",
";",
"}"
] |
[
"sets",
"the",
"base",
"url",
"to",
"the",
"location",
"where",
"the",
"open",
"a",
"p",
"i",
"document",
"is",
"being",
"served"
] |
[
"public",
"api",
"client",
"set",
"base",
"path",
"(",
"string",
"base",
"path",
")",
"{",
"this",
"base",
"path",
"=",
"base",
"path",
";",
"return",
"this",
";",
"}"
] |
[
"creates",
"an",
"embedded",
"server",
"instance"
] |
[
"public",
"embedded",
"server",
"create",
"(",
"routes",
"route",
"matcher",
",",
"static",
"files",
"configuration",
"static",
"files",
"configuration",
",",
"exception",
"mapper",
"exception",
"mapper",
",",
"boolean",
"has",
"multiple",
"handler",
")",
";"
] |
[
"set",
"the",
"uri",
"for",
"the",
"application",
"'",
"s",
"executable",
"normally",
"this",
"is",
"a",
"hdfs",
":",
"location"
] |
[
"public",
"static",
"void",
"set",
"executable",
"(",
"job",
"conf",
"conf",
",",
"string",
"executable",
")",
"{",
"conf",
"set",
"(",
"submitter",
"executable",
",",
"executable",
")",
";",
"}"
] |
[
"finds",
"the",
"result",
"type",
"of",
"a",
"decimal",
"multiplication",
"operation"
] |
[
"public",
"static",
"decimal",
"type",
"find",
"multiplication",
"decimal",
"type",
"(",
"int",
"precision",
"1",
",",
"int",
"scale",
"1",
",",
"int",
"precision",
"2",
",",
"int",
"scale",
"2",
")",
"{",
"/",
"/",
"adopted",
"from",
"calcite",
"int",
"scale",
"=",
"scale",
"1",
"+",
"scale",
"2",
";",
"scale",
"=",
"math",
"min",
"(",
"scale",
",",
"decimal",
"type",
"max",
"precision",
")",
";",
"int",
"precision",
"=",
"precision",
"1",
"+",
"precision",
"2",
";",
"precision",
"=",
"math",
"min",
"(",
"precision",
",",
"decimal",
"type",
"max",
"precision",
")",
";",
"return",
"new",
"decimal",
"type",
"(",
"false",
",",
"precision",
",",
"scale",
")",
";",
"}"
] |
[
"get",
"my",
"string"
] |
[
"public",
"string",
"get",
"my",
"string",
"(",
")",
"{",
"return",
"my",
"string",
";",
"}"
] |
[
"deprecated",
":",
"change",
"usages",
"of",
"this",
"to",
"{",
"@",
"link",
"#",
"on",
"fallback",
"error",
"}",
"invoked",
"after",
"failed",
"execution",
"of",
"{",
"@",
"link",
"hystrix",
"command",
"#",
"get",
"fallback",
"(",
")",
"}",
"with",
"thrown",
"exception"
] |
[
"public",
"<",
"t",
">",
"exception",
"on",
"fallback",
"error",
"(",
"hystrix",
"command",
"<",
"t",
">",
"command",
"instance",
",",
"exception",
"e",
")",
"{",
"/",
"/",
"pass",
"-",
"thru",
"by",
"default",
"return",
"e",
";",
"}"
] |
[
"retrieve",
"the",
"shard",
"size",
"for",
"the",
"{",
"@",
"link",
"hystrix",
"collapser",
"}",
"being",
"invoked",
"at",
"a",
"given",
"percentile",
"percentile",
"capture",
"and",
"calculation",
"is",
"configured",
"via",
"{",
"@",
"link",
"hystrix",
"collapser",
"properties",
"#",
"metrics",
"rolling",
"statistical",
"window",
"in",
"milliseconds",
"(",
")",
"}",
"and",
"other",
"related",
"properties"
] |
[
"public",
"int",
"get",
"shard",
"size",
"percentile",
"(",
"double",
"percentile",
")",
"{",
"return",
"0",
";",
"/",
"/",
"return",
"rolling",
"collapser",
"usage",
"distribution",
"stream",
"get",
"latest",
"batch",
"size",
"percentile",
"(",
"percentile",
")",
";",
"}"
] |
[
"get",
"small",
"snake"
] |
[
"public",
"string",
"get",
"small",
"snake",
"(",
")",
"{",
"return",
"small",
"snake",
";",
"}"
] |
[
"gets",
"resource",
"id"
] |
[
"public",
"string",
"get",
"resource",
"id",
"(",
")",
"{",
"return",
"resource",
"id",
";",
"}"
] |
[
"initialize",
"the",
"bodies",
",",
"anchors",
",",
"lengths",
",",
"max",
"lengths",
",",
"and",
"ratio",
"using",
"the",
"world",
"anchors"
] |
[
"public",
"void",
"initialize",
"(",
"body",
"body",
"a",
",",
"body",
"body",
"b",
",",
"vector",
"2",
"ground",
"anchor",
"a",
",",
"vector",
"2",
"ground",
"anchor",
"b",
",",
"vector",
"2",
"anchor",
"a",
",",
"vector",
"2",
"anchor",
"b",
",",
"float",
"ratio",
")",
"{",
"this",
"body",
"a",
"=",
"body",
"a",
";",
"this",
"body",
"b",
"=",
"body",
"b",
";",
"this",
"ground",
"anchor",
"a",
"set",
"(",
"ground",
"anchor",
"a",
")",
";",
"this",
"ground",
"anchor",
"b",
"set",
"(",
"ground",
"anchor",
"b",
")",
";",
"this",
"local",
"anchor",
"a",
"set",
"(",
"body",
"a",
"get",
"local",
"point",
"(",
"anchor",
"a",
")",
")",
";",
"this",
"local",
"anchor",
"b",
"set",
"(",
"body",
"b",
"get",
"local",
"point",
"(",
"anchor",
"b",
")",
")",
";",
"length",
"a",
"=",
"anchor",
"a",
"dst",
"(",
"ground",
"anchor",
"a",
")",
";",
"length",
"b",
"=",
"anchor",
"b",
"dst",
"(",
"ground",
"anchor",
"b",
")",
";",
"this",
"ratio",
"=",
"ratio",
";",
"float",
"c",
"=",
"length",
"a",
"+",
"ratio",
"*",
"length",
"b",
";",
"}"
] |
[
"returns",
"whether",
"the",
"loader",
"is",
"currently",
"loading"
] |
[
"public",
"boolean",
"is",
"loading",
"(",
")",
"{",
"return",
"current",
"task",
"!",
"=",
"null",
";",
"}"
] |
[
"handle",
"post",
"request"
] |
[
"protected",
"void",
"handle",
"post",
"request",
"(",
"final",
"http",
"servlet",
"response",
"response",
",",
"final",
"http",
"servlet",
"request",
"request",
")",
"{",
"val",
"ctx",
"=",
"decode",
"soap",
"request",
"(",
"request",
")",
";",
"val",
"query",
"=",
"(",
"attribute",
"query",
")",
"ctx",
"get",
"message",
"(",
")",
";",
"val",
"config",
"=",
"get",
"saml",
"profile",
"handler",
"configuration",
"context",
"(",
")",
";",
"try",
"{",
"val",
"issuer",
"=",
"objects",
"require",
"non",
"null",
"(",
"query",
")",
"get",
"issuer",
"(",
")",
"get",
"value",
"(",
")",
";",
"val",
"service",
"=",
"verify",
"saml",
"registered",
"service",
"(",
"issuer",
")",
";",
"val",
"adaptor",
"=",
"get",
"saml",
"metadata",
"facade",
"for",
"(",
"service",
",",
"query",
")",
";",
"if",
"(",
"adaptor",
"is",
"empty",
"(",
")",
")",
"{",
"throw",
"new",
"unauthorized",
"service",
"exception",
"(",
"unauthorized",
"service",
"exception",
"code",
"unauthz",
"service",
",",
"\"",
"cannot",
"find",
"metadata",
"linked",
"to",
"\"",
"+",
"issuer",
")",
";",
"}",
"val",
"facade",
"=",
"adaptor",
"get",
"(",
")",
";",
"verify",
"authentication",
"context",
"signature",
"(",
"ctx",
",",
"request",
",",
"query",
",",
"facade",
")",
";",
"val",
"available",
"attributes",
"=",
"new",
"linked",
"hash",
"map",
"<",
"string",
",",
"object",
">",
"(",
")",
";",
"val",
"final",
"attributes",
"=",
"new",
"linked",
"hash",
"map",
"<",
"string",
",",
"object",
">",
"(",
")",
";",
"if",
"(",
"!",
"query",
"get",
"attributes",
"(",
")",
"is",
"empty",
"(",
")",
")",
"{",
"val",
"id",
"=",
"config",
"get",
"saml",
"attribute",
"query",
"ticket",
"factory",
"(",
")",
"create",
"ticket",
"id",
"for",
"(",
"query",
"get",
"subject",
"(",
")",
"get",
"name",
"i",
"d",
"(",
")",
"get",
"value",
"(",
")",
")",
";",
"logger",
"debug",
"(",
"\"",
"created",
"ticket",
"id",
"for",
"attribute",
"query",
"[",
"{",
"}",
"]",
"\"",
",",
"id",
")",
";",
"val",
"ticket",
"=",
"config",
"get",
"ticket",
"registry",
"(",
")",
"get",
"ticket",
"(",
"id",
",",
"saml",
"attribute",
"query",
"ticket",
"class",
")",
";",
"if",
"(",
"ticket",
"=",
"=",
"null",
")",
"{",
"throw",
"new",
"invalid",
"ticket",
"exception",
"(",
"id",
")",
";",
"}",
"val",
"authentication",
"=",
"ticket",
"get",
"ticket",
"granting",
"ticket",
"(",
")",
"get",
"authentication",
"(",
")",
";",
"val",
"principal",
"=",
"authentication",
"get",
"principal",
"(",
")",
";",
"available",
"attributes",
"put",
"all",
"(",
"authentication",
"get",
"attributes",
"(",
")",
")",
";",
"available",
"attributes",
"put",
"all",
"(",
"principal",
"get",
"attributes",
"(",
")",
")",
";",
"}",
"query",
"get",
"attributes",
"(",
")",
"for",
"each",
"(",
"a",
"-",
">",
"{",
"if",
"(",
"available",
"attributes",
"contains",
"key",
"(",
"a",
"get",
"name",
"(",
")",
")",
")",
"{",
"final",
"attributes",
"put",
"(",
"a",
"get",
"name",
"(",
")",
",",
"available",
"attributes",
"get",
"(",
"a",
"get",
"name",
"(",
")",
")",
")",
";",
"}",
"}",
")",
";",
"logger",
"trace",
"(",
"\"",
"final",
"attributes",
"for",
"attribute",
"query",
"are",
"[",
"{",
"}",
"]",
"\"",
",",
"final",
"attributes",
")",
";",
"val",
"cas",
"assertion",
"=",
"build",
"cas",
"assertion",
"(",
"issuer",
",",
"service",
",",
"final",
"attributes",
")",
";",
"config",
"get",
"response",
"builder",
"(",
")",
"build",
"(",
"query",
",",
"request",
",",
"response",
",",
"cas",
"assertion",
",",
"service",
",",
"facade",
",",
"s",
"a",
"m",
"l",
"constants",
"saml2",
"soap11",
"binding",
"uri",
",",
"ctx",
")",
";",
"}",
"catch",
"(",
"final",
"exception",
"e",
")",
"{",
"logging",
"utils",
"error",
"(",
"logger",
",",
"e",
")",
";",
"request",
"set",
"attribute",
"(",
"saml",
"id",
"p",
"constants",
"request",
"attribute",
"error",
",",
"\"",
"unable",
"to",
"build",
"soap",
"response",
":",
"\"",
"+",
"string",
"utils",
"default",
"string",
"(",
"e",
"get",
"message",
"(",
")",
")",
")",
";",
"config",
"get",
"saml",
"fault",
"response",
"builder",
"(",
")",
"build",
"(",
"query",
",",
"request",
",",
"response",
",",
"null",
",",
"null",
",",
"null",
",",
"s",
"a",
"m",
"l",
"constants",
"saml2",
"soap11",
"binding",
"uri",
",",
"ctx",
")",
";",
"}",
"}"
] |
[
"store",
"the",
"data",
"in",
"the",
"internal",
"cache",
",",
"if",
"it",
"'",
"s",
"not",
"yet",
"present",
"return",
"the",
"generated",
"id",
"ids",
"are",
"positive",
"and",
"unique",
"stream",
"the",
"proto",
"to",
"output",
",",
"the",
"first",
"time",
"it",
"'",
"s",
"generated"
] |
[
"int",
"data",
"to",
"id",
"and",
"stream",
"output",
"proto",
"(",
"k",
"data",
")",
"throws",
"i",
"o",
"exception",
",",
"interrupted",
"exception",
"{",
"k",
"key",
"=",
"transform",
"to",
"key",
"(",
"data",
")",
";",
"integer",
"id",
"=",
"cache",
"get",
"(",
"key",
")",
";",
"if",
"(",
"id",
"=",
"=",
"null",
")",
"{",
"/",
"/",
"note",
"that",
"this",
"cannot",
"be",
"replaced",
"by",
"compute",
"if",
"absent",
"since",
"create",
"proto",
"is",
"a",
"recursive",
"/",
"/",
"operation",
"for",
"the",
"case",
"of",
"nested",
"sets",
"which",
"will",
"call",
"data",
"to",
"id",
"on",
"the",
"same",
"object",
"and",
"thus",
"/",
"/",
"compute",
"if",
"absent",
"again",
"id",
"=",
"generate",
"next",
"id",
"(",
")",
";",
"cache",
"put",
"(",
"key",
",",
"id",
")",
";",
"p",
"proto",
"=",
"create",
"proto",
"(",
"data",
",",
"id",
")",
";",
"to",
"output",
"(",
"proto",
")",
";",
"}",
"return",
"id",
";",
"}"
] |
[
"should",
"ec",
"policies",
"be",
"displayed"
] |
[
"boolean",
"is",
"display",
"e",
"c",
"policy",
"(",
")",
"{",
"return",
"this",
"display",
"e",
"c",
"policy",
";",
"}"
] |
[
"if",
"the",
"base",
"object",
"is",
"not",
"null",
",",
"returns",
"the",
"most",
"general",
"type",
"that",
"this",
"resolver",
"accepts",
"for",
"the",
"property",
"argument",
"otherwise",
",",
"returns",
"null",
"assuming",
"the",
"base",
"is",
"not",
"null",
",",
"this",
"method",
"will",
"always",
"return",
"object",
"class",
"this",
"is",
"because",
"any",
"object",
"is",
"accepted",
"as",
"a",
"key",
"and",
"is",
"coerced",
"into",
"a",
"string"
] |
[
"public",
"class",
"<",
"?",
">",
"get",
"common",
"property",
"type",
"(",
"e",
"l",
"context",
"context",
",",
"object",
"base",
")",
"{",
"return",
"is",
"resolvable",
"(",
"base",
")",
"?",
"object",
"class",
":",
"null",
";",
"}"
] |
[
"returns",
"a",
"predicate",
"that",
"evaluates",
"to",
"{",
"@",
"code",
"true",
"}",
"if",
"any",
"one",
"of",
"its",
"components",
"evaluates",
"to",
"{",
"@",
"code",
"true",
"}",
"the",
"components",
"are",
"evaluated",
"in",
"order",
",",
"and",
"evaluation",
"will",
"be",
"\"",
"short",
"-",
"circuited",
"\"",
"as",
"soon",
"as",
"a",
"true",
"predicate",
"is",
"found",
"it",
"defensively",
"copies",
"the",
"iterable",
"passed",
"in",
",",
"so",
"future",
"changes",
"to",
"it",
"won",
"'",
"t",
"alter",
"the",
"behavior",
"of",
"this",
"predicate",
"if",
"{",
"@",
"code",
"components",
"}",
"is",
"empty",
",",
"the",
"returned",
"predicate",
"will",
"always",
"evaluate",
"to",
"{",
"@",
"code",
"false",
"}"
] |
[
"public",
"static",
"<",
"t",
">",
"predicate",
"<",
"t",
">",
"or",
"(",
"iterable",
"<",
"?",
"extends",
"predicate",
"<",
"?",
"super",
"t",
">",
">",
"components",
")",
"{",
"return",
"new",
"or",
"predicate",
"<",
"t",
">",
"(",
"defensive",
"copy",
"(",
"components",
")",
")",
";",
"}"
] |
[
"return",
"the",
"drawable",
"in",
"cache"
] |
[
"public",
"static",
"drawable",
"get",
"drawable",
"(",
"@",
"non",
"null",
"final",
"string",
"key",
",",
"@",
"non",
"null",
"final",
"cache",
"disk",
"utils",
"cache",
"disk",
"utils",
")",
"{",
"return",
"cache",
"disk",
"utils",
"get",
"drawable",
"(",
"key",
")",
";",
"}"
] |
[
"test",
"the",
"property",
"'",
"breed",
"'"
] |
[
"public",
"void",
"breed",
"test",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"breed",
"}"
] |
[
"checks",
"if",
"we",
"have",
"to",
"recreate",
"root",
"directory",
"this",
"is",
"needed",
"because",
"old",
"versions",
"of",
"this",
"storage",
"created",
"too",
"much",
"different",
"files",
"in",
"the",
"same",
"dir",
",",
"and",
"samsung",
"'",
"s",
"rfs",
"has",
"a",
"bug",
"that",
"after",
"the",
"13",
"0",
"0",
"0th",
"creation",
"fails",
"so",
"if",
"cache",
"is",
"not",
"already",
"in",
"expected",
"version",
"let",
"'",
"s",
"destroy",
"everything",
"(",
"if",
"not",
"in",
"expected",
"version",
"there",
"'",
"s",
"nothing",
"to",
"reuse",
"here",
"anyway",
")"
] |
[
"private",
"void",
"recreate",
"directory",
"if",
"version",
"changes",
"(",
")",
"{",
"boolean",
"recreate",
"base",
"=",
"false",
";",
"if",
"(",
"!",
"m",
"root",
"directory",
"exists",
"(",
")",
")",
"{",
"recreate",
"base",
"=",
"true",
";",
"}",
"else",
"if",
"(",
"!",
"m",
"version",
"directory",
"exists",
"(",
")",
")",
"{",
"recreate",
"base",
"=",
"true",
";",
"file",
"tree",
"delete",
"recursively",
"(",
"m",
"root",
"directory",
")",
";",
"}",
"if",
"(",
"recreate",
"base",
")",
"{",
"try",
"{",
"file",
"utils",
"mkdirs",
"(",
"m",
"version",
"directory",
")",
";",
"}",
"catch",
"(",
"file",
"utils",
"create",
"directory",
"exception",
"e",
")",
"{",
"/",
"/",
"not",
"the",
"end",
"of",
"the",
"world",
",",
"when",
"saving",
"files",
"we",
"will",
"try",
"to",
"create",
"missing",
"parent",
"dirs",
"m",
"cache",
"error",
"logger",
"log",
"error",
"(",
"cache",
"error",
"logger",
"cache",
"error",
"category",
"write",
"create",
"dir",
",",
"tag",
",",
"\"",
"version",
"directory",
"could",
"not",
"be",
"created",
":",
"\"",
"+",
"m",
"version",
"directory",
",",
"null",
")",
";",
"}",
"}",
"}"
] |
[
"the",
"remote",
"cluster",
"license",
"info",
"this",
"method",
"should",
"only",
"be",
"invoked",
"if",
"this",
"instance",
"represents",
"a",
"failing",
"license",
"check"
] |
[
"public",
"remote",
"cluster",
"license",
"info",
"remote",
"cluster",
"license",
"info",
"(",
")",
"{",
"assert",
"is",
"success",
"(",
")",
"=",
"=",
"false",
";",
"return",
"remote",
"cluster",
"license",
"info",
";",
"}"
] |
[
"make",
"sure",
"{",
"@",
"link",
"resource",
"plugin",
"manager",
"}",
"is",
"initialized",
"during",
"nm",
"start",
"up"
] |
[
"public",
"void",
"test",
"resource",
"plugin",
"manager",
"initialization",
"(",
")",
"throws",
"exception",
"{",
"final",
"resource",
"plugin",
"manager",
"rpm",
"=",
"stub",
"resource",
"pluginmanager",
"(",
")",
";",
"nm",
"=",
"new",
"resource",
"plugin",
"mock",
"n",
"m",
"(",
"rpm",
")",
";",
"nm",
"init",
"(",
"conf",
")",
";",
"verify",
"(",
"rpm",
")",
"initialize",
"(",
"any",
"(",
"context",
"class",
")",
")",
";",
"}"
] |
[
"script",
"to",
"modify",
"the",
"documents",
"before",
"they",
"are",
"processed"
] |
[
"public",
"self",
"script",
"(",
"script",
"script",
")",
"{",
"request",
"set",
"script",
"(",
"script",
")",
";",
"return",
"self",
"(",
")",
";",
"}"
] |
[
"unregisters",
"from",
"the",
"resource",
"manager",
"and",
"stops",
"the",
"request",
"handler",
"thread"
] |
[
"public",
"finish",
"application",
"master",
"response",
"finish",
"application",
"master",
"(",
"finish",
"application",
"master",
"request",
"request",
")",
"throws",
"yarn",
"exception",
",",
"i",
"o",
"exception",
"{",
"if",
"(",
"this",
"user",
"ugi",
"=",
"=",
"null",
")",
"{",
"if",
"(",
"this",
"connection",
"initiated",
")",
"{",
"/",
"/",
"this",
"is",
"possible",
"if",
"the",
"async",
"launch",
"u",
"a",
"m",
"is",
"still",
"/",
"/",
"blocked",
"and",
"retrying",
"return",
"a",
"dummy",
"response",
"in",
"this",
"case",
"log",
"warn",
"(",
"\"",
"unmanaged",
"am",
"still",
"not",
"successfully",
"launched",
"/",
"registered",
"yet",
"\"",
"+",
"\"",
"stopping",
"the",
"uam",
"heartbeat",
"thread",
"anyways",
"\"",
")",
";",
"return",
"finish",
"application",
"master",
"response",
"new",
"instance",
"(",
"false",
")",
";",
"}",
"else",
"{",
"throw",
"new",
"yarn",
"exception",
"(",
"\"",
"finish",
"application",
"master",
"should",
"not",
"\"",
"+",
"\"",
"be",
"called",
"before",
"create",
"and",
"register",
"\"",
")",
";",
"}",
"}",
"finish",
"application",
"master",
"response",
"response",
"=",
"this",
"rm",
"proxy",
"relayer",
"finish",
"application",
"master",
"(",
"request",
")",
";",
"if",
"(",
"response",
"get",
"is",
"unregistered",
"(",
")",
")",
"{",
"shut",
"down",
"connections",
"(",
")",
";",
"}",
"return",
"response",
";",
"}"
] |
[
"creates",
"a",
"lazy",
"{",
"@",
"link",
"execution",
"config",
"}",
"for",
"the",
"{",
"@",
"link",
"kryo",
"serializer",
"}",
"with",
"information",
"from",
"existing",
"{",
"@",
"link",
"execution",
"config",
"}",
"(",
"if",
"available",
")",
"enriched",
"with",
"table",
"{",
"@",
"link",
"readable",
"config",
"}"
] |
[
"private",
"static",
"supplier",
"<",
"execution",
"config",
">",
"create",
"kryo",
"execution",
"config",
"(",
"class",
"loader",
"class",
"loader",
",",
"readable",
"config",
"config",
",",
"execution",
"config",
"execution",
"config",
")",
"{",
"return",
"(",
")",
"-",
">",
"{",
"final",
"execution",
"config",
"new",
"execution",
"config",
"=",
"new",
"execution",
"config",
"(",
")",
";",
"if",
"(",
"execution",
"config",
"!",
"=",
"null",
")",
"{",
"execution",
"config",
"get",
"default",
"kryo",
"serializers",
"(",
")",
"for",
"each",
"(",
"(",
"c",
",",
"s",
")",
"-",
">",
"new",
"execution",
"config",
"add",
"default",
"kryo",
"serializer",
"(",
"c",
",",
"s",
"get",
"serializer",
"(",
")",
")",
")",
";",
"execution",
"config",
"get",
"default",
"kryo",
"serializer",
"classes",
"(",
")",
"for",
"each",
"(",
"new",
"execution",
"config",
":",
":",
"add",
"default",
"kryo",
"serializer",
")",
";",
"execution",
"config",
"get",
"registered",
"kryo",
"types",
"(",
")",
"for",
"each",
"(",
"new",
"execution",
"config",
":",
":",
"register",
"kryo",
"type",
")",
";",
"execution",
"config",
"get",
"registered",
"types",
"with",
"kryo",
"serializer",
"classes",
"(",
")",
"for",
"each",
"(",
"new",
"execution",
"config",
":",
":",
"register",
"type",
"with",
"kryo",
"serializer",
")",
";",
"execution",
"config",
"get",
"registered",
"types",
"with",
"kryo",
"serializers",
"(",
")",
"for",
"each",
"(",
"(",
"c",
",",
"s",
")",
"-",
">",
"new",
"execution",
"config",
"register",
"type",
"with",
"kryo",
"serializer",
"(",
"c",
",",
"s",
"get",
"serializer",
"(",
")",
")",
")",
";",
"}",
"new",
"execution",
"config",
"configure",
"(",
"config",
",",
"class",
"loader",
")",
";",
"return",
"new",
"execution",
"config",
";",
"}",
";",
"}"
] |
[
"opens",
"a",
"new",
"output",
"stream",
"to",
"the",
"given",
"blob",
"(",
"page",
"or",
"block",
"blob",
")",
"to",
"populate",
"it",
"from",
"scratch",
"with",
"data"
] |
[
"private",
"output",
"stream",
"open",
"output",
"stream",
"(",
"final",
"cloud",
"blob",
"wrapper",
"blob",
")",
"throws",
"storage",
"exception",
"{",
"if",
"(",
"blob",
"instanceof",
"cloud",
"page",
"blob",
"wrapper",
")",
"{",
"return",
"new",
"page",
"blob",
"output",
"stream",
"(",
"(",
"cloud",
"page",
"blob",
"wrapper",
")",
"blob",
",",
"get",
"instrumented",
"context",
"(",
")",
",",
"session",
"configuration",
")",
";",
"}",
"else",
"{",
"/",
"/",
"handle",
"both",
"clould",
"block",
"blob",
"wrapper",
"impl",
"and",
"(",
"only",
"for",
"the",
"test",
"code",
"path",
")",
"/",
"/",
"mock",
"cloud",
"block",
"blob",
"wrapper",
"return",
"(",
"(",
"cloud",
"block",
"blob",
"wrapper",
")",
"blob",
")",
"open",
"output",
"stream",
"(",
"get",
"upload",
"options",
"(",
")",
",",
"get",
"instrumented",
"context",
"(",
")",
")",
";",
"}",
"}"
] |
[
"pruning",
"the",
"useless",
"checkpoints",
",",
"it",
"should",
"be",
"called",
"only",
"when",
"holding",
"the",
"{",
"@",
"link",
"#",
"lock",
"}"
] |
[
"private",
"void",
"prune",
"checkpoints",
"(",
"long",
"predicate",
"pruning",
"checker",
",",
"boolean",
"break",
"once",
"checker",
"false",
")",
"{",
"final",
"list",
"<",
"map",
"entry",
"<",
"long",
",",
"task",
"state",
"snapshot",
">",
">",
"to",
"remove",
"=",
"new",
"array",
"list",
"<",
">",
"(",
")",
";",
"synchronized",
"(",
"lock",
")",
"{",
"iterator",
"<",
"map",
"entry",
"<",
"long",
",",
"task",
"state",
"snapshot",
">",
">",
"entry",
"iterator",
"=",
"stored",
"task",
"state",
"by",
"checkpoint",
"i",
"d",
"entry",
"set",
"(",
")",
"iterator",
"(",
")",
";",
"while",
"(",
"entry",
"iterator",
"has",
"next",
"(",
")",
")",
"{",
"map",
"entry",
"<",
"long",
",",
"task",
"state",
"snapshot",
">",
"snapshot",
"entry",
"=",
"entry",
"iterator",
"next",
"(",
")",
";",
"long",
"entry",
"checkpoint",
"id",
"=",
"snapshot",
"entry",
"get",
"key",
"(",
")",
";",
"if",
"(",
"pruning",
"checker",
"test",
"(",
"entry",
"checkpoint",
"id",
")",
")",
"{",
"to",
"remove",
"add",
"(",
"snapshot",
"entry",
")",
";",
"entry",
"iterator",
"remove",
"(",
")",
";",
"}",
"else",
"if",
"(",
"break",
"once",
"checker",
"false",
")",
"{",
"break",
";",
"}",
"}",
"}",
"async",
"discard",
"local",
"state",
"for",
"collection",
"(",
"to",
"remove",
")",
";",
"}"
] |
[
"called",
"by",
"specific",
"{",
"@",
"link",
"leader",
"election",
"driver",
"}",
"when",
"the",
"leadership",
"is",
"revoked"
] |
[
"void",
"on",
"revoke",
"leadership",
"(",
")",
";"
] |
[
"returns",
"a",
"parsed",
"config",
"must",
"have",
"been",
"returned",
"via",
"service",
"config",
"parser",
"parse",
"service",
"config",
"(",
")",
"get",
"config",
"(",
")"
] |
[
"public",
"object",
"get",
"config",
"(",
")",
"{",
"return",
"config",
";",
"}"
] |
[
"create",
"response",
"entity",
"for",
"authn",
"failure",
"response"
] |
[
"public",
"static",
"response",
"entity",
"<",
"string",
">",
"create",
"response",
"entity",
"for",
"authn",
"failure",
"(",
"final",
"authentication",
"exception",
"e",
",",
"final",
"http",
"servlet",
"request",
"request",
",",
"final",
"application",
"context",
"application",
"context",
")",
"{",
"try",
"{",
"val",
"authn",
"exceptions",
"=",
"e",
"get",
"handler",
"errors",
"(",
")",
"values",
"(",
")",
"stream",
"(",
")",
"map",
"(",
"ex",
"-",
">",
"map",
"exception",
"to",
"message",
"(",
"e",
",",
"request",
",",
"application",
"context",
",",
"ex",
")",
")",
"collect",
"(",
"collectors",
"to",
"list",
"(",
")",
")",
";",
"if",
"(",
"authn",
"exceptions",
"is",
"empty",
"(",
")",
")",
"{",
"authn",
"exceptions",
"add",
"(",
"map",
"exception",
"to",
"message",
"(",
"e",
",",
"request",
",",
"application",
"context",
",",
"e",
")",
")",
";",
"}",
"val",
"errors",
"map",
"=",
"new",
"hash",
"map",
"<",
"string",
",",
"list",
"<",
"string",
">",
">",
"(",
"1",
")",
";",
"errors",
"map",
"put",
"(",
"\"",
"authentication",
"exceptions",
"\"",
",",
"authn",
"exceptions",
")",
";",
"logger",
"warn",
"(",
"\"",
"[",
"{",
"}",
"]",
"caused",
"by",
":",
"[",
"{",
"}",
"]",
"\"",
",",
"e",
"get",
"message",
"(",
")",
",",
"authn",
"exceptions",
")",
";",
"return",
"new",
"response",
"entity",
"<",
">",
"(",
"mapper",
"writer",
"with",
"default",
"pretty",
"printer",
"(",
")",
"write",
"value",
"as",
"string",
"(",
"errors",
"map",
")",
",",
"http",
"status",
"unauthorized",
")",
";",
"}",
"catch",
"(",
"final",
"json",
"processing",
"exception",
"exception",
")",
"{",
"logging",
"utils",
"error",
"(",
"logger",
",",
"e",
")",
";",
"return",
"new",
"response",
"entity",
"<",
">",
"(",
"e",
"get",
"message",
"(",
")",
",",
"http",
"status",
"internal",
"server",
"error",
")",
";",
"}",
"}"
] |
[
"get",
"map",
"map",
"string"
] |
[
"public",
"map",
"<",
"string",
",",
"map",
"<",
"string",
",",
"string",
">",
">",
"get",
"map",
"map",
"string",
"(",
")",
"{",
"return",
"map",
"map",
"string",
";",
"}"
] |
[
"returns",
"whether",
"the",
"append",
"range",
"should",
"use",
"the",
"block",
"size",
"range"
] |
[
"boolean",
"should",
"append",
"use",
"block",
"size",
"(",
")",
"{",
"range",
"<",
"long",
">",
"append",
"range",
"=",
"get",
"append",
"size",
"(",
")",
";",
"if",
"(",
"append",
"range",
"=",
"=",
"null",
"|",
"|",
"(",
"append",
"range",
"get",
"lower",
"(",
")",
"=",
"=",
"append",
"range",
"get",
"upper",
"(",
")",
"&",
"&",
"(",
"append",
"range",
"get",
"upper",
"(",
")",
"=",
"=",
"long",
"max",
"value",
")",
")",
")",
"{",
"return",
"true",
";",
"}",
"return",
"false",
";",
"}"
] |
[
"for",
"optional",
"fields",
":",
"definition",
"level",
"=",
"=",
"max",
"definition",
"level",
"=",
">",
"value",
"is",
"defined",
"definition",
"level",
"=",
"=",
"max",
"definition",
"level",
"-",
"1",
"=",
">",
"value",
"is",
"null",
"definition",
"level",
"<",
"max",
"definition",
"level",
"-",
"1",
"=",
">",
"value",
"does",
"not",
"exist",
",",
"because",
"one",
"of",
"its",
"optional",
"parent",
"fields",
"is",
"null"
] |
[
"public",
"static",
"boolean",
"is",
"value",
"null",
"(",
"boolean",
"required",
",",
"int",
"definition",
"level",
",",
"int",
"max",
"definition",
"level",
")",
"{",
"return",
"!",
"required",
"&",
"&",
"(",
"definition",
"level",
"=",
"=",
"max",
"definition",
"level",
"-",
"1",
")",
";",
"}"
] |
[
"initialize",
"the",
"capacity",
"information",
"of",
"the",
"group",
"if",
"the",
"quota",
"is",
"reached",
",",
"the",
"capacity",
"will",
"be",
"automatically",
"expanded",
"to",
"reduce",
"the",
"operation",
"and",
"maintenance",
"cost"
] |
[
"public",
"boolean",
"init",
"group",
"capacity",
"(",
"string",
"group",
")",
"{",
"return",
"init",
"group",
"capacity",
"(",
"group",
",",
"null",
",",
"null",
",",
"null",
",",
"null",
")",
";",
"}"
] |
[
"returns",
"the",
"appropriate",
"{",
"@",
"code",
"filled",
"-",
"new",
"-",
"array",
"}",
"rop",
"for",
"the",
"given",
"type",
"the",
"result",
"may",
"be",
"a",
"shared",
"instance"
] |
[
"public",
"static",
"rop",
"op",
"filled",
"new",
"array",
"(",
"type",
"bearer",
"array",
"type",
",",
"int",
"count",
")",
"{",
"type",
"type",
"=",
"array",
"type",
"get",
"type",
"(",
")",
";",
"type",
"element",
"type",
"=",
"type",
"get",
"component",
"type",
"(",
")",
";",
"if",
"(",
"element",
"type",
"is",
"category",
"2",
"(",
")",
")",
"{",
"return",
"throw",
"bad",
"type",
"(",
"array",
"type",
")",
";",
"}",
"if",
"(",
"count",
"<",
"0",
")",
"{",
"throw",
"new",
"illegal",
"argument",
"exception",
"(",
"\"",
"count",
"<",
"0",
"\"",
")",
";",
"}",
"std",
"type",
"list",
"source",
"types",
"=",
"new",
"std",
"type",
"list",
"(",
"count",
")",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"count",
";",
"i",
"+",
"+",
")",
"{",
"source",
"types",
"set",
"(",
"i",
",",
"element",
"type",
")",
";",
"}",
"/",
"/",
"note",
":",
"the",
"resulting",
"rop",
"is",
"considered",
"call",
"-",
"like",
"return",
"new",
"rop",
"(",
"reg",
"ops",
"filled",
"new",
"array",
",",
"source",
"types",
",",
"exceptions",
"list",
"error",
")",
";",
"}"
] |
[
"specify",
"the",
"number",
"of",
"seconds",
"to",
"wait",
"until",
"http",
"exchanges",
"have",
"completed",
"when",
"shutting",
"down",
"the",
"http",
"server",
"default",
"is",
"0",
"only",
"applicable",
"for",
"a",
"locally",
"configured",
"http",
"server",
"ignored",
"when",
"the",
"{",
"@",
"link",
"#",
"set",
"server",
"\"",
"server",
"\"",
"}",
"property",
"has",
"been",
"specified"
] |
[
"public",
"void",
"set",
"shutdown",
"delay",
"(",
"int",
"shutdown",
"delay",
")",
"{",
"this",
"shutdown",
"delay",
"=",
"shutdown",
"delay",
";",
"}"
] |
[
"gets",
"a",
"string",
"representation",
"of",
"a",
"range"
] |
[
"public",
"static",
"string",
"to",
"string",
"(",
"protos",
"value",
"range",
"range",
")",
"{",
"check",
"not",
"null",
"(",
"range",
")",
";",
"return",
"string",
"format",
"(",
"\"",
"%",
"d",
"-",
"%",
"d",
"\"",
",",
"range",
"get",
"begin",
"(",
")",
",",
"range",
"get",
"end",
"(",
")",
")",
";",
"}"
] |
[
"returns",
"the",
"host",
"of",
"the",
"mini",
"kdc"
] |
[
"public",
"string",
"get",
"host",
"(",
")",
"{",
"return",
"conf",
"get",
"property",
"(",
"kdc",
"bind",
"address",
")",
";",
"}"
] |
[
"set",
"header",
"parameters",
"to",
"the",
"request",
"builder",
",",
"including",
"default",
"headers"
] |
[
"public",
"void",
"process",
"header",
"params",
"(",
"map",
"<",
"string",
",",
"string",
">",
"header",
"params",
",",
"request",
"builder",
"req",
"builder",
")",
"{",
"for",
"(",
"entry",
"<",
"string",
",",
"string",
">",
"param",
":",
"header",
"params",
"entry",
"set",
"(",
")",
")",
"{",
"req",
"builder",
"header",
"(",
"param",
"get",
"key",
"(",
")",
",",
"parameter",
"to",
"string",
"(",
"param",
"get",
"value",
"(",
")",
")",
")",
";",
"}",
"for",
"(",
"entry",
"<",
"string",
",",
"string",
">",
"header",
":",
"default",
"header",
"map",
"entry",
"set",
"(",
")",
")",
"{",
"if",
"(",
"!",
"header",
"params",
"contains",
"key",
"(",
"header",
"get",
"key",
"(",
")",
")",
")",
"{",
"req",
"builder",
"header",
"(",
"header",
"get",
"key",
"(",
")",
",",
"parameter",
"to",
"string",
"(",
"header",
"get",
"value",
"(",
")",
")",
")",
";",
"}",
"}",
"}"
] |
[
"model",
"tests",
"for",
"big",
"cat",
"all",
"of"
] |
[
"public",
"void",
"test",
"big",
"cat",
"all",
"of",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"big",
"cat",
"all",
"of",
"}"
] |
[
"path",
"parameters",
"associated",
"with",
"this",
"path",
"segment"
] |
[
"multi",
"value",
"map",
"<",
"string",
",",
"string",
">",
"parameters",
"(",
")",
";"
] |
[
"find",
"the",
"fields",
"constant",
"that",
"matches",
"field",
"id",
",",
"or",
"null",
"if",
"its",
"not",
"found"
] |
[
"public",
"static",
"fields",
"find",
"by",
"thrift",
"id",
"(",
"int",
"field",
"id",
")",
"{",
"switch",
"(",
"field",
"id",
")",
"{",
"case",
"1",
":",
"/",
"/",
"id",
"return",
"id",
";",
"default",
":",
"return",
"null",
";",
"}",
"}"
] |
[
"convert",
"the",
"given",
"object",
"to",
"string",
"with",
"each",
"line",
"indented",
"by",
"4",
"spaces",
"(",
"except",
"the",
"first",
"line",
")"
] |
[
"private",
"string",
"to",
"indented",
"string",
"(",
"object",
"o",
")",
"{",
"if",
"(",
"o",
"=",
"=",
"null",
")",
"{",
"return",
"\"",
"null",
"\"",
";",
"}",
"return",
"o",
"to",
"string",
"(",
")",
"replace",
"(",
"\"",
"\\",
"n",
"\"",
",",
"\"",
"\\",
"n",
"\"",
")",
";",
"}"
] |
[
"sets",
"the",
"minimum",
"and",
"preferred",
"resources",
"for",
"this",
"stream",
"transformation"
] |
[
"public",
"void",
"set",
"resources",
"(",
"resource",
"spec",
"min",
"resources",
",",
"resource",
"spec",
"preferred",
"resources",
")",
"{",
"operator",
"validation",
"utils",
"validate",
"min",
"and",
"preferred",
"resources",
"(",
"min",
"resources",
",",
"preferred",
"resources",
")",
";",
"this",
"min",
"resources",
"=",
"check",
"not",
"null",
"(",
"min",
"resources",
")",
";",
"this",
"preferred",
"resources",
"=",
"check",
"not",
"null",
"(",
"preferred",
"resources",
")",
";",
"}"
] |
[
"returns",
"n",
"m",
"token",
",",
"null",
"if",
"absent",
"only",
"the",
"singleton",
"obtained",
"from",
"{",
"@",
"link",
"#",
"get",
"singleton",
"(",
")",
"}",
"is",
"looked",
"at",
"for",
"the",
"tokens",
"if",
"you",
"are",
"using",
"your",
"own",
"n",
"m",
"token",
"cache",
"that",
"is",
"different",
"from",
"the",
"singleton",
",",
"use",
"{",
"@",
"link",
"#",
"get",
"token",
"(",
"string",
")",
"}"
] |
[
"public",
"static",
"token",
"get",
"n",
"m",
"token",
"(",
"string",
"node",
"addr",
")",
"{",
"return",
"nm",
"token",
"cache",
"get",
"token",
"(",
"node",
"addr",
")",
";",
"}"
] |
[
"test",
"the",
"property",
"'",
"bool",
"item",
"'"
] |
[
"public",
"void",
"bool",
"item",
"test",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"bool",
"item",
"}"
] |
[
"returns",
"all",
"of",
"the",
"concrete",
"indices",
"that",
"are",
"open",
"and",
"not",
"hidden"
] |
[
"public",
"string",
"[",
"]",
"get",
"concrete",
"visible",
"open",
"indices",
"(",
")",
"{",
"return",
"visible",
"open",
"indices",
";",
"}"
] |
[
"returns",
"a",
"java",
"io",
"file",
"representation",
"of",
"this",
"path",
"caveat",
":",
"the",
"result",
"may",
"be",
"useless",
"if",
"this",
"path",
"'",
"s",
"get",
"file",
"system",
"(",
")",
"is",
"not",
"the",
"unix",
"filesystem"
] |
[
"public",
"file",
"get",
"path",
"file",
"(",
")",
"{",
"return",
"new",
"file",
"(",
"get",
"path",
"string",
"(",
")",
")",
";",
"}"
] |
[
"convert",
"data",
"id"
] |
[
"private",
"string",
"convert",
"data",
"id",
"(",
"string",
"raw",
"data",
"id",
")",
"{",
"if",
"(",
"raw",
"data",
"id",
"ends",
"with",
"(",
"special",
"key",
"grouplist",
")",
")",
"{",
"string",
"suffix",
"=",
"string",
"utils",
"remove",
"end",
"(",
"raw",
"data",
"id",
",",
"dot",
"+",
"special",
"key",
"grouplist",
")",
";",
"/",
"/",
"change",
"the",
"format",
"of",
"default",
"grouplist",
"to",
"grouplist",
"default",
"return",
"service",
"prefix",
"+",
"dot",
"+",
"special",
"key",
"grouplist",
"+",
"dot",
"+",
"suffix",
";",
"}",
"return",
"seata",
"prefix",
"+",
"dot",
"+",
"raw",
"data",
"id",
";",
"}"
] |
[
"specifies",
"the",
"types",
"for",
"the",
"csv",
"fields",
"this",
"method",
"parses",
"the",
"csv",
"data",
"to",
"a",
"18",
"-",
"tuple",
"which",
"has",
"fields",
"of",
"the",
"specified",
"types",
"this",
"method",
"is",
"overloaded",
"for",
"each",
"possible",
"length",
"of",
"the",
"tuples",
"to",
"support",
"type",
"safe",
"creation",
"of",
"data",
"sets",
"through",
"csv",
"parsing"
] |
[
"public",
"<",
"t0",
",",
"t1",
",",
"t2",
",",
"t3",
",",
"t4",
",",
"t5",
",",
"t6",
",",
"t7",
",",
"t8",
",",
"t9",
",",
"t10",
",",
"t11",
",",
"t12",
",",
"t13",
",",
"t14",
",",
"t15",
",",
"t16",
",",
"t17",
">",
"data",
"source",
"<",
"tuple",
"1",
"8",
"<",
"t0",
",",
"t1",
",",
"t2",
",",
"t3",
",",
"t4",
",",
"t5",
",",
"t6",
",",
"t7",
",",
"t8",
",",
"t9",
",",
"t10",
",",
"t11",
",",
"t12",
",",
"t13",
",",
"t14",
",",
"t15",
",",
"t16",
",",
"t17",
">",
">",
"types",
"(",
"class",
"<",
"t0",
">",
"type",
"0",
",",
"class",
"<",
"t1",
">",
"type",
"1",
",",
"class",
"<",
"t2",
">",
"type",
"2",
",",
"class",
"<",
"t3",
">",
"type",
"3",
",",
"class",
"<",
"t4",
">",
"type",
"4",
",",
"class",
"<",
"t5",
">",
"type",
"5",
",",
"class",
"<",
"t6",
">",
"type",
"6",
",",
"class",
"<",
"t7",
">",
"type",
"7",
",",
"class",
"<",
"t8",
">",
"type",
"8",
",",
"class",
"<",
"t9",
">",
"type",
"9",
",",
"class",
"<",
"t10",
">",
"type",
"1",
"0",
",",
"class",
"<",
"t11",
">",
"type",
"1",
"1",
",",
"class",
"<",
"t12",
">",
"type",
"1",
"2",
",",
"class",
"<",
"t13",
">",
"type",
"1",
"3",
",",
"class",
"<",
"t14",
">",
"type",
"1",
"4",
",",
"class",
"<",
"t15",
">",
"type",
"1",
"5",
",",
"class",
"<",
"t16",
">",
"type",
"1",
"6",
",",
"class",
"<",
"t17",
">",
"type",
"1",
"7",
")",
"{",
"tuple",
"type",
"info",
"<",
"tuple",
"1",
"8",
"<",
"t0",
",",
"t1",
",",
"t2",
",",
"t3",
",",
"t4",
",",
"t5",
",",
"t6",
",",
"t7",
",",
"t8",
",",
"t9",
",",
"t10",
",",
"t11",
",",
"t12",
",",
"t13",
",",
"t14",
",",
"t15",
",",
"t16",
",",
"t17",
">",
">",
"types",
"=",
"tuple",
"type",
"info",
"get",
"basic",
"and",
"basic",
"value",
"tuple",
"type",
"info",
"(",
"type",
"0",
",",
"type",
"1",
",",
"type",
"2",
",",
"type",
"3",
",",
"type",
"4",
",",
"type",
"5",
",",
"type",
"6",
",",
"type",
"7",
",",
"type",
"8",
",",
"type",
"9",
",",
"type",
"1",
"0",
",",
"type",
"1",
"1",
",",
"type",
"1",
"2",
",",
"type",
"1",
"3",
",",
"type",
"1",
"4",
",",
"type",
"1",
"5",
",",
"type",
"1",
"6",
",",
"type",
"1",
"7",
")",
";",
"csv",
"input",
"format",
"<",
"tuple",
"1",
"8",
"<",
"t0",
",",
"t1",
",",
"t2",
",",
"t3",
",",
"t4",
",",
"t5",
",",
"t6",
",",
"t7",
",",
"t8",
",",
"t9",
",",
"t10",
",",
"t11",
",",
"t12",
",",
"t13",
",",
"t14",
",",
"t15",
",",
"t16",
",",
"t17",
">",
">",
"input",
"format",
"=",
"new",
"tuple",
"csv",
"input",
"format",
"<",
"tuple",
"1",
"8",
"<",
"t0",
",",
"t1",
",",
"t2",
",",
"t3",
",",
"t4",
",",
"t5",
",",
"t6",
",",
"t7",
",",
"t8",
",",
"t9",
",",
"t10",
",",
"t11",
",",
"t12",
",",
"t13",
",",
"t14",
",",
"t15",
",",
"t16",
",",
"t17",
">",
">",
"(",
"path",
",",
"types",
",",
"this",
"included",
"mask",
")",
";",
"configure",
"input",
"format",
"(",
"input",
"format",
")",
";",
"return",
"new",
"data",
"source",
"<",
"tuple",
"1",
"8",
"<",
"t0",
",",
"t1",
",",
"t2",
",",
"t3",
",",
"t4",
",",
"t5",
",",
"t6",
",",
"t7",
",",
"t8",
",",
"t9",
",",
"t10",
",",
"t11",
",",
"t12",
",",
"t13",
",",
"t14",
",",
"t15",
",",
"t16",
",",
"t17",
">",
">",
"(",
"execution",
"context",
",",
"input",
"format",
",",
"types",
",",
"utils",
"get",
"call",
"location",
"name",
"(",
")",
")",
";",
"}"
] |
[
"get",
"the",
"name",
"of",
"the",
"property",
"being",
"changed"
] |
[
"public",
"string",
"get",
"property",
"name",
"(",
")",
"{",
"return",
"property",
"name",
";",
"}"
] |
[
"verify",
"empty",
"moved",
"blocks",
"reporting",
"queue"
] |
[
"public",
"void",
"test",
"no",
"block",
"movement",
"attempt",
"finished",
"report",
"added",
"(",
")",
"throws",
"exception",
"{",
"long",
"item",
"=",
"new",
"long",
"(",
"1234",
")",
";",
"block",
"block",
"=",
"new",
"block",
"(",
"item",
")",
";",
"datanode",
"info",
"dn",
"info",
"=",
"d",
"f",
"s",
"test",
"util",
"get",
"local",
"datanode",
"info",
"(",
"9867",
")",
";",
"set",
"<",
"storage",
"type",
"node",
"pair",
">",
"locs",
"=",
"new",
"hash",
"set",
"<",
">",
"(",
")",
";",
"locs",
"add",
"(",
"new",
"storage",
"type",
"node",
"pair",
"(",
"storage",
"type",
"archive",
",",
"dn",
"info",
")",
")",
";",
"map",
"<",
"block",
",",
"set",
"<",
"storage",
"type",
"node",
"pair",
">",
">",
"blocks",
"map",
"=",
"new",
"hash",
"map",
"<",
">",
"(",
")",
";",
"blocks",
"map",
"put",
"(",
"block",
",",
"locs",
")",
";",
"bsm",
"attempted",
"items",
"add",
"(",
"0l",
",",
"0l",
",",
"0l",
",",
"blocks",
"map",
",",
"0",
")",
";",
"assert",
"equals",
"(",
"\"",
"shouldn",
"'",
"t",
"receive",
"result",
"\"",
",",
"0",
",",
"bsm",
"attempted",
"items",
"get",
"movement",
"finished",
"blocks",
"count",
"(",
")",
")",
";",
"assert",
"equals",
"(",
"\"",
"item",
"doesn",
"'",
"t",
"exist",
"in",
"the",
"attempted",
"list",
"\"",
",",
"1",
",",
"bsm",
"attempted",
"items",
"get",
"attempted",
"items",
"count",
"(",
")",
")",
";",
"}"
] |
[
"creates",
"a",
"{",
"@",
"link",
"reentrant",
"lock",
"}",
"with",
"the",
"given",
"fairness",
"policy",
"and",
"rank",
"the",
"values",
"returned",
"by",
"{",
"@",
"link",
"enum",
"#",
"get",
"declaring",
"class",
"(",
")",
"}",
"and",
"{",
"@",
"link",
"enum",
"#",
"name",
"(",
")",
"}",
"are",
"used",
"to",
"describe",
"the",
"lock",
"in",
"warning",
"or",
"exception",
"output"
] |
[
"public",
"reentrant",
"lock",
"new",
"reentrant",
"lock",
"(",
"e",
"rank",
",",
"boolean",
"fair",
")",
"{",
"return",
"policy",
"=",
"=",
"policies",
"disabled",
"?",
"new",
"reentrant",
"lock",
"(",
"fair",
")",
":",
"new",
"cycle",
"detecting",
"reentrant",
"lock",
"(",
"lock",
"graph",
"nodes",
"get",
"(",
"rank",
")",
",",
"fair",
")",
";",
"}"
] |
[
"returns",
"an",
"immutable",
"set",
"containing",
"each",
"of",
"{",
"@",
"code",
"elements",
"}",
",",
"minus",
"duplicates",
",",
"in",
"the",
"order",
"each",
"appears",
"first",
"in",
"the",
"source",
"collection",
"<",
"b",
">",
"performance",
"note",
":",
"<",
"b",
">",
"this",
"method",
"will",
"sometimes",
"recognize",
"that",
"the",
"actual",
"copy",
"operation",
"is",
"unnecessary",
";",
"for",
"example",
",",
"{",
"@",
"code",
"copy",
"of",
"(",
"copy",
"of",
"(",
"an",
"array",
"list",
")",
")",
"}",
"will",
"copy",
"the",
"data",
"only",
"once",
"this",
"reduces",
"the",
"expense",
"of",
"habitually",
"making",
"defensive",
"copies",
"at",
"api",
"boundaries",
"however",
",",
"the",
"precise",
"conditions",
"for",
"skipping",
"the",
"copy",
"operation",
"are",
"undefined"
] |
[
"public",
"static",
"<",
"e",
">",
"immutable",
"set",
"<",
"e",
">",
"copy",
"of",
"(",
"collection",
"<",
"?",
"extends",
"e",
">",
"elements",
")",
"{",
"/",
"*",
"*",
"todo",
"(",
"lowasser",
")",
":",
"consider",
"checking",
"for",
"immutable",
"as",
"list",
"here",
"*",
"todo",
"(",
"lowasser",
")",
":",
"consider",
"checking",
"for",
"multiset",
"here",
"*",
"/",
"/",
"/",
"don",
"'",
"t",
"refer",
"to",
"immutable",
"sorted",
"set",
"by",
"name",
"so",
"it",
"won",
"'",
"t",
"pull",
"in",
"all",
"that",
"code",
"if",
"(",
"elements",
"instanceof",
"immutable",
"set",
"&",
"&",
"!",
"(",
"elements",
"instanceof",
"sorted",
"set",
")",
")",
"{",
"@",
"suppress",
"warnings",
"(",
"\"",
"unchecked",
"\"",
")",
"/",
"/",
"all",
"supported",
"methods",
"are",
"covariant",
"immutable",
"set",
"<",
"e",
">",
"set",
"=",
"(",
"immutable",
"set",
"<",
"e",
">",
")",
"elements",
";",
"if",
"(",
"!",
"set",
"is",
"partial",
"view",
"(",
")",
")",
"{",
"return",
"set",
";",
"}",
"}",
"else",
"if",
"(",
"elements",
"instanceof",
"enum",
"set",
")",
"{",
"return",
"copy",
"of",
"enum",
"set",
"(",
"(",
"enum",
"set",
")",
"elements",
")",
";",
"}",
"object",
"[",
"]",
"array",
"=",
"elements",
"to",
"array",
"(",
")",
";",
"if",
"(",
"elements",
"instanceof",
"set",
")",
"{",
"/",
"/",
"assume",
"probably",
"no",
"duplicates",
"(",
"though",
"it",
"might",
"be",
"using",
"different",
"equality",
"semantics",
")",
"return",
"construct",
"(",
"array",
"length",
",",
"array",
"length",
",",
"array",
")",
";",
"}",
"else",
"{",
"return",
"construct",
"unknown",
"duplication",
"(",
"array",
"length",
",",
"array",
")",
";",
"}",
"}"
] |
[
"this",
"is",
"called",
"after",
"reloading",
"the",
"allocation",
"configuration",
"when",
"the",
"scheduler",
"is",
"reinitialized",
"checks",
"to",
"see",
"whether",
"any",
"non",
"-",
"runnable",
"applications",
"become",
"runnable",
"now",
"that",
"the",
"max",
"running",
"apps",
"of",
"given",
"queue",
"has",
"been",
"changed",
"runs",
"in",
"o",
"(",
"n",
")",
"where",
"n",
"is",
"the",
"number",
"of",
"apps",
"that",
"are",
"non",
"-",
"runnable",
"and",
"in",
"the",
"queues",
"that",
"went",
"from",
"having",
"no",
"slack",
"to",
"having",
"slack"
] |
[
"public",
"void",
"update",
"runnability",
"on",
"reload",
"(",
")",
"{",
"parent",
"queue",
"root",
"queue",
"=",
"(",
"parent",
"queue",
")",
"scheduler",
"get",
"root",
"queue",
"(",
")",
";",
"list",
"<",
"list",
"<",
"fi",
"ca",
"scheduler",
"app",
">",
">",
"apps",
"now",
"maybe",
"runnable",
"=",
"new",
"array",
"list",
"<",
"list",
"<",
"fi",
"ca",
"scheduler",
"app",
">",
">",
"(",
")",
";",
"gather",
"possibly",
"runnable",
"app",
"lists",
"(",
"root",
"queue",
",",
"apps",
"now",
"maybe",
"runnable",
")",
";",
"update",
"apps",
"runnability",
"(",
"apps",
"now",
"maybe",
"runnable",
",",
"integer",
"max",
"value",
")",
";",
"}"
] |
[
"test",
"to",
"test",
"if",
"the",
"user",
"set",
"old",
"env",
"variables",
"reflect",
"in",
"the",
"child",
"processes",
"mainly",
"-",
"x",
"=",
"y",
"(",
"x",
"can",
"be",
"a",
"already",
"existing",
"env",
"variable",
"or",
"a",
"new",
"variable",
")"
] |
[
"public",
"void",
"test",
"task",
"old",
"env",
"(",
")",
"{",
"try",
"{",
"job",
"conf",
"conf",
"=",
"new",
"job",
"conf",
"(",
"mr",
"get",
"config",
"(",
")",
")",
";",
"string",
"base",
"dir",
"=",
"system",
"get",
"property",
"(",
"\"",
"test",
"build",
"data",
"\"",
",",
"\"",
"build",
"/",
"test",
"/",
"data",
"\"",
")",
";",
"/",
"/",
"initialize",
"input",
",",
"output",
"directories",
"path",
"in",
"dir",
"=",
"new",
"path",
"(",
"base",
"dir",
"+",
"\"",
"/",
"testing",
"/",
"wc",
"/",
"input",
"1",
"\"",
")",
";",
"path",
"out",
"dir",
"=",
"new",
"path",
"(",
"base",
"dir",
"+",
"\"",
"/",
"testing",
"/",
"wc",
"/",
"output",
"1",
"\"",
")",
";",
"file",
"system",
"out",
"fs",
"=",
"out",
"dir",
"get",
"file",
"system",
"(",
"conf",
")",
";",
"run",
"test",
"task",
"env",
"(",
"conf",
",",
"in",
"dir",
",",
"out",
"dir",
",",
"true",
")",
";",
"out",
"fs",
"delete",
"(",
"out",
"dir",
",",
"true",
")",
";",
"}",
"catch",
"(",
"exception",
"e",
")",
"{",
"e",
"print",
"stack",
"trace",
"(",
")",
";",
"fail",
"(",
"\"",
"exception",
"in",
"testing",
"child",
"env",
"\"",
")",
";",
"tear",
"down",
"(",
")",
";",
"}",
"}"
] |
[
"multiplies",
"the",
"vectors",
"with",
"the",
"given",
"matrix",
",",
",",
"performing",
"a",
"division",
"by",
"w",
"the",
"matrix",
"array",
"is",
"assumed",
"to",
"hold",
"a",
"4x",
"4",
"column",
"major",
"matrix",
"as",
"you",
"can",
"get",
"from",
"{",
"@",
"link",
"matrix",
"4",
"#",
"val",
"}",
"the",
"vectors",
"array",
"is",
"assumed",
"to",
"hold",
"3",
"-",
"component",
"vectors",
"offset",
"specifies",
"the",
"offset",
"into",
"the",
"array",
"where",
"the",
"x",
"-",
"component",
"of",
"the",
"first",
"vector",
"is",
"located",
"the",
"num",
"vecs",
"parameter",
"specifies",
"the",
"number",
"of",
"vectors",
"stored",
"in",
"the",
"vectors",
"array",
"the",
"stride",
"parameter",
"specifies",
"the",
"number",
"of",
"floats",
"between",
"subsequent",
"vectors",
"and",
"must",
"be",
">",
"=",
"3",
"this",
"is",
"the",
"same",
"as",
"{",
"@",
"link",
"vector",
"3",
"#",
"prj",
"(",
"matrix",
"4",
")",
"}",
"applied",
"to",
"multiple",
"vectors"
] |
[
"public",
"static",
"native",
"void",
"prj",
"(",
"float",
"[",
"]",
"mat",
",",
"float",
"[",
"]",
"vecs",
",",
"int",
"offset",
",",
"int",
"num",
"vecs",
",",
"int",
"stride",
")",
"/",
"*",
"-",
"{",
"}",
"-",
"*",
"/",
";",
"/",
"*",
"float",
"*",
"vec",
"ptr",
"=",
"vecs",
"+",
"offset",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"num",
"vecs",
";",
"i",
"+",
"+",
")",
"{",
"matrix",
"4",
"proj",
"(",
"mat",
",",
"vec",
"ptr",
")",
";",
"vec",
"ptr",
"+",
"=",
"stride",
";",
"}",
"*",
"/"
] |
[
"determine",
"if",
"request",
"has",
"errors"
] |
[
"public",
"static",
"optional",
"<",
"model",
"and",
"view",
">",
"has",
"delegation",
"request",
"failed",
"(",
"final",
"http",
"servlet",
"request",
"request",
",",
"final",
"int",
"status",
")",
"{",
"val",
"params",
"=",
"request",
"get",
"parameter",
"map",
"(",
")",
";",
"if",
"(",
"stream",
"of",
"(",
"\"",
"error",
"\"",
",",
"\"",
"error",
"code",
"\"",
",",
"\"",
"error",
"description",
"\"",
",",
"\"",
"error",
"message",
"\"",
")",
"any",
"match",
"(",
"params",
":",
":",
"contains",
"key",
")",
")",
"{",
"val",
"model",
"=",
"new",
"hash",
"map",
"<",
"string",
",",
"object",
">",
"(",
")",
";",
"if",
"(",
"params",
"contains",
"key",
"(",
"\"",
"error",
"code",
"\"",
")",
")",
"{",
"model",
"put",
"(",
"\"",
"code",
"\"",
",",
"string",
"escape",
"utils",
"escape",
"html",
"4",
"(",
"request",
"get",
"parameter",
"(",
"\"",
"error",
"code",
"\"",
")",
")",
")",
";",
"}",
"else",
"{",
"model",
"put",
"(",
"\"",
"code",
"\"",
",",
"status",
")",
";",
"}",
"model",
"put",
"(",
"\"",
"error",
"\"",
",",
"string",
"escape",
"utils",
"escape",
"html",
"4",
"(",
"request",
"get",
"parameter",
"(",
"\"",
"error",
"\"",
")",
")",
")",
";",
"model",
"put",
"(",
"\"",
"reason",
"\"",
",",
"string",
"escape",
"utils",
"escape",
"html",
"4",
"(",
"request",
"get",
"parameter",
"(",
"\"",
"error",
"reason",
"\"",
")",
")",
")",
";",
"if",
"(",
"params",
"contains",
"key",
"(",
"\"",
"error",
"description",
"\"",
")",
")",
"{",
"model",
"put",
"(",
"\"",
"description",
"\"",
",",
"string",
"escape",
"utils",
"escape",
"html",
"4",
"(",
"request",
"get",
"parameter",
"(",
"\"",
"error",
"description",
"\"",
")",
")",
")",
";",
"}",
"else",
"if",
"(",
"params",
"contains",
"key",
"(",
"\"",
"error",
"message",
"\"",
")",
")",
"{",
"model",
"put",
"(",
"\"",
"description",
"\"",
",",
"string",
"escape",
"utils",
"escape",
"html",
"4",
"(",
"request",
"get",
"parameter",
"(",
"\"",
"error",
"message",
"\"",
")",
")",
")",
";",
"}",
"model",
"put",
"(",
"cas",
"protocol",
"constants",
"parameter",
"service",
",",
"request",
"get",
"attribute",
"(",
"cas",
"protocol",
"constants",
"parameter",
"service",
")",
")",
";",
"model",
"put",
"(",
"\"",
"client",
"\"",
",",
"string",
"escape",
"utils",
"escape",
"html",
"4",
"(",
"request",
"get",
"parameter",
"(",
"\"",
"client",
"name",
"\"",
")",
")",
")",
";",
"logger",
"debug",
"(",
"\"",
"delegation",
"request",
"has",
"failed",
"details",
"are",
"[",
"{",
"}",
"]",
"\"",
",",
"model",
")",
";",
"return",
"optional",
"of",
"(",
"new",
"model",
"and",
"view",
"(",
"\"",
"cas",
"pac",
"4j",
"stop",
"webflow",
"\"",
",",
"model",
")",
")",
";",
"}",
"return",
"optional",
"empty",
"(",
")",
";",
"}"
] |
[
"this",
"test",
"validates",
"the",
"correctness",
"of",
"get",
"new",
"application",
"in",
"case",
"the",
"cluster",
"is",
"composed",
"of",
"only",
"1",
"bad",
"sub",
"cluster"
] |
[
"public",
"void",
"test",
"get",
"new",
"application",
"one",
"bad",
"s",
"c",
"(",
")",
"throws",
"yarn",
"exception",
",",
"i",
"o",
"exception",
",",
"interrupted",
"exception",
"{",
"system",
"out",
"println",
"(",
"\"",
"test",
"get",
"new",
"application",
"with",
"one",
"bad",
"sub",
"cluster",
"\"",
")",
";",
"setup",
"cluster",
"(",
"arrays",
"as",
"list",
"(",
"bad",
"2",
")",
")",
";",
"try",
"{",
"interceptor",
"get",
"new",
"application",
"(",
"get",
"new",
"application",
"request",
"new",
"instance",
"(",
")",
")",
";",
"assert",
"fail",
"(",
")",
";",
"}",
"catch",
"(",
"exception",
"e",
")",
"{",
"system",
"out",
"println",
"(",
"e",
"to",
"string",
"(",
")",
")",
";",
"assert",
"assert",
"true",
"(",
"e",
"get",
"message",
"(",
")",
"equals",
"(",
"federation",
"policy",
"utils",
"no",
"active",
"subcluster",
"available",
")",
")",
";",
"}",
"}"
] |
[
"flushes",
"out",
"to",
"all",
"replicas",
"of",
"the",
"block",
"the",
"data",
"is",
"in",
"the",
"buffers",
"of",
"the",
"d",
"ns",
"but",
"not",
"necessarily",
"in",
"the",
"dn",
"'",
"s",
"os",
"buffers",
"it",
"is",
"a",
"synchronous",
"operation",
"when",
"it",
"returns",
",",
"it",
"guarantees",
"that",
"flushed",
"data",
"become",
"visible",
"to",
"new",
"readers",
"it",
"is",
"not",
"guaranteed",
"that",
"data",
"has",
"been",
"flushed",
"to",
"persistent",
"store",
"on",
"the",
"datanode",
"block",
"allocations",
"are",
"persisted",
"on",
"namenode"
] |
[
"public",
"void",
"hflush",
"(",
")",
"throws",
"i",
"o",
"exception",
"{",
"try",
"(",
"trace",
"scope",
"ignored",
"=",
"dfs",
"client",
"new",
"path",
"trace",
"scope",
"(",
"\"",
"hflush",
"\"",
",",
"src",
")",
")",
"{",
"flush",
"or",
"sync",
"(",
"false",
",",
"enum",
"set",
"none",
"of",
"(",
"sync",
"flag",
"class",
")",
")",
";",
"}",
"}"
] |
[
"confirm",
"that",
"no",
"buffering",
"or",
"blocking",
"of",
"the",
"observable",
"on",
"next",
"calls",
"occurs",
"and",
"it",
"just",
"grabs",
"the",
"next",
"emitted",
"value",
"this",
"results",
"in",
"output",
"such",
"as",
"{",
"@",
"code",
"=",
">",
"a",
":",
"1",
"b",
":",
"2",
"c",
":",
"89",
"}"
] |
[
"public",
"void",
"no",
"buffering",
"or",
"blocking",
"of",
"sequence",
"(",
")",
"throws",
"throwable",
"{",
"int",
"repeat",
"=",
"0",
";",
"for",
"(",
";",
";",
")",
"{",
"final",
"serial",
"disposable",
"task",
"=",
"new",
"serial",
"disposable",
"(",
")",
";",
"try",
"{",
"final",
"count",
"down",
"latch",
"finished",
"=",
"new",
"count",
"down",
"latch",
"(",
"1",
")",
";",
"final",
"int",
"count",
"=",
"30",
";",
"final",
"count",
"down",
"latch",
"time",
"has",
"passed",
"=",
"new",
"count",
"down",
"latch",
"(",
"count",
")",
";",
"final",
"atomic",
"boolean",
"running",
"=",
"new",
"atomic",
"boolean",
"(",
"true",
")",
";",
"final",
"atomic",
"integer",
"count",
"=",
"new",
"atomic",
"integer",
"(",
"0",
")",
";",
"final",
"flowable",
"<",
"integer",
">",
"obs",
"=",
"flowable",
"unsafe",
"create",
"(",
"new",
"publisher",
"<",
"integer",
">",
"(",
")",
"{",
"@",
"override",
"public",
"void",
"subscribe",
"(",
"final",
"subscriber",
"<",
"?",
"super",
"integer",
">",
"subscriber",
")",
"{",
"subscriber",
"on",
"subscribe",
"(",
"new",
"boolean",
"subscription",
"(",
")",
")",
";",
"task",
"replace",
"(",
"schedulers",
"single",
"(",
")",
"schedule",
"direct",
"(",
"new",
"runnable",
"(",
")",
"{",
"@",
"override",
"public",
"void",
"run",
"(",
")",
"{",
"try",
"{",
"while",
"(",
"running",
"get",
"(",
")",
"&",
"&",
"!",
"task",
"is",
"disposed",
"(",
")",
")",
"{",
"subscriber",
"on",
"next",
"(",
"count",
"increment",
"and",
"get",
"(",
")",
")",
";",
"time",
"has",
"passed",
"count",
"down",
"(",
")",
";",
"}",
"subscriber",
"on",
"complete",
"(",
")",
";",
"}",
"catch",
"(",
"throwable",
"e",
")",
"{",
"subscriber",
"on",
"error",
"(",
"e",
")",
";",
"}",
"finally",
"{",
"finished",
"count",
"down",
"(",
")",
";",
"}",
"}",
"}",
")",
")",
";",
"}",
"}",
")",
";",
"iterator",
"<",
"integer",
">",
"it",
"=",
"obs",
"blocking",
"next",
"(",
")",
"iterator",
"(",
")",
";",
"assert",
"true",
"(",
"it",
"has",
"next",
"(",
")",
")",
";",
"int",
"a",
"=",
"it",
"next",
"(",
")",
";",
"assert",
"true",
"(",
"it",
"has",
"next",
"(",
")",
")",
";",
"int",
"b",
"=",
"it",
"next",
"(",
")",
";",
"/",
"/",
"we",
"should",
"have",
"a",
"different",
"value",
"assert",
"true",
"(",
"\"",
"a",
"and",
"b",
"should",
"be",
"different",
"\"",
",",
"a",
"!",
"=",
"b",
")",
";",
"/",
"/",
"wait",
"for",
"some",
"time",
"(",
"if",
"times",
"out",
"we",
"are",
"blocked",
"somewhere",
"so",
"fail",
"set",
"very",
"high",
"for",
"very",
"slow",
",",
"constrained",
"machines",
")",
"time",
"has",
"passed",
"await",
"(",
"8000",
",",
"time",
"unit",
"milliseconds",
")",
";",
"assert",
"true",
"(",
"it",
"has",
"next",
"(",
")",
")",
";",
"int",
"c",
"=",
"it",
"next",
"(",
")",
";",
"assert",
"true",
"(",
"\"",
"c",
"should",
"not",
"just",
"be",
"the",
"next",
"in",
"sequence",
"\"",
",",
"c",
"!",
"=",
"(",
"b",
"+",
"1",
")",
")",
";",
"assert",
"true",
"(",
"\"",
"expected",
"that",
"c",
"[",
"\"",
"+",
"c",
"+",
"\"",
"]",
"is",
"higher",
"than",
"or",
"equal",
"to",
"\"",
"+",
"count",
",",
"c",
">",
"=",
"count",
")",
";",
"assert",
"true",
"(",
"it",
"has",
"next",
"(",
")",
")",
";",
"int",
"d",
"=",
"it",
"next",
"(",
")",
";",
"assert",
"true",
"(",
"d",
">",
"c",
")",
";",
"/",
"/",
"shut",
"down",
"the",
"thread",
"running",
"set",
"(",
"false",
")",
";",
"finished",
"await",
"(",
")",
";",
"assert",
"false",
"(",
"it",
"has",
"next",
"(",
")",
")",
";",
"system",
"out",
"println",
"(",
"\"",
"a",
":",
"\"",
"+",
"a",
"+",
"\"",
"b",
":",
"\"",
"+",
"b",
"+",
"\"",
"c",
":",
"\"",
"+",
"c",
")",
";",
"break",
";",
"}",
"catch",
"(",
"assertion",
"error",
"ex",
")",
"{",
"if",
"(",
"+",
"+",
"repeat",
"=",
"=",
"3",
")",
"{",
"throw",
"ex",
";",
"}",
"thread",
"sleep",
"(",
"(",
"int",
")",
"(",
"1000",
"*",
"math",
"pow",
"(",
"2",
",",
"repeat",
"-",
"1",
")",
")",
")",
";",
"}",
"finally",
"{",
"task",
"dispose",
"(",
")",
";",
"}",
"}",
"}"
] |
[
"optional",
":",
"indicates",
"whether",
"connections",
"to",
"this",
"port",
"should",
"be",
"secured",
"using",
"tls",
"the",
"value",
"of",
"this",
"field",
"determines",
"how",
"tls",
"is",
"enforced",
"<",
"code",
">",
"istio",
"networking",
"v",
"1alpha",
"3",
"server",
"t",
"l",
"s",
"options",
"t",
"l",
"smode",
"mode",
"=",
"2",
";",
"<",
"code",
">"
] |
[
"public",
"int",
"get",
"mode",
"value",
"(",
")",
"{",
"return",
"mode",
";",
"}"
] |
[
"whether",
"to",
"base",
"6",
"4",
"-",
"encode",
"{",
"@",
"code",
"byte",
"[",
"]",
"}",
"properties",
"when",
"reading",
"and",
"writing",
"json",
"when",
"set",
"to",
"{",
"@",
"code",
"true",
"}",
",",
"a",
"custom",
"{",
"@",
"link",
"com",
"google",
"gson",
"type",
"adapter",
"}",
"will",
"be",
"registered",
"via",
"{",
"@",
"link",
"gson",
"builder",
"#",
"register",
"type",
"hierarchy",
"adapter",
"(",
"class",
",",
"object",
")",
"}",
"which",
"serializes",
"a",
"{",
"@",
"code",
"byte",
"[",
"]",
"}",
"property",
"to",
"and",
"from",
"a",
"base",
"6",
"4",
"-",
"encoded",
"string",
"instead",
"of",
"a",
"json",
"array"
] |
[
"public",
"void",
"set",
"base",
"6",
"4",
"encode",
"byte",
"arrays",
"(",
"boolean",
"base",
"6",
"4",
"encode",
"byte",
"arrays",
")",
"{",
"this",
"base",
"6",
"4",
"encode",
"byte",
"arrays",
"=",
"base",
"6",
"4",
"encode",
"byte",
"arrays",
";",
"}"
] |
[
"new",
"string",
"cipher",
"executor"
] |
[
"public",
"static",
"<",
"t",
"extends",
"base",
"string",
"cipher",
"executor",
">",
"t",
"new",
"string",
"cipher",
"executor",
"(",
"final",
"encryption",
"optional",
"signing",
"optional",
"jwt",
"cryptography",
"properties",
"crypto",
",",
"final",
"class",
"<",
"t",
">",
"cipher",
"class",
")",
"{",
"val",
"ctor",
"=",
"cipher",
"class",
"get",
"declared",
"constructor",
"(",
"string",
"class",
",",
"string",
"class",
",",
"string",
"class",
",",
"boolean",
"class",
",",
"boolean",
"class",
",",
"int",
"class",
",",
"int",
"class",
")",
";",
"val",
"cipher",
"=",
"(",
"t",
")",
"ctor",
"new",
"instance",
"(",
"crypto",
"get",
"encryption",
"(",
")",
"get",
"key",
"(",
")",
",",
"crypto",
"get",
"signing",
"(",
")",
"get",
"key",
"(",
")",
",",
"crypto",
"get",
"alg",
"(",
")",
",",
"crypto",
"is",
"encryption",
"enabled",
"(",
")",
",",
"crypto",
"is",
"signing",
"enabled",
"(",
")",
",",
"crypto",
"get",
"signing",
"(",
")",
"get",
"key",
"size",
"(",
")",
",",
"crypto",
"get",
"encryption",
"(",
")",
"get",
"key",
"size",
"(",
")",
")",
";",
"cipher",
"set",
"strategy",
"type",
"(",
"base",
"string",
"cipher",
"executor",
"cipher",
"operations",
"strategy",
"type",
"value",
"of",
"(",
"crypto",
"get",
"strategy",
"type",
"(",
")",
")",
")",
";",
"return",
"cipher",
";",
"}"
] |
[
"validates",
"that",
"the",
"packages",
"listed",
"under",
"\"",
"deps",
"\"",
"all",
"have",
"the",
"given",
"constraint",
"if",
"a",
"package",
"does",
"not",
"have",
"this",
"attribute",
",",
"an",
"error",
"is",
"generated"
] |
[
"public",
"static",
"final",
"void",
"validate",
"constraint",
"(",
"rule",
"context",
"rule",
"context",
",",
"string",
"constraint",
",",
"iterable",
"<",
"?",
"extends",
"transitive",
"info",
"collection",
">",
"targets",
")",
"{",
"for",
"(",
"transitive",
"info",
"collection",
"target",
":",
"targets",
")",
"{",
"java",
"info",
"java",
"info",
"=",
"java",
"info",
"get",
"java",
"info",
"(",
"target",
")",
";",
"if",
"(",
"java",
"info",
"!",
"=",
"null",
"&",
"&",
"!",
"java",
"info",
"get",
"java",
"constraints",
"(",
")",
"contains",
"(",
"constraint",
")",
")",
"{",
"rule",
"context",
"attribute",
"error",
"(",
"\"",
"deps",
"\"",
",",
"string",
"format",
"(",
"\"",
"%",
"s",
":",
"does",
"not",
"have",
"constraint",
"'",
"%",
"s",
"'",
"\"",
",",
"target",
"get",
"label",
"(",
")",
",",
"constraint",
")",
")",
";",
"}",
"}",
"}"
] |
[
"tests",
"the",
"corner",
"case",
"that",
"for",
"some",
"reason",
"a",
"transform",
"configuration",
"still",
"exists",
"in",
"the",
"index",
"but",
"the",
"persistent",
"task",
"disappeared",
"test",
"note",
":",
"{",
"@",
"link",
"transform",
"rest",
"test",
"case",
"}",
"checks",
"for",
"an",
"empty",
"index",
"as",
"part",
"of",
"the",
"test",
"case",
"cleanup",
",",
"so",
"we",
"do",
"not",
"need",
"to",
"check",
"that",
"the",
"document",
"has",
"been",
"deleted",
"in",
"this",
"place"
] |
[
"public",
"void",
"test",
"delete",
"configuration",
"left",
"over",
"(",
")",
"throws",
"i",
"o",
"exception",
"{",
"string",
"fake",
"transform",
"name",
"=",
"random",
"alpha",
"of",
"length",
"between",
"(",
"5",
",",
"20",
")",
";",
"final",
"request",
"options",
"expect",
"warning",
"options",
"=",
"expect",
"warnings",
"(",
"\"",
"this",
"request",
"accesses",
"system",
"indices",
":",
"[",
"\"",
"+",
"transform",
"internal",
"index",
"constants",
"latest",
"index",
"name",
"+",
"\"",
"]",
",",
"but",
"in",
"a",
"future",
"major",
"version",
",",
"direct",
"access",
"to",
"system",
"indices",
"will",
"\"",
"+",
"\"",
"be",
"prevented",
"by",
"default",
"\"",
")",
";",
"try",
"(",
"x",
"content",
"builder",
"builder",
"=",
"json",
"builder",
"(",
")",
")",
"{",
"builder",
"start",
"object",
"(",
")",
";",
"{",
"builder",
"field",
"(",
"transform",
"field",
"id",
"get",
"preferred",
"name",
"(",
")",
",",
"fake",
"transform",
"name",
")",
";",
"}",
"builder",
"end",
"object",
"(",
")",
";",
"final",
"string",
"entity",
"entity",
"=",
"new",
"string",
"entity",
"(",
"strings",
"to",
"string",
"(",
"builder",
")",
",",
"content",
"type",
"application",
"json",
")",
";",
"request",
"req",
"=",
"new",
"request",
"(",
"\"",
"put",
"\"",
",",
"transform",
"internal",
"index",
"constants",
"latest",
"index",
"name",
"+",
"\"",
"/",
"doc",
"/",
"\"",
"+",
"transform",
"config",
"document",
"id",
"(",
"fake",
"transform",
"name",
")",
")",
";",
"req",
"set",
"options",
"(",
"expect",
"warning",
"options",
")",
";",
"req",
"set",
"entity",
"(",
"entity",
")",
";",
"client",
"(",
")",
"perform",
"request",
"(",
"req",
")",
";",
"}",
"/",
"/",
"refresh",
"the",
"index",
"final",
"request",
"refresh",
"request",
"=",
"new",
"request",
"(",
"\"",
"post",
"\"",
",",
"transform",
"internal",
"index",
"constants",
"latest",
"index",
"name",
"+",
"\"",
"/",
"refresh",
"\"",
")",
";",
"refresh",
"request",
"set",
"options",
"(",
"expect",
"warning",
"options",
")",
";",
"assert",
"o",
"k",
"(",
"client",
"(",
")",
"perform",
"request",
"(",
"refresh",
"request",
")",
")",
";",
"request",
"delete",
"request",
"=",
"new",
"request",
"(",
"\"",
"delete",
"\"",
",",
"get",
"transform",
"endpoint",
"(",
")",
"+",
"fake",
"transform",
"name",
")",
";",
"response",
"delete",
"response",
"=",
"client",
"(",
")",
"perform",
"request",
"(",
"delete",
"request",
")",
";",
"assert",
"o",
"k",
"(",
"delete",
"response",
")",
";",
"assert",
"true",
"(",
"(",
"boolean",
")",
"x",
"content",
"map",
"values",
"extract",
"value",
"(",
"\"",
"acknowledged",
"\"",
",",
"entity",
"as",
"map",
"(",
"delete",
"response",
")",
")",
")",
";",
"/",
"/",
"delete",
"again",
",",
"should",
"fail",
"expect",
"throws",
"(",
"response",
"exception",
"class",
",",
"(",
")",
"-",
">",
"client",
"(",
")",
"perform",
"request",
"(",
"delete",
"request",
")",
")",
";",
"}"
] |
[
"returns",
"the",
"function",
"pointer"
] |
[
"public",
"long",
"get",
"function",
"(",
")",
"{",
"return",
"value",
";",
"}"
] |
[
"returns",
"a",
"new",
"builder",
"the",
"generated",
"builder",
"is",
"equivalent",
"to",
"the",
"builder",
"created",
"by",
"the",
"{",
"@",
"link",
"builder",
"}",
"constructor"
] |
[
"public",
"static",
"<",
"k",
",",
"v",
">",
"builder",
"<",
"k",
",",
"v",
">",
"builder",
"(",
")",
"{",
"return",
"new",
"builder",
"<",
">",
"(",
")",
";",
"}"
] |
[
"creates",
"the",
"namenode",
"proxy",
"with",
"the",
"passed",
"protocol",
"this",
"will",
"handle",
"creation",
"of",
"either",
"ha",
"-",
"or",
"non",
"-",
"ha",
"-",
"enabled",
"proxy",
"objects",
",",
"depending",
"upon",
"if",
"the",
"provided",
"uri",
"is",
"a",
"configured",
"logical",
"uri"
] |
[
"public",
"static",
"<",
"t",
">",
"proxy",
"and",
"info",
"<",
"t",
">",
"create",
"proxy",
"(",
"configuration",
"conf",
",",
"uri",
"name",
"node",
"uri",
",",
"class",
"<",
"t",
">",
"xface",
")",
"throws",
"i",
"o",
"exception",
"{",
"return",
"create",
"proxy",
"(",
"conf",
",",
"name",
"node",
"uri",
",",
"xface",
",",
"null",
")",
";",
"}"
] |
[
"model",
"tests",
"for",
"xml",
"item"
] |
[
"public",
"void",
"test",
"xml",
"item",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"xml",
"item",
"}"
] |
[
"set",
"to",
"{",
"@",
"code",
"true",
"}",
"to",
"force",
"this",
"index",
"to",
"use",
"{",
"@",
"link",
"op",
"type",
"#",
"create",
"}"
] |
[
"public",
"index",
"request",
"create",
"(",
"boolean",
"create",
")",
"{",
"if",
"(",
"create",
")",
"{",
"return",
"op",
"type",
"(",
"op",
"type",
"create",
")",
";",
"}",
"else",
"{",
"return",
"op",
"type",
"(",
"op",
"type",
"index",
")",
";",
"}",
"}"
] |
[
"return",
"true",
"if",
"this",
"impl",
"is",
"going",
"to",
"be",
"smaller",
"than",
"{",
"@",
"link",
"single",
"packed",
"ordinals",
"}",
"by",
"at",
"least",
"20",
"%"
] |
[
"public",
"static",
"boolean",
"significantly",
"smaller",
"than",
"single",
"packed",
"ordinals",
"(",
"int",
"max",
"doc",
",",
"int",
"num",
"docs",
"with",
"value",
",",
"long",
"num",
"ords",
",",
"float",
"acceptable",
"overhead",
"ratio",
")",
"{",
"int",
"bits",
"per",
"ord",
"=",
"packed",
"ints",
"bits",
"required",
"(",
"num",
"ords",
")",
";",
"bits",
"per",
"ord",
"=",
"packed",
"ints",
"fastest",
"format",
"and",
"bits",
"(",
"num",
"docs",
"with",
"value",
",",
"bits",
"per",
"ord",
",",
"acceptable",
"overhead",
"ratio",
")",
"bits",
"per",
"value",
";",
"/",
"/",
"compute",
"the",
"worst",
"-",
"case",
"number",
"of",
"bits",
"per",
"value",
"for",
"offsets",
"in",
"the",
"worst",
"case",
",",
"eg",
"if",
"no",
"docs",
"have",
"a",
"value",
"at",
"the",
"/",
"/",
"beginning",
"of",
"the",
"block",
"and",
"all",
"docs",
"have",
"one",
"at",
"the",
"end",
"of",
"the",
"block",
"final",
"float",
"avg",
"values",
"per",
"doc",
"=",
"(",
"float",
")",
"num",
"docs",
"with",
"value",
"/",
"max",
"doc",
";",
"final",
"int",
"max",
"delta",
"=",
"(",
"int",
")",
"math",
"ceil",
"(",
"offsets",
"page",
"size",
"*",
"(",
"1",
"-",
"avg",
"values",
"per",
"doc",
")",
"*",
"avg",
"values",
"per",
"doc",
")",
";",
"int",
"bits",
"per",
"offset",
"=",
"packed",
"ints",
"bits",
"required",
"(",
"max",
"delta",
")",
"+",
"1",
";",
"/",
"/",
"+",
"1",
"because",
"of",
"the",
"sign",
"bits",
"per",
"offset",
"=",
"packed",
"ints",
"fastest",
"format",
"and",
"bits",
"(",
"max",
"doc",
",",
"bits",
"per",
"offset",
",",
"acceptable",
"overhead",
"ratio",
")",
"bits",
"per",
"value",
";",
"final",
"long",
"expected",
"multi",
"size",
"in",
"bytes",
"=",
"(",
"long",
")",
"num",
"docs",
"with",
"value",
"*",
"bits",
"per",
"ord",
"+",
"(",
"long",
")",
"max",
"doc",
"*",
"bits",
"per",
"offset",
";",
"final",
"long",
"expected",
"single",
"size",
"in",
"bytes",
"=",
"(",
"long",
")",
"max",
"doc",
"*",
"bits",
"per",
"ord",
";",
"return",
"expected",
"multi",
"size",
"in",
"bytes",
"<",
"0",
"8f",
"*",
"expected",
"single",
"size",
"in",
"bytes",
";",
"}"
] |
[
"returns",
"{",
"@",
"code",
"true",
"}",
"if",
"and",
"only",
"if",
"the",
"specified",
"address",
"is",
"supported",
"by",
"this",
"resolved"
] |
[
"boolean",
"is",
"supported",
"(",
"socket",
"address",
"address",
")",
";"
] |
[
"write",
"this",
"record",
"batch",
"into",
"an",
"output",
"stream"
] |
[
"void",
"write",
"to",
"(",
"byte",
"buffer",
"output",
"stream",
"output",
"stream",
")",
";"
] |
[
"get",
"pet",
"id"
] |
[
"public",
"long",
"get",
"pet",
"id",
"(",
")",
"{",
"return",
"pet",
"id",
";",
"}"
] |
[
"whether",
"this",
"serializer",
"supports",
"the",
"version",
"of",
"the",
"output",
"stream"
] |
[
"default",
"boolean",
"supports",
"version",
"(",
"diff",
"<",
"v",
">",
"value",
",",
"version",
"version",
")",
"{",
"return",
"true",
";",
"}"
] |
[
"validate",
"that",
"the",
"nested",
"path",
"and",
"its",
"ancestors",
"should",
"have",
"been",
"moved"
] |
[
"protected",
"void",
"validate",
"ancestors",
"moved",
"(",
"path",
"src",
",",
"path",
"dst",
",",
"string",
"nested",
"path",
")",
"throws",
"i",
"o",
"exception",
"{",
"assert",
"is",
"directory",
"(",
"dst",
")",
";",
"assert",
"path",
"does",
"not",
"exist",
"(",
"\"",
"src",
"path",
"should",
"not",
"exist",
"\"",
",",
"path",
"(",
"src",
"+",
"nested",
"path",
")",
")",
";",
"assert",
"path",
"exists",
"(",
"\"",
"dst",
"path",
"should",
"exist",
"\"",
",",
"path",
"(",
"dst",
"+",
"nested",
"path",
")",
")",
";",
"path",
"path",
"=",
"new",
"path",
"(",
"nested",
"path",
")",
"get",
"parent",
"(",
")",
";",
"while",
"(",
"path",
"!",
"=",
"null",
"&",
"&",
"!",
"path",
"is",
"root",
"(",
")",
")",
"{",
"final",
"path",
"parent",
"src",
"=",
"path",
"(",
"src",
"+",
"path",
"to",
"string",
"(",
")",
")",
";",
"assert",
"path",
"does",
"not",
"exist",
"(",
"parent",
"src",
"+",
"\"",
"is",
"not",
"deleted",
"\"",
",",
"parent",
"src",
")",
";",
"final",
"path",
"parent",
"dst",
"=",
"path",
"(",
"dst",
"+",
"path",
"to",
"string",
"(",
")",
")",
";",
"assert",
"path",
"exists",
"(",
"parent",
"dst",
"+",
"\"",
"should",
"exist",
"after",
"rename",
"\"",
",",
"parent",
"dst",
")",
";",
"assert",
"is",
"directory",
"(",
"parent",
"dst",
")",
";",
"path",
"=",
"path",
"get",
"parent",
"(",
")",
";",
"}",
"}"
] |
[
"compute",
"the",
"distance",
"between",
"two",
"points",
"using",
"the",
"selected",
"algorithm",
"(",
"plane",
",",
"arc",
")"
] |
[
"public",
"double",
"calculate",
"(",
"double",
"src",
"lat",
",",
"double",
"src",
"lon",
",",
"double",
"dst",
"lat",
",",
"double",
"dst",
"lon",
",",
"distance",
"unit",
"unit",
")",
"{",
"if",
"(",
"this",
"=",
"=",
"plane",
")",
"{",
"return",
"distance",
"unit",
"convert",
"(",
"geo",
"utils",
"plane",
"distance",
"(",
"src",
"lat",
",",
"src",
"lon",
",",
"dst",
"lat",
",",
"dst",
"lon",
")",
",",
"distance",
"unit",
"meters",
",",
"unit",
")",
";",
"}",
"return",
"distance",
"unit",
"convert",
"(",
"geo",
"utils",
"arc",
"distance",
"(",
"src",
"lat",
",",
"src",
"lon",
",",
"dst",
"lat",
",",
"dst",
"lon",
")",
",",
"distance",
"unit",
"meters",
",",
"unit",
")",
";",
"}"
] |
[
"reset",
"spring",
"'",
"s",
"common",
"reflection",
"metadata",
"caches",
",",
"in",
"particular",
"the",
"{",
"@",
"link",
"reflection",
"utils",
"}",
",",
"{",
"@",
"link",
"annotation",
"utils",
"}",
",",
"{",
"@",
"link",
"resolvable",
"type",
"}",
"and",
"{",
"@",
"link",
"cached",
"introspection",
"results",
"}",
"caches"
] |
[
"protected",
"void",
"reset",
"common",
"caches",
"(",
")",
"{",
"reflection",
"utils",
"clear",
"cache",
"(",
")",
";",
"annotation",
"utils",
"clear",
"cache",
"(",
")",
";",
"resolvable",
"type",
"clear",
"cache",
"(",
")",
";",
"cached",
"introspection",
"results",
"clear",
"class",
"loader",
"(",
"get",
"class",
"loader",
"(",
")",
")",
";",
"}"
] |
[
"display",
"the",
"content",
"specified",
"by",
"url",
"in",
"a",
"web",
"browser",
"window",
"this",
"call",
"will",
"launch",
"a",
"new",
"thread",
"and",
"then",
"immediately",
"return"
] |
[
"public",
"static",
"void",
"display",
"(",
"url",
"url",
")",
"{",
"display",
"(",
"url",
",",
"null",
",",
"null",
")",
";",
"}"
] |
[
"rename",
"all",
"the",
"fsimage",
"files",
"with",
"the",
"specific",
"name",
"node",
"file",
"type",
"the",
"associated",
"checksum",
"files",
"will",
"also",
"be",
"renamed"
] |
[
"void",
"rename",
"checkpoint",
"(",
"name",
"node",
"file",
"from",
"nnf",
",",
"name",
"node",
"file",
"to",
"nnf",
")",
"throws",
"i",
"o",
"exception",
"{",
"array",
"list",
"<",
"storage",
"directory",
">",
"al",
"=",
"null",
";",
"f",
"s",
"image",
"transactional",
"storage",
"inspector",
"inspector",
"=",
"new",
"f",
"s",
"image",
"transactional",
"storage",
"inspector",
"(",
"enum",
"set",
"of",
"(",
"from",
"nnf",
")",
")",
";",
"storage",
"inspect",
"storage",
"dirs",
"(",
"inspector",
")",
";",
"for",
"(",
"f",
"s",
"image",
"file",
"image",
":",
"inspector",
"get",
"found",
"images",
"(",
")",
")",
"{",
"try",
"{",
"rename",
"image",
"file",
"in",
"dir",
"(",
"image",
"sd",
",",
"from",
"nnf",
",",
"to",
"nnf",
",",
"image",
"tx",
"id",
",",
"true",
")",
";",
"}",
"catch",
"(",
"i",
"o",
"exception",
"ioe",
")",
"{",
"log",
"warn",
"(",
"\"",
"unable",
"to",
"rename",
"checkpoint",
"in",
"\"",
"+",
"image",
"sd",
",",
"ioe",
")",
";",
"if",
"(",
"al",
"=",
"=",
"null",
")",
"{",
"al",
"=",
"lists",
"new",
"array",
"list",
"(",
")",
";",
"}",
"al",
"add",
"(",
"image",
"sd",
")",
";",
"}",
"}",
"if",
"(",
"al",
"!",
"=",
"null",
")",
"{",
"storage",
"report",
"errors",
"on",
"directories",
"(",
"al",
")",
";",
"}",
"}"
] |
[
"get",
"my",
"string"
] |
[
"public",
"string",
"get",
"my",
"string",
"(",
")",
"{",
"return",
"my",
"string",
";",
"}"
] |
[
"opens",
"up",
"the",
"stream",
"at",
"specified",
"target",
"position",
"and",
"for",
"given",
"length"
] |
[
"private",
"synchronized",
"void",
"reopen",
"(",
"final",
"string",
"reason",
",",
"final",
"long",
"target",
"pos",
",",
"final",
"long",
"length",
")",
"throws",
"i",
"o",
"exception",
"{",
"long",
"start",
"time",
"=",
"system",
"current",
"time",
"millis",
"(",
")",
";",
"long",
"thread",
"id",
"=",
"thread",
"current",
"thread",
"(",
")",
"get",
"id",
"(",
")",
";",
"if",
"(",
"wrapped",
"stream",
"!",
"=",
"null",
")",
"{",
"close",
"stream",
"(",
"\"",
"reopen",
"(",
"\"",
"+",
"reason",
"+",
"\"",
")",
"\"",
",",
"content",
"range",
"finish",
")",
";",
"}",
"content",
"range",
"finish",
"=",
"calculate",
"request",
"limit",
"(",
"target",
"pos",
",",
"length",
",",
"content",
"length",
",",
"read",
"ahead",
"range",
")",
";",
"try",
"{",
"get",
"object",
"request",
"request",
"=",
"new",
"get",
"object",
"request",
"(",
"bucket",
",",
"key",
")",
";",
"request",
"set",
"range",
"start",
"(",
"target",
"pos",
")",
";",
"request",
"set",
"range",
"end",
"(",
"content",
"range",
"finish",
")",
";",
"if",
"(",
"fs",
"get",
"sse",
"(",
")",
"is",
"sse",
"c",
"enable",
"(",
")",
")",
"{",
"request",
"set",
"sse",
"c",
"header",
"(",
"fs",
"get",
"sse",
"(",
")",
"get",
"sse",
"c",
"header",
"(",
")",
")",
";",
"}",
"wrapped",
"stream",
"=",
"client",
"get",
"object",
"(",
"request",
")",
"get",
"object",
"content",
"(",
")",
";",
"content",
"range",
"start",
"=",
"target",
"pos",
";",
"if",
"(",
"wrapped",
"stream",
"=",
"=",
"null",
")",
"{",
"throw",
"new",
"i",
"o",
"exception",
"(",
"\"",
"null",
"io",
"stream",
"from",
"reopen",
"of",
"(",
"\"",
"+",
"reason",
"+",
"\"",
")",
"\"",
"+",
"uri",
")",
";",
"}",
"}",
"catch",
"(",
"obs",
"exception",
"e",
")",
"{",
"throw",
"translate",
"exception",
"(",
"\"",
"reopen",
"at",
"position",
"\"",
"+",
"target",
"pos",
",",
"uri",
",",
"e",
")",
";",
"}",
"this",
"stream",
"current",
"pos",
"=",
"target",
"pos",
";",
"long",
"end",
"time",
"=",
"system",
"current",
"time",
"millis",
"(",
")",
";",
"log",
"debug",
"(",
"\"",
"reopen",
"(",
"{",
"}",
")",
"for",
"{",
"}",
"range",
"[",
"{",
"}",
"-",
"{",
"}",
"]",
",",
"length",
"=",
"{",
"}",
",",
"\"",
"+",
"\"",
"stream",
"position",
"=",
"{",
"}",
",",
"next",
"read",
"position",
"=",
"{",
"}",
",",
"thread",
"=",
"{",
"}",
",",
"\"",
"+",
"\"",
"time",
"used",
"in",
"milli",
"sec",
"=",
"{",
"}",
"\"",
",",
"uri",
",",
"reason",
",",
"target",
"pos",
",",
"content",
"range",
"finish",
",",
"length",
",",
"stream",
"current",
"pos",
",",
"next",
"read",
"pos",
",",
"thread",
"id",
",",
"end",
"time",
"-",
"start",
"time",
")",
";",
"}"
] |
[
"java",
"config",
"friendly",
"alternative",
"to",
"{",
"@",
"link",
"#",
"set",
"extensions",
"(",
"map",
")",
"}"
] |
[
"public",
"void",
"register",
"extension",
"(",
"string",
"coding",
",",
"string",
"extension",
")",
"{",
"this",
"extensions",
"put",
"(",
"coding",
",",
"(",
"extension",
"starts",
"with",
"(",
"\"",
"\"",
")",
"?",
"extension",
":",
"\"",
"\"",
"+",
"extension",
")",
")",
";",
"}"
] |
[
"gets",
"the",
"desired",
"image",
"base",
"to",
"use",
"during",
"the",
"load"
] |
[
"public",
"long",
"get",
"desired",
"image",
"base",
"(",
")",
"{",
"return",
"image",
"base",
";",
"}"
] |
[
"specify",
"the",
"maximum",
"number",
"of",
"parts",
"allowed",
"in",
"a",
"given",
"multipart",
"request"
] |
[
"public",
"void",
"set",
"max",
"parts",
"(",
"int",
"max",
"parts",
")",
"{",
"this",
"max",
"parts",
"=",
"max",
"parts",
";",
"}"
] |
[
"the",
"given",
"node",
"is",
"reporting",
"that",
"it",
"received",
"a",
"certain",
"block"
] |
[
"public",
"void",
"add",
"block",
"(",
"datanode",
"storage",
"info",
"storage",
"info",
",",
"block",
"block",
",",
"string",
"del",
"hint",
")",
"throws",
"i",
"o",
"exception",
"{",
"datanode",
"descriptor",
"node",
"=",
"storage",
"info",
"get",
"datanode",
"descriptor",
"(",
")",
";",
"/",
"/",
"decrement",
"number",
"of",
"blocks",
"scheduled",
"to",
"this",
"datanode",
"/",
"/",
"for",
"a",
"retry",
"request",
"(",
"of",
"datanode",
"protocol",
"#",
"block",
"received",
"and",
"deleted",
"with",
"/",
"/",
"received",
"block",
")",
",",
"we",
"currently",
"also",
"decrease",
"the",
"approximate",
"number",
"node",
"decrement",
"blocks",
"scheduled",
"(",
"storage",
"info",
"get",
"storage",
"type",
"(",
")",
")",
";",
"/",
"/",
"get",
"the",
"deletion",
"hint",
"node",
"datanode",
"descriptor",
"del",
"hint",
"node",
"=",
"null",
";",
"if",
"(",
"del",
"hint",
"!",
"=",
"null",
"&",
"&",
"del",
"hint",
"length",
"(",
")",
"!",
"=",
"0",
")",
"{",
"del",
"hint",
"node",
"=",
"datanode",
"manager",
"get",
"datanode",
"(",
"del",
"hint",
")",
";",
"if",
"(",
"del",
"hint",
"node",
"=",
"=",
"null",
")",
"{",
"block",
"log",
"warn",
"(",
"\"",
"block",
"*",
"block",
"received",
":",
"{",
"}",
"is",
"expected",
"to",
"be",
"removed",
"\"",
"+",
"\"",
"from",
"an",
"unrecorded",
"node",
"{",
"}",
"\"",
",",
"block",
",",
"del",
"hint",
")",
";",
"}",
"}",
"/",
"/",
"/",
"/",
"modify",
"the",
"blocks",
"-",
">",
"datanode",
"map",
"and",
"node",
"'",
"s",
"map",
"/",
"/",
"block",
"info",
"stored",
"block",
"=",
"get",
"stored",
"block",
"(",
"block",
")",
";",
"if",
"(",
"stored",
"block",
"!",
"=",
"null",
"&",
"&",
"block",
"get",
"generation",
"stamp",
"(",
")",
"=",
"=",
"stored",
"block",
"get",
"generation",
"stamp",
"(",
")",
")",
"{",
"if",
"(",
"pending",
"reconstruction",
"decrement",
"(",
"stored",
"block",
",",
"storage",
"info",
")",
")",
"{",
"name",
"node",
"get",
"name",
"node",
"metrics",
"(",
")",
"inc",
"successful",
"re",
"replications",
"(",
")",
";",
"}",
"}",
"process",
"and",
"handle",
"reported",
"block",
"(",
"storage",
"info",
",",
"block",
",",
"replica",
"state",
"finalized",
",",
"del",
"hint",
"node",
")",
";",
"}"
] |
[
"verify",
"that",
"information",
"about",
"the",
"fencing",
"target",
"gets",
"passed",
"as",
"environment",
"variables",
"to",
"the",
"fencer"
] |
[
"public",
"void",
"test",
"target",
"as",
"environment",
"(",
")",
"{",
"if",
"(",
"!",
"shell",
"windows",
")",
"{",
"fencer",
"try",
"fence",
"(",
"test",
"target",
",",
"\"",
"echo",
"$",
"target",
"host",
"$",
"target",
"port",
"\"",
")",
";",
"mockito",
"verify",
"(",
"shell",
"command",
"fencer",
"log",
")",
"info",
"(",
"mockito",
"ends",
"with",
"(",
"\"",
"echo",
"$",
"ta",
"rget",
"port",
":",
"dummyhost",
"1234",
"\"",
")",
")",
";",
"}",
"else",
"{",
"fencer",
"try",
"fence",
"(",
"test",
"target",
",",
"\"",
"echo",
"%",
"target",
"host",
"%",
"%",
"target",
"port",
"%",
"\"",
")",
";",
"mockito",
"verify",
"(",
"shell",
"command",
"fencer",
"log",
")",
"info",
"(",
"mockito",
"ends",
"with",
"(",
"\"",
"echo",
"%",
"ta",
"get",
"port",
"%",
":",
"dummyhost",
"1234",
"\"",
")",
")",
";",
"}",
"}"
] |
[
"test",
"the",
"property",
"'",
"prefix",
"namespace",
"integer",
"'"
] |
[
"public",
"void",
"prefix",
"namespace",
"integer",
"test",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"prefix",
"namespace",
"integer",
"}"
] |
[
"return",
"the",
"name",
"of",
"the",
"parameter",
"that",
"contains",
"a",
"locale",
"specification",
"in",
"a",
"locale",
"change",
"request"
] |
[
"public",
"string",
"get",
"param",
"name",
"(",
")",
"{",
"return",
"this",
"param",
"name",
";",
"}"
] |
[
"renews",
"an",
"existing",
"retention",
"lease"
] |
[
"public",
"retention",
"lease",
"renew",
"retention",
"lease",
"(",
"final",
"string",
"id",
",",
"final",
"long",
"retaining",
"sequence",
"number",
",",
"final",
"string",
"source",
")",
"{",
"assert",
"assert",
"primary",
"mode",
"(",
")",
";",
"verify",
"not",
"closed",
"(",
")",
";",
"ensure",
"soft",
"deletes",
"enabled",
"(",
"\"",
"retention",
"leases",
"\"",
")",
";",
"try",
"(",
"closeable",
"ignore",
"=",
"acquire",
"history",
"retention",
"lock",
"(",
")",
")",
"{",
"final",
"long",
"actual",
"retaining",
"sequence",
"number",
"=",
"retaining",
"sequence",
"number",
"=",
"=",
"retain",
"all",
"?",
"get",
"min",
"retained",
"seq",
"no",
"(",
")",
":",
"retaining",
"sequence",
"number",
";",
"return",
"replication",
"tracker",
"renew",
"retention",
"lease",
"(",
"id",
",",
"actual",
"retaining",
"sequence",
"number",
",",
"source",
")",
";",
"}",
"catch",
"(",
"final",
"i",
"o",
"exception",
"e",
")",
"{",
"throw",
"new",
"assertion",
"error",
"(",
"e",
")",
";",
"}",
"}"
] |
[
"creates",
"a",
"new",
"builder",
"object",
"for",
"creating",
"an",
"ml",
"filter",
"object"
] |
[
"public",
"static",
"builder",
"builder",
"(",
"string",
"filter",
"id",
")",
"{",
"return",
"new",
"builder",
"(",
")",
"set",
"id",
"(",
"filter",
"id",
")",
";",
"}"
] |
[
"see",
"{",
"@",
"link",
"#",
"ceil",
"(",
"long",
")",
"}",
"this",
"method",
"modifies",
"the",
"given",
"calendar",
"and",
"returns",
"the",
"same",
"object"
] |
[
"public",
"calendar",
"ceil",
"(",
"calendar",
"cal",
")",
"{",
"calendar",
"two",
"years",
"future",
"=",
"(",
"calendar",
")",
"cal",
"clone",
"(",
")",
";",
"two",
"years",
"future",
"add",
"(",
"calendar",
"year",
",",
"2",
")",
";",
"outer",
":",
"while",
"(",
"true",
")",
"{",
"if",
"(",
"cal",
"compare",
"to",
"(",
"two",
"years",
"future",
")",
">",
"0",
")",
"{",
"/",
"/",
"we",
"went",
"too",
"far",
"into",
"the",
"future",
"throw",
"new",
"rare",
"or",
"impossible",
"date",
"exception",
"(",
")",
";",
"}",
"for",
"(",
"calendar",
"field",
"f",
":",
"calendar",
"field",
"adjust",
"order",
")",
"{",
"int",
"cur",
"=",
"f",
"value",
"of",
"(",
"cal",
")",
";",
"int",
"next",
"=",
"f",
"ceil",
"(",
"this",
",",
"cur",
")",
";",
"if",
"(",
"cur",
"=",
"=",
"next",
")",
"continue",
";",
"/",
"/",
"this",
"field",
"is",
"already",
"in",
"a",
"good",
"shape",
"move",
"on",
"to",
"next",
"/",
"/",
"we",
"are",
"modifying",
"this",
"field",
",",
"so",
"clear",
"all",
"the",
"lower",
"level",
"fields",
"for",
"(",
"calendar",
"field",
"l",
"=",
"f",
"lower",
"field",
";",
"l",
"!",
"=",
"null",
";",
"l",
"=",
"l",
"lower",
"field",
")",
"l",
"clear",
"(",
"cal",
")",
";",
"if",
"(",
"next",
"<",
"0",
")",
"{",
"/",
"/",
"we",
"need",
"to",
"roll",
"over",
"to",
"the",
"next",
"field",
"f",
"roll",
"up",
"(",
"cal",
",",
"1",
")",
";",
"f",
"set",
"to",
"(",
"cal",
",",
"f",
"first",
"(",
"this",
")",
")",
";",
"/",
"/",
"since",
"higher",
"order",
"field",
"is",
"affected",
"by",
"this",
",",
"we",
"need",
"to",
"restart",
"from",
"all",
"over",
"continue",
"outer",
";",
"}",
"else",
"{",
"f",
"set",
"to",
"(",
"cal",
",",
"next",
")",
";",
"/",
"/",
"check",
"if",
"value",
"was",
"actually",
"set",
"if",
"(",
"f",
"value",
"of",
"(",
"cal",
")",
"!",
"=",
"next",
")",
"{",
"/",
"/",
"we",
"need",
"to",
"roll",
"over",
"to",
"the",
"next",
"field",
"f",
"roll",
"up",
"(",
"cal",
",",
"1",
")",
";",
"f",
"set",
"to",
"(",
"cal",
",",
"f",
"first",
"(",
"this",
")",
")",
";",
"/",
"/",
"since",
"higher",
"order",
"field",
"is",
"affected",
"by",
"this",
",",
"we",
"need",
"to",
"restart",
"from",
"all",
"over",
"continue",
"outer",
";",
"}",
"if",
"(",
"f",
"redo",
"adjustment",
"if",
"modified",
")",
"continue",
"outer",
";",
"/",
"/",
"when",
"we",
"modify",
"day",
"of",
"month",
"and",
"day",
"of",
"week",
",",
"do",
"it",
"all",
"over",
"from",
"the",
"top",
"}",
"}",
"return",
"cal",
";",
"/",
"/",
"all",
"fields",
"adjusted",
"}",
"}"
] |
[
"ensure",
"that",
"there",
"is",
"waiting",
"(",
"sleep",
"duration",
"!",
"=",
"0",
")",
"if",
"the",
"metrics",
"have",
"only",
"been",
"updated",
"with",
"many",
"successful",
"and",
"failed",
"requests",
"also",
"ensure",
"that",
"the",
"sleep",
"duration",
"decreases",
"to",
"zero",
"over",
"time"
] |
[
"public",
"void",
"test",
"many",
"success",
"and",
"errors",
"and",
"waiting",
"(",
")",
"{",
"client",
"throttling",
"analyzer",
"analyzer",
"=",
"new",
"client",
"throttling",
"analyzer",
"(",
"\"",
"test",
"\"",
",",
"analysis",
"period",
")",
";",
"validate",
"(",
"0",
",",
"analyzer",
"get",
"sleep",
"duration",
"(",
")",
")",
";",
"final",
"int",
"number",
"of",
"requests",
"=",
"20",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"number",
"of",
"requests",
";",
"i",
"+",
"+",
")",
"{",
"analyzer",
"add",
"bytes",
"transferred",
"(",
"8",
"*",
"megabyte",
",",
"false",
")",
";",
"analyzer",
"add",
"bytes",
"transferred",
"(",
"2",
"*",
"megabyte",
",",
"true",
")",
";",
"}",
"sleep",
"(",
"analysis",
"period",
"plus",
"10",
"percent",
")",
";",
"nano",
"timer",
"timer",
"=",
"new",
"nano",
"timer",
"(",
")",
";",
"analyzer",
"suspend",
"if",
"necessary",
"(",
")",
";",
"fuzzy",
"validate",
"(",
"7",
",",
"timer",
"elapsed",
"time",
"ms",
"(",
")",
",",
"max",
"acceptable",
"percent",
"difference",
")",
";",
"sleep",
"(",
"10",
"*",
"analysis",
"period",
")",
";",
"validate",
"(",
"0",
",",
"analyzer",
"get",
"sleep",
"duration",
"(",
")",
")",
";",
"}"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.