[Jenkins] FAILURE: CouchDB » jenkins-cpse-debugging #25

2019-08-14 Thread Apache Jenkins Server
Boo, we failed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/25/display/redirect

[GitHub] [couchdb] kocolosk commented on issue #2115: Update default config settings (Q, max_document_size, etc.)

2019-08-14 Thread GitBox
kocolosk commented on issue #2115: Update default config settings (Q, 
max_document_size, etc.)
URL: https://github.com/apache/couchdb/issues/2115#issuecomment-521493367
 
 
   I erred on the side of fewer shards because we have splitting but not 
merging, and because the initial setting of 8 was derived from some of our 
deployments which I'd wager are larger than average. But I'm happy to go along 
with whatever consensus (including retaining the current default if that's what 
folks want).
   
   Attachments aren't included in the computation for 
`couchdb.max_document_size`, only the actual JSON fields and values. That said, 
there are absolutely users in the wild with JSON docs larger than 1 MB, and 
this change in defaults could certainly surprise them. In 3.x they'll be able 
to work around it by changing the default on their server, but this is meant as 
a signal to re-think the data model. My experience has been that those large 
docs are problematic for a number of reasons; the somewhat fuzzy limit at which 
the view engine breaks, and the intense write amplification when updating any 
field of the document are two examples that come to mind.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] jiangphcn commented on issue #2030: eunit test timedout errors during jenkins CI

2019-08-14 Thread GitBox
jiangphcn commented on issue #2030: eunit test timedout errors during jenkins 
CI 
URL: https://github.com/apache/couchdb/issues/2030#issuecomment-521488497
 
 
   thanks @wohali for further information. 


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali commented on issue #2030: eunit test timedout errors during jenkins CI

2019-08-14 Thread GitBox
wohali commented on issue #2030: eunit test timedout errors during jenkins CI 
URL: https://github.com/apache/couchdb/issues/2030#issuecomment-521487996
 
 
   A while ago, yes, maybe 2 years now. I can contact them again.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali commented on issue #2113: Publish package on ARM

2019-08-14 Thread GitBox
wohali commented on issue #2113: Publish package on ARM
URL: https://github.com/apache/couchdb/issues/2113#issuecomment-521487851
 
 
   I can take this, but won't get to it until next week.
   
   Really glad to see there's progress here! @lag-linaro will be very pleased. 
:)


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali commented on issue #1515: Improve plugin architecture / Erlang release building

2019-08-14 Thread GitBox
wohali commented on issue #1515: Improve plugin architecture / Erlang release 
building
URL: https://github.com/apache/couchdb/issues/1515#issuecomment-521487684
 
 
   @davisp what do you think? I expect this was only in here for #1516 but if 
you had other ideas, I'd at least like to see a writeup of what you want to do 
before we move it out of 3.x.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali edited a comment on issue #2115: Update default config settings (Q, max_document_size, etc.)

2019-08-14 Thread GitBox
wohali edited a comment on issue #2115: Update default config settings (Q, 
max_document_size, etc.)
URL: https://github.com/apache/couchdb/issues/2115#issuecomment-521487442
 
 
   There was significant discussion on both of these changes in other tickets 
and on the mailing list.
   
   I'm -1 until we at least review that feedback and consider the implications.
   
   I believe we got closer to q=2 or 4 on the lists than 1 or 2. Or we could be 
more intelligent and try and autopick on first run or something, based on # of 
CPU cores and nodes in the cluster, and th absence of a q= value in the local 
ini files...spitballing here.
   
   As for the max document size, I think this is actually more controversial, 
and will break anyone who has larger attachments in CouchDB today who upgrades! 
That seems to violate the principle of least surprise. See #1253 and #1200 for 
the latest on this.
   
   /cc @janl 


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali commented on issue #2115: Update default config settings (Q, max_document_size, etc.)

2019-08-14 Thread GitBox
wohali commented on issue #2115: Update default config settings (Q, 
max_document_size, etc.)
URL: https://github.com/apache/couchdb/issues/2115#issuecomment-521487442
 
 
   There was significant discussion on both of these changes in other tickets 
and on the mailing list.
   
   I'm -1 until we at least review that feedback and consider the implications.
   
   I believe we got closer to q=2 or 4 on the lists than 1 or 2. Or we could be 
