Re: [MarkLogic Dev General] ROXY bootstrap not working with LDAP enabled 8000, 8002 servers

2015-08-18 Thread Sudheer Yalaverthi
Hi Dave,

I tried it. I have the nobody user but that user is not assigned rest-reader, 
rest-extension-user roles. I assigned those roles manually. (I did a wipe 
earlier when I did not enable external security on 8000 and 8002)

When I did the bootstrap, I still got the same error.

But from the error log file, it looks like this error is happening when trying 
to retrieve the default user.


2015-08-18 20:47:53.944 Info: App-Services: http://marklogic.com/xdmp/error error.xsd" 
xmlns:error="http://marklogic.com/xdmp/error"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
2015-08-18 20:47:53.944 Info: App-Services:   
SEC-USERDNE
2015-08-18 20:47:53.944 Info: App-Services:   
2015-08-18 20:47:53.944 Info: App-Services:   
1.0-ml
2015-08-18 20:47:53.944 Info: App-Services:   User does not 
exist
2015-08-18 20:47:53.944 Info: App-Services:   SEC-USERDNE: 
xdmp:user("nobody") -- User does not exist: user-name = 
nobody
2015-08-18 20:47:53.944 Info: App-Services:   
false
2015-08-18 20:47:53.944 Info: App-Services:   
xdmp:user("nobody")
2015-08-18 20:47:53.944 Info: App-Services:   
2015-08-18 20:47:53.944 Info: App-Services: 
user-name
2015-08-18 20:47:53.944 Info: App-Services: 
nobody
2015-08-18 20:47:53.944 Info: App-Services:   
2015-08-18 20:47:53.944 Info: App-Services:   
2015-08-18 20:47:53.944 Info: App-Services: 
2015-08-18 20:47:53.944 Info: App-Services:   3
2015-08-18 20:47:53.944 Info: App-Services:   8
2015-08-18 20:47:53.944 Info: App-Services:   
xdmp:eval("
declare variable $username 
external;
xd...", (fn:QName("", "username"), 
"nobody"))
2015-08-18 20:47:53.944 Info: App-Services:   
1.0-ml
2015-08-18 20:47:53.944 Info: App-Services: 
2015-08-18 20:47:53.944 Info: App-Services: 
2015-08-18 20:47:53.944 Info: App-Services:   4934
2015-08-18 20:47:53.944 Info: App-Services:   6
2015-08-18 20:47:53.944 Info: App-Services:   
setup:get-appserver-default-user(roxy8060;)
2015-08-18 20:47:53.944 Info: App-Services:   
2015-08-18 20:47:53.944 Info: App-Services:  
2015-08-18 20:47:53.944 Info: App-Services:server-config
2015-08-18 20:47:53.944 Info: App-Services:roxy8060;
2015-08-18 20:47:53.944 Info: App-Services:  
2015-08-18 20:47:53.944 Info: App-Services:  
2015-08-18 20:47:53.944 Info: App-Services:user
2015-08-18 20:47:53.944 Info: App-Services:
"nobody"
2015-08-18 20:47:53.944 Info: App-Services:  
2015-08-18 20:47:53.944 Info: App-Services:   
2015-08-18 20:47:53.944 Info: App-Services:   
1.0-ml
2015-08-18 20:47:53.944 Info: App-Services: 


When I had the ldpap user as the default user, the error was different and it 
is thrown when the default user is set.

