Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Transaction #6

Merged
merged 6 commits into from Jul 11, 2011
Merged

Transaction #6

merged 6 commits into from Jul 11, 2011

Conversation

starkj
Copy link

@starkj starkj commented Jun 28, 2011

Interface for transactions derived from javax.transaction.UserTransaction

Johannes Stark added 3 commits June 27, 2011 17:36
…tion

As there is no transaction standard in PHP this interface should provide a transaction mechanism in a way the original Java UserTransaction interface can be used for transactions while working with the JCR API.
(see comments of former commit)
* application is not allowed to commit the transaction.
* @throws LogicException Thrown if the current session is not associated
* with a transaction.
* @throws \PHPCR\RepositoryException Thrown if the transaction implementation
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i assume a timeout would qualify for this exception?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to stay close to the Java spec. There is no exception that is more specific. So yes, I guess a time out would qualify for this one.

@lsmith77
Copy link
Member

ok, then i dont have any more feedback. i will poke the midgard guys.

@piotras
Copy link
Contributor

piotras commented Jun 28, 2011

begin() "Create a new transaction and associate it with the current session."

It rather should be:

"Begins new transaction associated with current session."

A session is responsible to create transaction.

namespace PHPCR\Transaction;

/**
* As there is no transaction standard in PHP this interface should provide a
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry, somehow github lost my comment on this apparently.

i would suggest to just explain to the php user how the transaction works. and have a note that this is not part of jcr as there is a java standard, and put all the details into doc/JCR_TO_PHPCR.txt

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done, or do you think more info on how to deal with transactions should be provided here?

@dbu
Copy link
Member

dbu commented Jun 28, 2011

like this. apart from the doc issue (jcr-to-phpcr.txt) i just commented, i think it can be merged.

lsmith77 added a commit that referenced this pull request Jul 11, 2011
@lsmith77 lsmith77 merged commit c525370 into phpcr:master Jul 11, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants