Skip to main content
assistive.skiplink.to.breadcrumbs
assistive.skiplink.to.header.menu
assistive.skiplink.to.action.menu
assistive.skiplink.to.quick.search
Log in
Confluence
Spaces
Hit enter to search
Help
Online Help
Keyboard Shortcuts
Feed Builder
What’s new
Available Gadgets
About Confluence
Log in
SEI CERT Oracle Coding Standard for Java
Pages
Boards
Space shortcuts
Dashboard
Secure Coding Home
Android
C
C++
Java
Perl
Page tree
Browse pages
Configure
Space tools
View Page
A
t
tachments (3)
Page History
Page Information
View in Hierarchy
View Source
Export to PDF
Export to Word
Pages
…
SEI CERT Oracle Coding Standard for Java
2 Rules
Rule 09. Locking (LCK)
Page Information
Title:
Rule 09. Locking (LCK)
Author:
Dhruv Mohindra
Jul 20, 2008
Last Changed by:
David Svoboda
Mar 15, 2022
Tiny Link:
(useful for email)
https://wiki.sei.cmu.edu/confluence/x/8jZGBQ
Export As:
Word
·
PDF
Incoming Links
SEI CERT Oracle Coding Standard for Java (7)
Page:
LCK07-J. Avoid deadlock by requesting and releasing locks in the same order
Page:
LCK06-J. Do not use an instance lock to protect shared static data
Page:
LCK00-J. Use private final lock objects to synchronize classes that may interact with untrusted code
Page:
LCK05-J. Synchronize access to static fields that can be modified by untrusted code
Page:
LCK02-J. Do not synchronize on the class object returned by getClass()
Page:
LCK03-J. Do not synchronize on the intrinsic locks of high-level concurrency objects
Page:
LCK11-J. Avoid client-side locking when using classes that do not commit to their locking strategy
Hierarchy
Parent Page
Page:
2 Rules
Children (12)
Page:
LCK00-J. Use private final lock objects to synchronize classes that may interact with untrusted code
Page:
LCK01-J. Do not synchronize on objects that may be reused
Page:
LCK02-J. Do not synchronize on the class object returned by getClass()
Page:
LCK03-J. Do not synchronize on the intrinsic locks of high-level concurrency objects
Page:
LCK04-J. Do not synchronize on a collection view if the backing collection is accessible
Page:
LCK05-J. Synchronize access to static fields that can be modified by untrusted code
Page:
LCK06-J. Do not use an instance lock to protect shared static data
Page:
LCK07-J. Avoid deadlock by requesting and releasing locks in the same order
Page:
LCK08-J. Ensure actively held locks are released on exceptional conditions
Page:
LCK09-J. Do not perform operations that can block while holding a lock
Show all...
Page:
LCK10-J. Use a correct form of the double-checked locking idiom
Page:
LCK11-J. Avoid client-side locking when using classes that do not commit to their locking strategy
Hide...
Labels
Global Labels (4)
lck
rule-list
review1
section
Recent Changes
Time
Editor
Mar 15, 2022 09:46
David Svoboda
View Changes
Mar 11, 2020 12:55
David Svoboda
View Changes
Nov 21, 2018 14:11
Derek Leung
View Changes
Nov 20, 2018 14:34
Derek Leung
View Changes
Nov 20, 2018 13:50
Derek Leung
View Page History
Outgoing Links
External Links (3)
https://wiki.sei.cmu.edu/confluence/pages/viewpage.action?p…
https://wiki.sei.cmu.edu/confluence/pages/viewpage.action?p…
https://wiki.sei.cmu.edu/confluence/pages/viewpage.action?p…
SEI CERT Oracle Coding Standard for Java (1)
Home page:
SEI CERT Oracle Coding Standard for Java
Overview
Content Tools
{"serverDuration": 95, "requestCorrelationId": "a965e9a227c8cb3e"}