2015-08-18 20:40:36.754 Info: App-Services: http://marklogic.com/xdmp/error error.xsd" 
xmlns:error="http://marklogic.com/xdmp/error"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
2015-08-18 20:40:36.754 Info: App-Services:   
ADMIN-NOSUCHUSER
2015-08-18 20:40:36.754 Info: App-Services:   
err:FOER
2015-08-18 20:40:36.754 Info: App-Services:   
1.0-ml
2015-08-18 20:40:36.754 Info: App-Services:   No such 
user
2015-08-18 20:40:36.754 Info: App-Services:   
ADMIN-NOSUCHUSER: (err:FOER) No such user 
16189239036379934068
2015-08-18 20:40:36.754 Info: App-Services:   
false
2015-08-18 20:40:36.754 Info: App-Services:
2015-08-18 20:40:36.754 Info: App-Services:   
2015-08-18 20:40:36.754 Info: App-Services: 
16189239036379934068
2015-08-18 20:40:36.754 Info: App-Services:   
2015-08-18 20:40:36.754 Info: App-Services:   
2015-08-18 20:40:36.754 Info: App-Services: 
2015-08-18 20:40:36.754 Info: App-Services:   
/MarkLogic/admin.xqy
2015-08-18 20:40:36.754 Info: App-Services:   9417
2015-08-18 20:40:36.754 Info: App-Services:   6
2015-08-18 20:40:36.754 Info: App-Services:   
admin:appserver-set-default-user(config
2015-08-18 20:40:36.754 Info: App-Services:
Re: [MarkLogic Dev General] ROXY bootstrap not working with LDAP enabled 8000, 8002 servers

The "nobody" user is set up by MarkLogic by default, so it ought to be there. 
I'd try recreating that user (roles: rest-reader, rest-extension-user, 
app-user; do it manually through the Admin UI), then try bootstrapping again 
with nobody as the default user.

If that works, then the question is, what happened to the nobody user? If you 
have that user defined in ml-config.xml and you have run the wipe command, it 
may have gotten deleted that way, but you shouldn't need to have it in your 
ml-config.xml.

--
Dave Cassel, @dmcassel
Technical Community Manager
MarkLogic Corporation
http://developer.marklogic.com/


From: 
mailto:general-boun...@developer.marklogic.com>>
 on behalf of Geert Josten 
mailto:geert.jos...@marklogic.com>>
Reply-To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Date: Tuesday, August 18, 2015 at 3:39 PM
To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Subject: Re: [MarkLogic Dev General] ROXY bootstrap not working with LDAP 
enabled 8000, 8002 servers

Does the ErrorLog.txt provide additional detail?

Cheers,
Geert

From: 
mailto:general-boun...@developer.marklogic.com>>
 on behalf of Sudheer Yalaverthi 
mailto:sudheer.yalaver...@db.com>>
Reply-To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Date: Tuesday, August 18, 2015 at 9:34 PM
To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Subject: [MarkLogic Dev General] ROXY bootstrap not working with LDAP enabled 
8000, 8002 servers

Hi,


I have MarkLogic instance with LDAP external security enabled for both servers 
that are running at 8000 and 8002.

I have given an ldap user as user in the build.properties. I changed the 
default-user to nobody.

While I am trying to bootstrap using roxy to my local environment, I am seeing 
below error.

[root@loninenghost49 roxy-master]# ./ml local bootstrap
Bootstrapping your project into MarkLogic 7 on loninenghost49...
Password for cd1admin1 user:
ERROR: note: restart required
SEC-USERDNE: xdmp:user("nobody") -- User does not exist: user-name = nobody
See MarkLogic Server error log for more details.
ERROR: ... Bootstrap FAILED

When I gave the cd1admin1 which is my ldap user as the default-user in 
build.properties, then I am getting the below error.

[root@ loninenghost49 roxy-master]# ./ml local bootstrap
Bootstrapping your project into MarkLogic 7 on loninenghost49...
Password for cd1admin1 user:
ERROR: note: restart required
ADMIN-NOSUCHUSER: (err:FOER) No such user 16189239036379934068
See MarkLogic Server error log for more details.
ERROR: ... Bootstrap FAILED


What am I doing wrong here?



Regards,
Sudheer Yalaverthi
NoSQL Engineer



---
This communication may contain confidential and/or privileged information. If 
you are not the intended recipient (or have received this communication in 
error) please notify the sender immediately and destroy this communication. Any 
unauthorized copying, disclosure or distribution of the material in this 
communication is strictly forbidden.

Deutsche Bank does not render legal or tax advice, and the information 
contained in this communication should not be regarded as such.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] ROXY bootstrap not working with LDAP enabled 8000, 8002 servers

Does the ErrorLog.txt provide additional detail?

Cheers,
Geert

From: 
mailto:general-boun...@developer.marklogic.com>>
 on behalf of Sudheer Yalaverthi 
mailto:sudheer.yalaver...@db.com>>
Reply-To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Date: Tuesday, August 18, 2015 at 9:34 PM
To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Subject: [MarkLogic Dev General] ROXY bootstrap not working with LDAP enabled 
8000, 8002 servers

Hi,


I have MarkLogic instance with LDAP external security enabled for both servers 
that are running at 8000 and 8002.

