[JBoss JIRA] Created: (DNA-448) The 'createIfMissing()' methods should be removed from the Graph API
by Randall Hauch (JIRA)
The 'createIfMissing()' methods should be removed from the Graph API
--------------------------------------------------------------------
Key: DNA-448
URL: https://jira.jboss.org/jira/browse/DNA-448
Project: DNA
Issue Type: Bug
Components: API, Graph
Affects Versions: 0.4
Reporter: Randall Hauch
Fix For: 0.6
This issue stemmed from DNA-443. The existence of the "createIfMissing()" methods that exist only on the Graph interface (and not the Graph.Batch interface) mask the existence of newer, more powerful methods that can do the same thing on Graph and Graph.Batch:
graph.create(path).ifAbsent()...
or
batch.create(path).ifAbsent()...
In fact, this style makes available several other methods than "ifAbsent()", such as "orUpdate()", "byAppending()", and "orReplace()". These correspond to the different NodeConflictBehavior options.
Unfortunately, the 'create()' methods just return the Conjunction interface, while the 'createIfMissing()' methods return the "GetNodeConjunction" interface (which extends Conjunction and adds the "andReturn():Node" method). And there is at least one place where 'createIfMissing(...).andReturn()' is being called. Looking at this now, I'm not sure why the Graph.create(...) methods can't return the GetNodeConjunction interface. This would allow the existing uses of the 'createIfMissing(...).andReturn()' to replace them with 'create(...).ifAbsent().andReturn()' calls, and enable the removal of the 'createIfMissing(...)' methods.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months
[JBoss JIRA] Created: (DNA-485) Standardize Default Workspace Name Property Across Sources
by Brian Carothers (JIRA)
Standardize Default Workspace Name Property Across Sources
----------------------------------------------------------
Key: DNA-485
URL: https://jira.jboss.org/jira/browse/DNA-485
Project: DNA
Issue Type: Feature Request
Components: API, Connectors
Affects Versions: 0.5
Reporter: Brian Carothers
Priority: Minor
Most (if not all) repositories will likely have the concept of a default workspace that has a configurable name. The in-memory, JBoss Cache, and Infinispan repositories already have this feature. However, they use different names for the property on the repository source object (in-memory -> defaultWorkspaceName, JBC -> nameOfDefaultWorkspace, Infinispan -> nameOfDefaultWorkspace).
Strictly speaking, this is a syntactically acceptable approach, but from a usability standpoint, it makes sense to establish naming conventions for common property names. Since the in-memory repository is very widely used in the codebase already, it probably makes the most sense to standardize on "defaultWorkspaceName" as the property containing the name of the default workspace.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months
[JBoss JIRA] Created: (DNA-484) Repository Startup Errors Use String[].toString() in Error Message
by Brian Carothers (JIRA)
Repository Startup Errors Use String[].toString() in Error Message
------------------------------------------------------------------
Key: DNA-484
URL: https://jira.jboss.org/jira/browse/DNA-484
Project: DNA
Issue Type: Bug
Components: Graph
Affects Versions: 0.5
Reporter: Brian Carothers
Priority: Minor
If one attempts to create a repository based on a source that is not in the classpath and one applies the patch to expose the startup problems, one will get a message like this:
ERROR: Unable to load class "org.jboss.dna.graph.connector.jbosscache.JBossCacheSource" using classpath "[Ljava.lang.String;@9444d1" (threw org.jboss.dna.graph.connector.jbosscache.JBossCacheSource)
The classpath String[] argument is being printed directly instead of being converted to a list first to handle the pretty-printing.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months
[JBoss JIRA] Created: (DNA-480) Clean up compiler warnings
by Randall Hauch (JIRA)
Clean up compiler warnings
--------------------------
Key: DNA-480
URL: https://jira.jboss.org/jira/browse/DNA-480
Project: DNA
Issue Type: Task
Components: Graph, JCR
Affects Versions: 0.5
Reporter: Randall Hauch
Assignee: Randall Hauch
Priority: Blocker
Fix For: 0.6
Read access to enclosing field Graph.CloneAction<T>.from is emulated by a synthetic accessor method. Increasing its visibility will improve your performance Graph.java dna-graph/src/main/java/org/jboss/dna/graph line 6227
Read access to enclosing field Graph.CloneAction<T>.from is emulated by a synthetic accessor method. Increasing its visibility will improve your performance Graph.java dna-graph/src/main/java/org/jboss/dna/graph line 6238
The declared exception SAXException is not actually thrown by the method addNodeIfPending() from type JcrContentHandler.SystemViewContentHandler JcrContentHandler.java dna-jcr/src/main/java/org/jboss/dna/jcr line 302
The declared exception SAXException is not actually thrown by the method characters(char[], int, int) from type JcrContentHandler.DocumentViewContentHandler JcrContentHandler.java dna-jcr/src/main/java/org/jboss/dna/jcr line 501
The declared exception SAXException is not actually thrown by the method startElement(String, String, String, Attributes) from type JcrContentHandler.DocumentViewContentHandler JcrContentHandler.java dna-jcr/src/main/java/org/jboss/dna/jcr line 419
The method addNodeToMap(MapNode) of type InMemoryRepository.Workspace should be tagged with @Override since it actually overrides a superclass method InMemoryRepository.java dna-graph/src/main/java/org/jboss/dna/graph/connector/inmemory line 73
The method addNodeToMap(MapNode) of type JBossCacheRepository.Workspace should be tagged with @Override since it actually overrides a superclass method JBossCacheRepository.java dna-connector-jbosscache/src/main/java/org/jboss/dna/connector/jbosscache line 59
The method createWorkspace(ExecutionContext, String) of type InMemoryRepository should be tagged with @Override since it actually overrides a superclass method InMemoryRepository.java dna-graph/src/main/java/org/jboss/dna/graph/connector/inmemory line 58
The method getNode(UUID) of type InMemoryRepository.Workspace should be tagged with @Override since it actually overrides a superclass method InMemoryRepository.java dna-graph/src/main/java/org/jboss/dna/graph/connector/inmemory line 88
The method getNode(UUID) of type JBossCacheRepository.Workspace should be tagged with @Override since it actually overrides a superclass method JBossCacheRepository.java dna-connector-jbosscache/src/main/java/org/jboss/dna/connector/jbosscache line 73
The method removeAllNodesFromMap() of type InMemoryRepository.Workspace should be tagged with @Override since it actually overrides a superclass method InMemoryRepository.java dna-graph/src/main/java/org/jboss/dna/graph/connector/inmemory line 84
The method removeAllNodesFromMap() of type JBossCacheRepository.Workspace should be tagged with @Override since it actually overrides a superclass method JBossCacheRepository.java dna-connector-jbosscache/src/main/java/org/jboss/dna/connector/jbosscache line 69
The method removeNodeFromMap(UUID) of type InMemoryRepository.Workspace should be tagged with @Override since it actually overrides a superclass method InMemoryRepository.java dna-graph/src/main/java/org/jboss/dna/graph/connector/inmemory line 79
The method removeNodeFromMap(UUID) of type JBossCacheRepository.Workspace should be tagged with @Override since it actually overrides a superclass method JBossCacheRepository.java dna-connector-jbosscache/src/main/java/org/jboss/dna/connector/jbosscache line 64
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months