more intelligent and try and autopick on first run or something, based on # of 
CPU cores and nodes in the cluster, and th absence of a q= value in the local 
ini files...spitballing here.
   
   As for the max document size, I think this is actually more controversial, 
and will break anyone who has larger attachments in CouchDB today who upgrades! 
That seems to violate the principle of least surprise. See #1253 and #1200 for 
the latest on this.
   
   #attach
   
   /cc @janl 


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali commented on a change in pull request #2114: Ensure EUnit inherits appropriate environment variables

2019-08-14 Thread GitBox
wohali commented on a change in pull request #2114: Ensure EUnit inherits 
appropriate environment variables
URL: https://github.com/apache/couchdb/pull/2114#discussion_r314151898
 
 

 ##
 File path: Makefile
 ##
 @@ -168,11 +168,11 @@ eunit: export BUILDDIR = $(shell pwd)
 eunit: export ERL_AFLAGS = -config $(shell pwd)/rel/files/eunit.config
 eunit: export COUCHDB_QUERY_SERVER_JAVASCRIPT = $(shell pwd)/bin/couchjs 
$(shell pwd)/share/server/main.js
 eunit: couch
-   @$(REBAR) setup_eunit 2> /dev/null
+   @COUCHDB_VERSION=$(COUCHDB_VERSION) COUCHDB_GIT_SHA=$(COUCHDB_GIT_SHA) 
$(REBAR) setup_eunit 2> /dev/null
 
 Review comment:
   Please make the same edit to `Makefile.win`.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] wohali commented on a change in pull request #2114: Ensure EUnit inherits appropriate environment variables