I have given an ldap user as user in the build.properties. I changed the 
default-user to nobody.

While I am trying to bootstrap using roxy to my local environment, I am seeing 
below error.

[root@loninenghost49 roxy-master]# ./ml local bootstrap
Bootstrapping your project into MarkLogic 7 on loninenghost49...
Password for cd1admin1 user:
ERROR: note: restart required
SEC-USERDNE: xdmp:user("nobody") -- User does not exist: user-name = nobody
See MarkLogic Server error log for more details.
ERROR: ... Bootstrap FAILED

When I gave the cd1admin1 which is my ldap user as the default-user in 
build.properties, then I am getting the below error.

[root@ loninenghost49 roxy-master]# ./ml local bootstrap
Bootstrapping your project into MarkLogic 7 on loninenghost49...
Password for cd1admin1 user:
ERROR: note: restart required
ADMIN-NOSUCHUSER: (err:FOER) No such user 16189239036379934068
See MarkLogic Server error log for more details.
ERROR: ... Bootstrap FAILED


What am I doing wrong here?



Regards,
Sudheer Yalaverthi
NoSQL Engineer



---
This communication may contain confidential and/or privileged information. If 
you are not the intended recipient (or have received this communication in 
error) please notify the sender immediately and destroy this communication. Any 
unauthorized copying, disclosure or distribution of the material in this 
communication is strictly forbidden.

Deutsche Bank does not render legal or tax advice, and the information 
contained in this communication should not be regarded as such.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] ROXY bootstrap not working with LDAP enabled 8000, 8002 servers

Hi,


I have MarkLogic instance with LDAP external security enabled for both servers 
that are running at 8000 and 8002.

I have given an ldap user as user in the build.properties. I changed the 
default-user to nobody.

While I am trying to bootstrap using roxy to my local environment, I am seeing 
below error.

[root@loninenghost49 roxy-master]# ./ml local bootstrap
Bootstrapping your project into MarkLogic 7 on loninenghost49...
Password for cd1admin1 user:
ERROR: note: restart required
SEC-USERDNE: xdmp:user("nobody") -- User does not exist: user-name = nobody
See MarkLogic Server error log for more details.
ERROR: ... Bootstrap FAILED

When I gave the cd1admin1 which is my ldap user as the default-user in 
build.properties, then I am getting the below error.

[root@ loninenghost49 roxy-master]# ./ml local bootstrap
Bootstrapping your project into MarkLogic 7 on loninenghost49...
Password for cd1admin1 user:
ERROR: note: restart required
ADMIN-NOSUCHUSER: (err:FOER) No such user 16189239036379934068
See MarkLogic Server error log for more details.
ERROR: ... Bootstrap FAILED


What am I doing wrong here?



Regards,
Sudheer Yalaverthi
NoSQL Engineer



---
This communication may contain confidential and/or privileged information. If 
you are not the intended recipient (or have received this communication in 
error) please notify the sender immediately and destroy this communication. Any 
unauthorized copying, disclosure or distribution of the material in this 
communication is strictly forbidden.

Deutsche Bank does not render legal or tax advice, and the information 
contained in this communication should not be regarded as such.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] path range index

Thanks,
Easy enough. ML8 doc little harder to search around.
-Paul
  From: Danny Sokolsky 
 To: Paul M ; MarkLogic Developer Discussion 
 
 Sent: Tuesday, August 18, 2015 1:41 PM
 Subject: RE: [MarkLogic Dev General] path range index
   
