Commit b67df7b
committed
fix(api): fix compilation error and address imbajin review issues
- GraphsAPI: remove duplicate private isPrefix() that shadowed the
protected version in API base class, causing compilation failure
- GraphsAPI: fix NPE in manage() when 'update' value is null by
guarding value.getClass() in both action and update validation
- GraphsAPI/GraphSpaceAPI: replace org.apache.commons.lang.StringUtils
with commons-lang3 and remove org.apache.logging.log4j.util.Strings
import (replaced with StringUtils equivalents) to fix potential
classpath issues
- GraphManager.updateGraphNickname: restore old nickname (not null)
on PD persistence failure to avoid a third inconsistent state
- StandardAuthManagerV2.setDefaultGraph: check existBelong() before
createBelong() to make the operation idempotent; repeated POST calls
for the same user/graph no longer throw HugeException
- StandardAuthManagerV2.createDefaultRole: same idempotent guard via
existBelong() check before createBelong()
- ManagerAPI.checkDefaultRole: use @PathParam graphspace instead of
@QueryParam to match the mounted path contract1 parent 6ddfb17 commit b67df7b
5 files changed
Lines changed: 34 additions & 28 deletions
File tree
- hugegraph-server
- hugegraph-api/src/main/java/org/apache/hugegraph
- api
- auth
- profile
- space
- core
- hugegraph-core/src/main/java/org/apache/hugegraph/auth
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
267 | 267 | | |
268 | 268 | | |
269 | 269 | | |
270 | | - | |
| 270 | + | |
271 | 271 | | |
272 | 272 | | |
273 | 273 | | |
| |||
Lines changed: 4 additions & 15 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
50 | 49 | | |
51 | 50 | | |
52 | 51 | | |
| |||
213 | 212 | | |
214 | 213 | | |
215 | 214 | | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | 215 | | |
228 | 216 | | |
229 | 217 | | |
| |||
358 | 346 | | |
359 | 347 | | |
360 | 348 | | |
361 | | - | |
| 349 | + | |
| 350 | + | |
362 | 351 | | |
363 | 352 | | |
364 | 353 | | |
| |||
367 | 356 | | |
368 | 357 | | |
369 | 358 | | |
370 | | - | |
| 359 | + | |
371 | 360 | | |
372 | 361 | | |
373 | 362 | | |
| |||
471 | 460 | | |
472 | 461 | | |
473 | 462 | | |
474 | | - | |
| 463 | + | |
475 | 464 | | |
476 | 465 | | |
477 | 466 | | |
| |||
Lines changed: 8 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
45 | 44 | | |
46 | 45 | | |
47 | 46 | | |
| |||
363 | 362 | | |
364 | 363 | | |
365 | 364 | | |
366 | | - | |
| 365 | + | |
367 | 366 | | |
368 | 367 | | |
369 | 368 | | |
370 | 369 | | |
371 | 370 | | |
372 | | - | |
| 371 | + | |
373 | 372 | | |
374 | 373 | | |
375 | 374 | | |
| |||
410 | 409 | | |
411 | 410 | | |
412 | 411 | | |
413 | | - | |
| 412 | + | |
414 | 413 | | |
415 | 414 | | |
416 | 415 | | |
417 | 416 | | |
418 | 417 | | |
419 | | - | |
| 418 | + | |
420 | 419 | | |
421 | 420 | | |
422 | 421 | | |
423 | 422 | | |
424 | 423 | | |
425 | | - | |
| 424 | + | |
426 | 425 | | |
427 | 426 | | |
428 | 427 | | |
429 | 428 | | |
430 | 429 | | |
431 | | - | |
| 430 | + | |
432 | 431 | | |
433 | 432 | | |
434 | 433 | | |
435 | 434 | | |
436 | 435 | | |
437 | | - | |
| 436 | + | |
438 | 437 | | |
439 | 438 | | |
440 | 439 | | |
| |||
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2210 | 2210 | | |
2211 | 2211 | | |
2212 | 2212 | | |
| 2213 | + | |
| 2214 | + | |
2213 | 2215 | | |
2214 | 2216 | | |
2215 | 2217 | | |
| |||
2226 | 2228 | | |
2227 | 2229 | | |
2228 | 2230 | | |
2229 | | - | |
2230 | | - | |
| 2231 | + | |
| 2232 | + | |
2231 | 2233 | | |
2232 | | - | |
| 2234 | + | |
2233 | 2235 | | |
2234 | 2236 | | |
2235 | 2237 | | |
| |||
hugegraph-server/hugegraph-core/src/main/java/org/apache/hugegraph/auth/StandardAuthManagerV2.java
Lines changed: 16 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1519 | 1519 | | |
1520 | 1520 | | |
1521 | 1521 | | |
| 1522 | + | |
| 1523 | + | |
| 1524 | + | |
| 1525 | + | |
| 1526 | + | |
| 1527 | + | |
| 1528 | + | |
1522 | 1529 | | |
1523 | 1530 | | |
1524 | 1531 | | |
| |||
1577 | 1584 | | |
1578 | 1585 | | |
1579 | 1586 | | |
| 1587 | + | |
1580 | 1588 | | |
1581 | 1589 | | |
1582 | 1590 | | |
1583 | 1591 | | |
1584 | 1592 | | |
| 1593 | + | |
1585 | 1594 | | |
1586 | 1595 | | |
1587 | 1596 | | |
1588 | 1597 | | |
| 1598 | + | |
| 1599 | + | |
| 1600 | + | |
| 1601 | + | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
1589 | 1605 | | |
1590 | 1606 | | |
1591 | 1607 | | |
| |||
0 commit comments