2019-08-14 Thread GitBox
wohali commented on a change in pull request #2114: Ensure EUnit inherits 
appropriate environment variables
URL: https://github.com/apache/couchdb/pull/2114#discussion_r314151791
 
 

 ##
 File path: Jenkinsfile
 ##
 @@ -529,8 +529,6 @@ pipeline {
 reprepro -b couchdb-pkg/repo includedeb jessie pkgs/jessie/*.deb
 cp js/debian-stretch/*.deb pkgs/stretch
 reprepro -b couchdb-pkg/repo includedeb stretch pkgs/stretch/*.deb
-cp js/ubuntu-trusty/*.deb pkgs/trusty
 
 Review comment:
   Yeah, we dropped the trusty builds, so this is fine.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] wohali merged pull request #152: add setuptools to dev images

2019-08-14 Thread GitBox
wohali merged pull request #152: add setuptools to dev images
URL: https://github.com/apache/couchdb-docker/pull/152
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] wohali commented on issue #152: add setuptools to dev images

2019-08-14 Thread GitBox
wohali commented on issue #152: add setuptools to dev images
URL: https://github.com/apache/couchdb-docker/pull/152#issuecomment-521483965
 
 
   Thanks!!


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] wohali commented on a change in pull request #151: allow running as arbitrary uid

2019-08-14 Thread GitBox
wohali commented on a change in pull request #151: allow running as arbitrary 
uid
URL: https://github.com/apache/couchdb-docker/pull/151#discussion_r314149332
 
 

 ##
 File path: 2.3.1/Dockerfile
 ##
 @@ -121,8 +121,13 @@ COPY docker-entrypoint.sh /usr/local/bin
 RUN ln -s usr/local/bin/docker-entrypoint.sh /docker-entrypoint.sh # backwards 
compat
 ENTRYPOINT ["tini", "--", "/docker-entrypoint.sh"]
 
-# Setup directories and permissions
-RUN find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f 
couchdb:couchdb '{}' +
 
 Review comment:
   Yeah, specifically those mounted in network file systems (NFS or slow SAN).


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] wohali commented on a change in pull request #151: allow running as arbitrary uid

2019-08-14 Thread GitBox
wohali commented on a change in pull request #151: allow running as arbitrary 
uid
URL: https://github.com/apache/couchdb-docker/pull/151#discussion_r314149281
 
 

 ##
 File path: 2.3.1/docker-entrypoint.sh
 ##
 @@ -25,36 +25,44 @@ if [ "$1" = 'couchdb' ]; then
 fi
 
 if [ "$1" = '/opt/couchdb/bin/couchdb' ]; then
-   # Check that we own everything in /opt/couchdb and fix if necessary. We 
also
-   # add the `-f` flag in all the following invocations because there may 
be
-   # cases where some of these ownership and permissions issues are 
non-fatal
-   # (e.g. a config file owned by root with o+r is actually fine), and we 
don't
-   # to be too aggressive about crashing here ...
-   find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f 
couchdb:couchdb '{}' +
+   # this is where runtime configuration changes will be written.
+   # we need to explicitly touch it here in case /opt/couchdb/etc has
+   # been mounted as an external volume, in which case it won't exist.
+   # If running as the couchdb user (i.e. container starts as root),
+   # write permissions will be granted below.
+   touch /opt/couchdb/etc/local.d/docker.ini
+
+   # if user is root, assume running under the couchdb user (default)
+   # and ensure it is able to access files and directories that may be 
mounted externally
+   if [ "$(id -u)" = '0' ]; then
+   # Check that we own everything in /opt/couchdb and fix if 
necessary. We also
+   # add the `-f` flag in all the following invocations because 
there may be
+   # cases where some of these ownership and permissions issues 
are non-fatal
+   # (e.g. a config file owned by root with o+r is actually fine), 
and we don't
+   # to be too aggressive about crashing here ...
+   find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec 
chown -f couchdb:couchdb '{}' +
 
-   # Ensure that data files have the correct permissions. We were 
previously
-   # preventing any access to these files outside of couchdb:couchdb, but 
it
-   # turns out that CouchDB itself does not set such restrictive 
permissions
-   # when it creates the files. The approach taken here ensures that the
-   # contents of the datadir have the same permissions as they had when 
they
-   # were initially created. This should minimize any startup delay.
-   find /opt/couchdb/data -type d ! -perm 0755 -exec chmod -f 0755 '{}' +
-   find /opt/couchdb/data -type f ! -perm 0644 -exec chmod -f 0644 '{}' +
+   # Ensure that data files have the correct permissions. We were 
previously
 
 Review comment:
   Oops ;) Any tabs are mistakes.
   
   The standard I've tried to keep everywhere is: 2 or 4 space indent, spaces 
only.
   
   Unless it's a Makefile, of course.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] jaydoane commented on a change in pull request #2101: Refactor fabric:cleanup_index_files

2019-08-14 Thread GitBox
jaydoane commented on a change in pull request #2101: Refactor 
fabric:cleanup_index_files
URL: https://github.com/apache/couchdb/pull/2101#discussion_r314045317
 
 

 ##
 File path: src/fabric/src/fabric.erl
 ##
 @@ -36,7 +36,8 @@
 
 % miscellany
 -export([design_docs/1, reset_validation_funs/1, cleanup_index_files/0,
-cleanup_index_files/1, cleanup_index_files_all_nodes/1, dbname/1]).
+cleanup_index_files/1, cleanup_index_files_all_nodes/1, dbname/1,
+non_active_index_files/1]).
 
 Review comment:
   I'd prefer to call this `inactive_index_files/1`


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] jaydoane commented on a change in pull request #2101: Refactor fabric:cleanup_index_files

2019-08-14 Thread GitBox
jaydoane commented on a change in pull request #2101: Refactor 
fabric:cleanup_index_files
URL: https://github.com/apache/couchdb/pull/2101#discussion_r314047597
 
 

 ##
 File path: src/fabric/src/fabric.erl
 ##
 @@ -503,26 +504,29 @@ cleanup_index_files() ->
 %% @doc clean up index files for a specific db
 -spec cleanup_index_files(dbname()) -> ok.
 cleanup_index_files(DbName) ->
+[file:delete(File) || File <- non_active_index_files(DbName)],
 
 Review comment:
   I generally prefer `lists:foreach` when I don't care about the value, and in 
this case, we're just throwing away the result of the list comprehension. On a 
related note, should we check the result of `file:delete` here? EDIT: Oh, I see 
you just copied the existing code, but I still wonder if it shouldn't be 
improved?


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] willholley commented on issue #151: allow running as arbitrary uid

2019-08-14 Thread GitBox
willholley commented on issue #151: allow running as arbitrary uid
URL: https://github.com/apache/couchdb-docker/pull/151#issuecomment-521391782
 
 
   > Hey @willholley , will review this later today. Looks like `dev` is 
failing for other reasons, making Travis fail. Do you have time to lend a hand?
   
   hopefully this is fixed in #152 


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] willholley opened a new pull request #152: add setuptools to dev images

2019-08-14 Thread GitBox
willholley opened a new pull request #152: add setuptools to dev images
URL: https://github.com/apache/couchdb-docker/pull/152
 
 
   
   
   ## Overview
   
   Fixes the `dev` containers which were missing `setuptools` (perhaps lots in 
the transition to python 3).
   
   ## Testing recommendations
   
   ```
   docker build -t couchdb:dev dev
   docker build -t couchdb:dev dev-cluster
   ```
   
   ## Checklist
   
   - [ ] Code is written and works correctly;
   - [ ] Changes are covered by tests;
   - [ ] Documentation reflects the changes;
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[Jenkins] FAILURE: CouchDB » jenkins-cpse-debugging #20

2019-08-14 Thread Apache Jenkins Server
Boo, we failed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/20/display/redirect

[GitHub] [couchdb] rnewson commented on issue #2115: Update default config settings (Q, max_document_size, etc.)

2019-08-14 Thread GitBox
rnewson commented on issue #2115: Update default config settings (Q, 
max_document_size, etc.)
URL: https://github.com/apache/couchdb/issues/2115#issuecomment-521370867
 
 
   +1 on lowering max_document_size to 1MB.
   
   default q is more controversial. How well is the shard splitting working? If 
it's seamless (no interruption to reads or writes) and efficient, then lowering 
to 2 is ok by me (I'd not be keen on 1). That said, q vanishes entirely in 4.0 
and we've lived with this default for a long time. Is it worth changing at this 
late stage?


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk commented on issue #2114: Ensure EUnit inherits appropriate environment variables

2019-08-14 Thread GitBox
kocolosk commented on issue #2114: Ensure EUnit inherits appropriate 
environment variables
URL: https://github.com/apache/couchdb/pull/2114#issuecomment-521369957
 
 
   I'm being sloppy again and using this branch for whack-a-mole timeout 
extensions where needed. I can move those elsewhere if folks want to keep the 
PR clean.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[Jenkins] FAILURE: CouchDB » jenkins-cpse-debugging #19

2019-08-14 Thread Apache Jenkins Server
Boo, we failed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/19/display/redirect

[GitHub] [couchdb] kocolosk opened a new issue #2115: Update default config settings (Q, max_document_size, etc.)

2019-08-14 Thread GitBox
kocolosk opened a new issue #2115: Update default config settings (Q, 
max_document_size, etc.)
URL: https://github.com/apache/couchdb/issues/2115
 
 
   I would like to take the opportunity to revisit a few default configuration 
settings for 3.0 deployments:
   
   `cluster.q` (currently 8) - we have had mailing list threads about this is 
too large for many deployments. The introduction of shard splitting gives us 
more flexibility to add shards to a database after the fact. I'd suggest 
setting this to 1 or 2 as a default.
   
   `couchdb.max_document_size` - the current default of 4GB is quite insane. 
The view engine already cannot handle anything much larger than ~10MB without a 
lot of tweaking. Moreover, 4.0 is going to force our hand on making documents 
smaller. I'd suggest we lower this default to 1MB.
   
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk commented on issue #1517: Automate incrementally growing a cluster

2019-08-14 Thread GitBox
kocolosk commented on issue #1517: Automate incrementally growing a cluster
URL: https://github.com/apache/couchdb/issues/1517#issuecomment-521342651
 
 
   It would be great to have full shard rebalancing across nodes in 3.0, but I 
don't think the timelines are going to work out.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk commented on issue #1515: Improve plugin architecture / Erlang release building

2019-08-14 Thread GitBox
kocolosk commented on issue #1515: Improve plugin architecture / Erlang release 
building
URL: https://github.com/apache/couchdb/issues/1515#issuecomment-521342068
 
 
   I don't think this belongs in 3.x. We closed #1516 by way of #2037, and I 
don't think anyone is signing up to better integrate Geospatial ahead of 3.0.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk opened a new pull request #2114: Ensure EUnit inherits appropriate environment variables

2019-08-14 Thread GitBox
kocolosk opened a new pull request #2114: Ensure EUnit inherits appropriate 
environment variables
URL: https://github.com/apache/couchdb/pull/2114
 
 
   
   
   ## Overview
   
   Omitting COUCHDB_VERSION caused the EUnit build of the replicator to have a 
corrupted User-Agent header. It tried to construct a version using git, but 
when building from a release tarball there is no git repo so the UA had a git 
error message in it. This error message contained a newline, which plausibly 
confused some part of the HTTP stack and caused replicator HTTP requests to 
hang.
   
   The second commit removes the attempt to publish packages for Ubuntu 14.04, 
as we're no longer building them for that (EOL) platform.
   
   ## Testing recommendations
   
   See 
https://builds.apache.org/blue/organizations/jenkins/CouchDB/detail/jenkins-cpse-debugging/18/pipeline/,
 which is building this branch before my cleanup rebase (the final diff from 
master is identical).
   
   The specific test that was quite regularly failing without this patch is 
`cpse_purge_http_replication`.
   
   
   
   ## Checklist
   
   - [x] Code is written and works correctly
   - [x] Changes are covered by tests
   - [ ] Any new configurable parameters are documented in 
`rel/overlay/etc/default.ini`
   - [ ] A PR for documentation changes has been made in 
https://github.com/apache/couchdb-documentation
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[Jenkins] FAILURE: CouchDB » jenkins-cpse-debugging #18

2019-08-14 Thread Apache Jenkins Server
Boo, we failed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/18/display/redirect

[GitHub] [couchdb-docker] kocolosk commented on a change in pull request #151: allow running as arbitrary uid

2019-08-14 Thread GitBox
kocolosk commented on a change in pull request #151: allow running as arbitrary 
uid
URL: https://github.com/apache/couchdb-docker/pull/151#discussion_r313983930
 
 

 ##
 File path: 2.3.1/Dockerfile
 ##
 @@ -121,8 +121,13 @@ COPY docker-entrypoint.sh /usr/local/bin
 RUN ln -s usr/local/bin/docker-entrypoint.sh /docker-entrypoint.sh # backwards 
compat
 ENTRYPOINT ["tini", "--", "/docker-entrypoint.sh"]
 
-# Setup directories and permissions
-RUN find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f 
couchdb:couchdb '{}' +
 
 Review comment:
   I couldn't repro the original issue myself, either. I think it mostly showed 
up when running with relatively slow PVs underneath.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk commented on issue #2091: HTTP Request TimeOut errors for Elixir tests in CouchDB test suite

2019-08-14 Thread GitBox
kocolosk commented on issue #2091: HTTP Request TimeOut errors for Elixir tests 
in CouchDB test suite
URL: https://github.com/apache/couchdb/issues/2091#issuecomment-521332020
 
 
   @sarveshtamba Are you up-to-date on master? I think 
608caaf12904effc104fc86a8525eb51425e2311 fixed those `ReshardAllDocsTest` 
timeouts for me (specifically by also raising the `inactivity_timeout` beyond 
the default of 10 seconds)


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk commented on issue #2099: CompactTest fails while executing CouchDB elixir test suite.

2019-08-14 Thread GitBox
kocolosk commented on issue #2099: CompactTest fails while executing CouchDB 
elixir test suite.
URL: https://github.com/apache/couchdb/issues/2099#issuecomment-521330942
 
 
   Hard to say without any additional details like database log files. I don't 
think I've ever seen that one fail like that on our CI system yet so I don't 
have any other context to go on.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] kocolosk opened a new issue #2113: Publish package on ARM

2019-08-14 Thread GitBox
kocolosk opened a new issue #2113: Publish package on ARM
URL: https://github.com/apache/couchdb/issues/2113
 
 
   # Summary
   
   We're building packages for ARM now but we're not publishing them to 
`repo-nightly.apache.org` like the others. See
   
   https://github.com/apache/couchdb/blob/master/Jenkinsfile#L525-L538
   
   and 
   
   https://github.com/apache/couchdb/blob/master/Jenkinsfile#L454
   
   I don't know much about building Debian repos so not sure where to drop the 
`aarch64-debian-stretch` .debs so the `reprepro` commands pick them up 
appropriately. /cc @wohali 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] nickva merged pull request #2111: Fix replication rescheduling Running < MaxJobs corner case

2019-08-14 Thread GitBox
nickva merged pull request #2111: Fix replication rescheduling Running < 
MaxJobs corner case
URL: https://github.com/apache/couchdb/pull/2111
 
 
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[Jenkins] SUCCESS: CouchDB » jenkins-cpse-debugging #17

2019-08-14 Thread Apache Jenkins Server
Yay, we passed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/17/display/redirect

[GitHub] [couchdb] nickva commented on a change in pull request #2111: Fix replication rescheduling Running < MaxJobs corner case

2019-08-14 Thread GitBox
nickva commented on a change in pull request #2111: Fix replication 
rescheduling Running < MaxJobs corner case
URL: https://github.com/apache/couchdb/pull/2111#discussion_r313893671
 
 

 ##
 File path: src/couch_replicator/src/couch_replicator_scheduler.erl
 ##
 @@ -723,49 +726,45 @@ reset_job_process(#job{} = Job) ->
 
 -spec reschedule(#state{}) -> ok.
 reschedule(State) ->
-Running = running_job_count(),
-Pending = pending_job_count(),
-stop_excess_jobs(State, Running),
-start_pending_jobs(State, Running, Pending),
-rotate_jobs(State, Running, Pending),
-update_running_jobs_stats(State#state.stats_pid),
-ok.
+StopCount = stop_excess_jobs(State, running_job_count()),
+rotate_jobs(State, StopCount),
+update_running_jobs_stats(State#state.stats_pid).
 
 
--spec stop_excess_jobs(#state{}, non_neg_integer()) -> ok.
+-spec stop_excess_jobs(#state{}, non_neg_integer()) -> non_neg_integer().
 stop_excess_jobs(State, Running) ->
 #state{max_jobs=MaxJobs} = State,
-StopCount = Running - MaxJobs,
-if StopCount =< 0 -> ok; true ->
-Stopped = stop_jobs(StopCount, true, State),
-OneshotLeft = StopCount - Stopped,
-if OneshotLeft =< 0 -> ok; true ->
-stop_jobs(OneshotLeft, false, State),
-ok
-end
-end.
+StopCount = max(0, Running - MaxJobs),
+Stopped = stop_jobs(StopCount, true, State),
+OneshotLeft = StopCount - Stopped,
 
 Review comment:
   I'll update to make stop_jobs handle negative values.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[Jenkins] FAILURE: CouchDB » jenkins-cpse-debugging #16

2019-08-14 Thread Apache Jenkins Server
Boo, we failed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/16/display/redirect

[Jenkins] FAILURE: CouchDB » jenkins-cpse-debugging #15

2019-08-14 Thread Apache Jenkins Server
Boo, we failed. 
https://builds.apache.org/job/CouchDB/job/jenkins-cpse-debugging/15/display/redirect

[GitHub] [couchdb] iilyak commented on a change in pull request #2111: Fix replication rescheduling Running < MaxJobs corner case

2019-08-14 Thread GitBox
iilyak commented on a change in pull request #2111: Fix replication 
rescheduling Running < MaxJobs corner case
URL: https://github.com/apache/couchdb/pull/2111#discussion_r313810037
 
 

 ##
 File path: src/couch_replicator/src/couch_replicator_scheduler.erl
 ##
 @@ -723,49 +726,45 @@ reset_job_process(#job{} = Job) ->
 
 -spec reschedule(#state{}) -> ok.
 reschedule(State) ->
-Running = running_job_count(),
-Pending = pending_job_count(),
-stop_excess_jobs(State, Running),
-start_pending_jobs(State, Running, Pending),
-rotate_jobs(State, Running, Pending),
-update_running_jobs_stats(State#state.stats_pid),
-ok.
+StopCount = stop_excess_jobs(State, running_job_count()),
+rotate_jobs(State, StopCount),
+update_running_jobs_stats(State#state.stats_pid).
 
 
--spec stop_excess_jobs(#state{}, non_neg_integer()) -> ok.
+-spec stop_excess_jobs(#state{}, non_neg_integer()) -> non_neg_integer().
 stop_excess_jobs(State, Running) ->
 #state{max_jobs=MaxJobs} = State,
-StopCount = Running - MaxJobs,
-if StopCount =< 0 -> ok; true ->
-Stopped = stop_jobs(StopCount, true, State),
-OneshotLeft = StopCount - Stopped,
-if OneshotLeft =< 0 -> ok; true ->
-stop_jobs(OneshotLeft, false, State),
-ok
-end
-end.
+StopCount = max(0, Running - MaxJobs),
+Stopped = stop_jobs(StopCount, true, State),
+OneshotLeft = StopCount - Stopped,
 
 Review comment:
   I think we should either change this line to `max(0, StopCount - Stopped)` 
or update stop_jobs to handle (return 0) negative values. 


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] willholley commented on a change in pull request #151: allow running as arbitrary uid

2019-08-14 Thread GitBox
willholley commented on a change in pull request #151: allow running as 
arbitrary uid
URL: https://github.com/apache/couchdb-docker/pull/151#discussion_r313784293
 
 

 ##
 File path: 2.3.1/docker-entrypoint.sh
 ##
 @@ -25,36 +25,44 @@ if [ "$1" = 'couchdb' ]; then
 fi
 
 if [ "$1" = '/opt/couchdb/bin/couchdb' ]; then
-   # Check that we own everything in /opt/couchdb and fix if necessary. We 
also
-   # add the `-f` flag in all the following invocations because there may 
be
-   # cases where some of these ownership and permissions issues are 
non-fatal
-   # (e.g. a config file owned by root with o+r is actually fine), and we 
don't
-   # to be too aggressive about crashing here ...
-   find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f 
couchdb:couchdb '{}' +
+   # this is where runtime configuration changes will be written.
+   # we need to explicitly touch it here in case /opt/couchdb/etc has
+   # been mounted as an external volume, in which case it won't exist.
+   # If running as the couchdb user (i.e. container starts as root),
+   # write permissions will be granted below.
+   touch /opt/couchdb/etc/local.d/docker.ini
+
+   # if user is root, assume running under the couchdb user (default)
+   # and ensure it is able to access files and directories that may be 
mounted externally
+   if [ "$(id -u)" = '0' ]; then
+   # Check that we own everything in /opt/couchdb and fix if 
necessary. We also
+   # add the `-f` flag in all the following invocations because 
there may be
+   # cases where some of these ownership and permissions issues 
are non-fatal
+   # (e.g. a config file owned by root with o+r is actually fine), 
and we don't
+   # to be too aggressive about crashing here ...
+   find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec 
chown -f couchdb:couchdb '{}' +
 
-   # Ensure that data files have the correct permissions. We were 
previously
-   # preventing any access to these files outside of couchdb:couchdb, but 
it
-   # turns out that CouchDB itself does not set such restrictive 
permissions
-   # when it creates the files. The approach taken here ensures that the
-   # contents of the datadir have the same permissions as they had when 
they
-   # were initially created. This should minimize any startup delay.
-   find /opt/couchdb/data -type d ! -perm 0755 -exec chmod -f 0755 '{}' +
-   find /opt/couchdb/data -type f ! -perm 0644 -exec chmod -f 0644 '{}' +
+   # Ensure that data files have the correct permissions. We were 
previously
 
 Review comment:
   the existing Dockerfile uses a mix of tabs and spaces - what's the preferred 
option? :)


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb-docker] willholley commented on a change in pull request #151: allow running as arbitrary uid

2019-08-14 Thread GitBox
willholley commented on a change in pull request #151: allow running as 
arbitrary uid
URL: https://github.com/apache/couchdb-docker/pull/151#discussion_r313782460
 
 

 ##
 File path: 2.3.1/Dockerfile
 ##
 @@ -121,8 +121,13 @@ COPY docker-entrypoint.sh /usr/local/bin
 RUN ln -s usr/local/bin/docker-entrypoint.sh /docker-entrypoint.sh # backwards 
compat
 ENTRYPOINT ["tini", "--", "/docker-entrypoint.sh"]
 
-# Setup directories and permissions
-RUN find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f 
couchdb:couchdb '{}' +
 
 Review comment:
   I didn't notice any issue with startup times when testing but have added 
this line back for consistency.


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] lag-linaro commented on issue #2030: eunit test timedout errors during jenkins CI

2019-08-14 Thread GitBox
lag-linaro commented on issue #2030: eunit test timedout errors during jenkins 
CI 
URL: https://github.com/apache/couchdb/issues/2030#issuecomment-521143824
 
 
   Have you tried reaching out to WorksOnArm?


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] [couchdb] sarveshtamba commented on issue #2099: CompactTest fails while executing CouchDB elixir test suite.

2019-08-14 Thread GitBox
sarveshtamba commented on issue #2099: CompactTest fails while executing 
CouchDB elixir test suite.
URL: https://github.com/apache/couchdb/issues/2099#issuecomment-521138808
 
 
   @wohali @kocolosk any inputs on this one?


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services