#yiv8123869589 #yiv8123869589 -- _filtered #yiv8123869589 
{font-family:Helvetica;panose-1:2 11 6 4 2 2 2 2 2 4;} _filtered #yiv8123869589 
{font-family:Helvetica;panose-1:2 11 6 4 2 2 2 2 2 4;} _filtered #yiv8123869589 
{font-family:Calibri;panose-1:2 15 5 2 2 2 4 3 2 4;} _filtered #yiv8123869589 
{font-family:Tahoma;panose-1:2 11 6 4 3 5 4 4 2 4;}#yiv8123869589 
#yiv8123869589 p.yiv8123869589MsoNormal, #yiv8123869589 
li.yiv8123869589MsoNormal, #yiv8123869589 div.yiv8123869589MsoNormal 
{margin:0in;margin-bottom:.0001pt;font-size:12.0pt;}#yiv8123869589 a:link, 
#yiv8123869589 span.yiv8123869589MsoHyperlink 
{color:blue;text-decoration:underline;}#yiv8123869589 a:visited, #yiv8123869589 
span.yiv8123869589MsoHyperlinkFollowed 
{color:purple;text-decoration:underline;}#yiv8123869589 
span.yiv8123869589EmailStyle17 {color:#1F497D;}#yiv8123869589 
.yiv8123869589MsoChpDefault {font-size:10.0pt;} _filtered #yiv8123869589 
{margin:1.0in 1.0in 1.0in 1.0in;}#yiv8123869589 div.yiv8123869589WordSection1 
{}#yiv8123869589 Hi Paul,    Try cts:values:    
http://docs.marklogic.com/cts:values    You can use it for any kind of range 
index.  You pass it a cts:reference for the path index:    
http://docs.marklogic.com/cts:path-reference    -Danny    

From: general-boun...@developer.marklogic.com 
[mailto:general-boun...@developer.marklogic.com]On Behalf Of Paul M
Sent: Tuesday, August 18, 2015 10:28 AM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] path range index    Suppose I want all the 
values for a specific path range index. Normally, I would use 
cts:element-values and cts:frequencey on a range index. How would I do this on 
a path range index, if possible.       Thank You. 

  ___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] path range index

Hi Paul,

Try cts:values:

http://docs.marklogic.com/cts:values

You can use it for any kind of range index.  You pass it a cts:reference for 
the path index:

http://docs.marklogic.com/cts:path-reference

-Danny

From: general-boun...@developer.marklogic.com 
[mailto:general-boun...@developer.marklogic.com] On Behalf Of Paul M
Sent: Tuesday, August 18, 2015 10:28 AM
To: MarkLogic Developer Discussion
Subject: [MarkLogic Dev General] path range index

Suppose I want all the values for a specific path range index.
Normally, I would use cts:element-values and cts:frequencey on a range index. 
How would I do this on a path range index, if possible.


Thank You.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] path range index

On Tue, 18 Aug 2015 10:27:44 -0700, Paul M  wrote:

> Suppose I want all the values for a specific path range index.Normally,  
> I would use cts:element-values and cts:frequencey on a range index. How  
> would I do this on a path range index, if possible.
>
> Thank You.


Yes, use cts:values:

cts:values( cts:path-reference("/your/path/",  
"collation=http://marklogic.com/collation/"; )

Substituting in the appropriate path and collation.

//Mary
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] path range index

Take a look at the example in the cts:values documentation 
. (Spoiler: You'll need a 
cts:path-reference  .)

Justin


> On Aug 18, 2015, at 10:27 AM, Paul M  wrote:
> 
> Suppose I want all the values for a specific path range index.
> Normally, I would use cts:element-values and cts:frequencey on a range index. 
> How would I do this on a path range index, if possible.
> 
> 
> Thank You.
> ___
> General mailing list
> General@developer.marklogic.com
> Manage your subscription at: 
> http://developer.marklogic.com/mailman/listinfo/general



smime.p7s
Description: S/MIME cryptographic signature
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] path range index

Suppose I want all the values for a specific path range index.Normally, I would 
use cts:element-values and cts:frequencey on a range index. How would I do this 
on a path range index, if possible.

Thank You.
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] Server Message: SVC-EXTIME: xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time limit exceeded.

Hi, Abhinav:

It looks like you are hitting the transaction time limit before committing the 
multi-statement transaction, so the transaction no longer exists for those 
writes.

It's not a good idea to build up huge transactions. In particular, the code 
that's trying to pool the multi-statement transactions might misunderstand the 
purpose of multi-statement transactions in MarkLogic.

Really, multi-statement transactions are for changes that must commit or fail 
together to leave the database in a consistent state.  The canonical examples 
are a balance transfer or the write and delete operations for a document move.

If the write for one document failed to write (maybe it had a bad format) and 
the rest wrote correctly, would that be preferable to having all writes fail?  
If so, you shouldn't use multi-statement transactions. Single document writes 
are still transactional without the explicit multi-statement transaction.

If you're using MarkLogic 8, you might also consider writing documents in bulk 
(typically of around 100 for optimal sized documents) for better performance.  
Bulk writes are also transactional.


Hoping that helps,


Erik Hennum


From: general-boun...@developer.marklogic.com 
[general-boun...@developer.marklogic.com] on behalf of 
abhinav.mish...@cognizant.com [abhinav.mish...@cognizant.com]
Sent: Tuesday, August 18, 2015 5:05 AM
To: general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded.

Hi Team,
Just want add few more info. We are sometimes getting below errors as well.

Java Layer:
com.marklogic.client.FailedRequestException: Local message: transaction 
rollback failed: Bad Request. Server Message: XDMP-NOTXN: 
xdmp:xa-complete1(xs:unsignedLong("5231619190085809367"), 
xs:unsignedLong("13101616944000907690"), fn:false()) -- No transaction with 
identifier 13101616944000907690
   at 
com.marklogic.client.impl.JerseyServices.completeTransaction(JerseyServices.java:1488)
   at 
com.marklogic.client.impl.JerseyServices.rollbackTransaction(JerseyServices.java:1420)
   at 
com.marklogic.client.impl.TransactionImpl.rollback(TransactionImpl.java:70)


MarkLogic Log:
2015-08-18 15:39:24.551 Info: REST-ContentStore: Status 500: XDMP-NOTXN: 
xdmp:invoke("/MarkLogic/rest-api/lib/transaction-runner-update.xqy", 
(as:QName("", "method"), "PUT", as:QName("", "headers"), ...), 13101616944000907690)
 -- No transaction with identifier 13101616944000907690
2015-08-18 15:39:25.347 Info: REST-ContentStore: Status 500: XDMP-NOTXN: 
xdmp:xa-complete1(xs:unsignedLong("5231619190085809367"), 
xs:unsignedLong("13101616944000907690"), fn:false()) -- No transaction with 
identifier 13101616944000907690

Regards,
Abhinav
From: Mishra, Abhinav Kumar (Cognizant)
Sent: Tuesday, August 18, 2015 12:24 PM
To: general@developer.marklogic.com
Subject: Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded.

Hi Team,
We are running into an issue, where in we are getting exception from MarkLogic 
as given below:

“write failed: Internal Server Error. Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded.”

But In MarkLogic logs I don’t see any log for the above statement. I have 
enabled log to debug mode on MarkLogic as well. We are not sure what is the 
exact reason of this failure.
I would really appreciate if you can provide some clues.

Now let me explain what we are doing..

We are saving xml documents to MarkLogic from a java based application. We have 
used MarkLogic’ s OOTB REST Java Client API. It will internally use 
”/documents” service via PUT request.
I have highlighted the RESTServices.putDocument(..) method below which will 
actually put the documents to MarkLogic.
We are opening the transaction, saving document to MarkLogic and then closing 
the transaction.


Code snippet:

   //rest-user has all the privileges required to load the documents in 
MarkLogic.
  DatabaseClient client = DatabaseClientFactory.newClient(“”, 
8004,rest-user, rest-user-password, Authentication.DIGEST);
  Transaction transaction = client.openTransaction();

try {
  //Here we are sending following parameters from outside, “[String 
path, InputStream is, Transaction transaction, String collection]”
//Where, path="/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc”
 // InputStream will have the xml document as a stream
// transaction is the implementation of com.marklogic.clinet.Transaction
// collection = “doc-versions”


 TransactionPoolableFactory transactionFactory = new 
TransactionPoolableFactory();
 GenericKeyedObjectPool transactionPool = 
new GenericKeyedObjectPool(transactionFactory);
 transactionPool.setTestOnReturn(true);
DatabaseClient cli

Re: [MarkLogic Dev General] Server Message: SVC-EXTIME: xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time limit exceeded.

The basic concept is that you are getting a deadlock due to an open transaction 
holding a lock.

I don't have enough scope of your code to say where exactly,
but use of 'multi statement transactions' (which is what the Transaction object 
represents) is an 'advanced' feature even when short lived in the scope of one 
function.  The code snippets shown have many places where transactions could be 
conceivably 'lost' or held open for longer duration than expected.  I would not 
recommend caching Transaction objects, its very difficult to guarantee the 
lifecycle if they the object references are stored anywhere but as local 
variables or parameters.  Even more difficult with Java and other GC based 
languages.

Reading this guide will help understanding the correct use of multistatement 
transactions

https://docs.marklogic.com/guide/app-dev/transactions

I recommend first isolating the code so that transactions are not cached,
ideally not used at all unless absolutely needed.

The code snippet as shown doesn't need a transaction, document writes are 
always transactional and will be handled properly in the server. For 
programmers with experience with  other databases this can be counter-intuitive.

Explicitly creating Transitions creates a 'multi statement' transaction which 
is much more complex to manage properly, especially  in a client/server 
environment where the server has no ability to manage exceptions, references 
etc for you.




-
David Lee
Lead Engineer
MarkLogic Corporation
d...@marklogic.com
Phone: +1 812-482-5224
Cell:  +1 812-630-7622
www.marklogic.com

From: general-boun...@developer.marklogic.com 
[mailto:general-boun...@developer.marklogic.com] On Behalf Of 
abhinav.mish...@cognizant.com
Sent: Tuesday, August 18, 2015 8:05 AM
To: general@developer.marklogic.com
Subject: Re: [MarkLogic Dev General] Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded.

Hi Team,
Just want add few more info. We are sometimes getting below errors as well.

Java Layer:
com.marklogic.client.FailedRequestException: Local message: transaction 
rollback failed: Bad Request. Server Message: XDMP-NOTXN: 
xdmp:xa-complete1(xs:unsignedLong("5231619190085809367"), 
xs:unsignedLong("13101616944000907690"), fn:false()) -- No transaction with 
identifier 13101616944000907690
   at 
com.marklogic.client.impl.JerseyServices.completeTransaction(JerseyServices.java:1488)
   at 
com.marklogic.client.impl.JerseyServices.rollbackTransaction(JerseyServices.java:1420)
   at 
com.marklogic.client.impl.TransactionImpl.rollback(TransactionImpl.java:70)


MarkLogic Log:
2015-08-18 15:39:24.551 Info: REST-ContentStore: Status 500: XDMP-NOTXN: 
xdmp:invoke("/MarkLogic/rest-api/lib/transaction-runner-update.xqy", 
(as:QName("", "method"), "PUT", as:QName("", "headers"), ...), 13101616944000907690)
 -- No transaction with identifier 13101616944000907690
2015-08-18 15:39:25.347 Info: REST-ContentStore: Status 500: XDMP-NOTXN: 
xdmp:xa-complete1(xs:unsignedLong("5231619190085809367"), 
xs:unsignedLong("13101616944000907690"), fn:false()) -- No transaction with 
identifier 13101616944000907690

Regards,
Abhinav
From: Mishra, Abhinav Kumar (Cognizant)
Sent: Tuesday, August 18, 2015 12:24 PM
To: general@developer.marklogic.com
Subject: Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded.

Hi Team,
We are running into an issue, where in we are getting exception from MarkLogic 
as given below:

"write failed: Internal Server Error. Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded."

But In MarkLogic logs I don't see any log for the above statement. I have 
enabled log to debug mode on MarkLogic as well. We are not sure what is the 
exact reason of this failure.
I would really appreciate if you can provide some clues.

Now let me explain what we are doing..

We are saving xml documents to MarkLogic from a java based application. We have 
used MarkLogic' s OOTB REST Java Client API. It will internally use 
"/documents" service via PUT request.
I have highlighted the RESTServices.putDocument(..) method below which will 
actually put the documents to MarkLogic.
We are opening the transaction, saving document to MarkLogic and then closing 
the transaction.


Code snippet:

   //rest-user has all the privileges required to load the documents in 
MarkLogic.
  DatabaseClient client = DatabaseClientFactory.newClient("", 
8004,rest-user, rest-user-password, Authentication.DIGEST);
  Transaction transaction = client.openTransaction();

try {
  //Here we are sending following parameters from outside, "[String 
path, InputStream is, Transaction transaction, String collection]"

Re: [MarkLogic Dev General] Server Message: SVC-EXTIME: xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time limit exceeded.

Hi Team,
Just want add few more info. We are sometimes getting below errors as well.

Java Layer:
com.marklogic.client.FailedRequestException: Local message: transaction 
rollback failed: Bad Request. Server Message: XDMP-NOTXN: 
xdmp:xa-complete1(xs:unsignedLong("5231619190085809367"), 
xs:unsignedLong("13101616944000907690"), fn:false()) -- No transaction with 
identifier 13101616944000907690
   at 
com.marklogic.client.impl.JerseyServices.completeTransaction(JerseyServices.java:1488)
   at 
com.marklogic.client.impl.JerseyServices.rollbackTransaction(JerseyServices.java:1420)
   at 
com.marklogic.client.impl.TransactionImpl.rollback(TransactionImpl.java:70)


MarkLogic Log:
2015-08-18 15:39:24.551 Info: REST-ContentStore: Status 500: XDMP-NOTXN: 
xdmp:invoke("/MarkLogic/rest-api/lib/transaction-runner-update.xqy", 
(as:QName("", "method"), "PUT", as:QName("", "headers"), ...), 13101616944000907690)
 -- No transaction with identifier 13101616944000907690
2015-08-18 15:39:25.347 Info: REST-ContentStore: Status 500: XDMP-NOTXN: 
xdmp:xa-complete1(xs:unsignedLong("5231619190085809367"), 
xs:unsignedLong("13101616944000907690"), fn:false()) -- No transaction with 
identifier 13101616944000907690

Regards,
Abhinav
From: Mishra, Abhinav Kumar (Cognizant)
Sent: Tuesday, August 18, 2015 12:24 PM
To: general@developer.marklogic.com
Subject: Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded.

Hi Team,
We are running into an issue, where in we are getting exception from MarkLogic 
as given below:

"write failed: Internal Server Error. Server Message: SVC-EXTIME: 
xdmp:lock-for-update("/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc") -- Time 
limit exceeded."

But In MarkLogic logs I don't see any log for the above statement. I have 
enabled log to debug mode on MarkLogic as well. We are not sure what is the 
exact reason of this failure.
I would really appreciate if you can provide some clues.

Now let me explain what we are doing..

We are saving xml documents to MarkLogic from a java based application. We have 
used MarkLogic' s OOTB REST Java Client API. It will internally use 
"/documents" service via PUT request.
I have highlighted the RESTServices.putDocument(..) method below which will 
actually put the documents to MarkLogic.
We are opening the transaction, saving document to MarkLogic and then closing 
the transaction.


Code snippet:

   //rest-user has all the privileges required to load the documents in 
MarkLogic.
  DatabaseClient client = DatabaseClientFactory.newClient("", 
8004,rest-user, rest-user-password, Authentication.DIGEST);
  Transaction transaction = client.openTransaction();

try {
  //Here we are sending following parameters from outside, "[String 
path, InputStream is, Transaction transaction, String collection]"
//Where, path="/docs/0f04c4fb-6058-4758-92eb-f9cfa2ea18bc"
 // InputStream will have the xml document as a stream
// transaction is the implementation of com.marklogic.clinet.Transaction
// collection = "doc-versions"


 TransactionPoolableFactory transactionFactory = new 
TransactionPoolableFactory();
 GenericKeyedObjectPool transactionPool = 
new GenericKeyedObjectPool(transactionFactory);
 transactionPool.setTestOnReturn(true);
DatabaseClient client = transactionPool.borrowObject(transaction);
InputStreamHandle handle = new InputStreamHandle(is);
DocumentMetadataHandle metadata = new DocumentMetadataHandle();
metadata.getCollections().addAll(collection);
DocumentManager docMgr = 
client.newXMLDocumentManager();
docMgr.write(path, metadata, handle, transaction);
   transactionPool.returnObject(transaction, client);

   transaction.commit();
try {
DatabaseClient client = transactionPool.borrowObject(transaction);
transactionPool.invalidateObject(transaction, client);
} catch (Exception e) {
throw new MarkLogicException(e.getMessage(), e);
}

} catch (Exception e) {
e.printStackTrace();

transaction.rollback();
try {
DatabaseClient client = transactionPool.borrowObject(transaction);
transactionPool.invalidateObject(transaction, client);
   } catch (Exception e) {
throw new MarkLogicException(e.getMessage(), e);
}
}


The highlighted "write" method is the implementation of DocumentManager 
interface, see the snippet below:

Interface:
package com.marklogic.client.document;

import com.marklogic.client.FailedRequestException;
import com.marklogic.client.ForbiddenUserException;
import com.marklogic.client.ResourceNotFoundException;
import com.marklogic.client.Transaction;
import com.marklogic.client.io.Format;
import com.marklogic.client.io.marker.AbstractReadHandle;
import com.marklogic.client.io.m