You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "Wojtek Piaseczny (JIRA)" <ji...@apache.org> on 2008/08/29 23:43:44 UTC

[jira] Created: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Unable to create dynamic fields with custom DataImportHandler transformer
-------------------------------------------------------------------------

                 Key: SOLR-742
                 URL: https://issues.apache.org/jira/browse/SOLR-742
             Project: Solr
          Issue Type: Bug
          Components: contrib - DataImportHandler
    Affects Versions: 1.3
            Reporter: Wojtek Piaseczny
             Fix For: 1.3


Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html

Dynamic fields aren't created when specified in a DataImportHandler's transformer. 

Reproducing the issue:
I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.

Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12643747#action_12643747 ] 

Shalin Shekhar Mangar commented on SOLR-742:
--------------------------------------------

Committed revision 709088.

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Wojtek Piaseczny (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12628138#action_12628138 ] 

Wojtek Piaseczny commented on SOLR-742:
---------------------------------------

That fixed my issue, thank you!

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Noble Paul (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Noble Paul updated SOLR-742:
----------------------------

    Attachment: SOLR-742.patch

the old patch was wrong

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar updated SOLR-742:
---------------------------------------

    Attachment: SOLR-742.patch

The last patch had a bug with handling nested entities.

This patch simplifies the logic by iterating over the map instead of the Fields defined in data config. Also, the overhead of creating a lowercase-key map per row is removed.

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Noble Paul (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Noble Paul updated SOLR-742:
----------------------------

    Attachment: SOLR-742.patch

dynamic fields are added if they are present in the doc

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar updated SOLR-742:
---------------------------------------

    Attachment: SOLR-742.patch

We also need to keep a lowercase map of schema fields. The only caveat is that dynamic fields which are added by the transformers must be in the correct case as defined in schema.xml

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Noble Paul (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Noble Paul updated SOLR-742:
----------------------------

    Attachment: SOLR-742.patch

simplified fix

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar resolved SOLR-742.
----------------------------------------

    Resolution: Fixed

Committed revision 708967.

Thanks Wojtek and Noble!

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar updated SOLR-742:
---------------------------------------

    Attachment: SOLR-742.patch

# Fixes a NPE when the rootEntity is null
# Added a test in TestDocBuilder2

I'll commit this shortly.

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch, SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Wojtek Piaseczny (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Wojtek Piaseczny updated SOLR-742:
----------------------------------

    Fix Version/s:     (was: 1.3)
                   1.4

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>             Fix For: 1.4
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shalin Shekhar Mangar reassigned SOLR-742:
------------------------------------------

    Assignee: Shalin Shekhar Mangar

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-742) Unable to create dynamic fields with custom DataImportHandler transformer

Posted by "Shalin Shekhar Mangar (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12630274#action_12630274 ] 

Shalin Shekhar Mangar commented on SOLR-742:
--------------------------------------------

The current DataImportHandler code does not handle dynamic fields. This patch solves the core problem partially by allowing Transformers to add a dynamic field/value pair to the document. Ideally, we'd like to support variables in the 'name' attribute as well.

Once 1.3 is release, we should look at adding complete support for dynamic fields.

> Unable to create dynamic fields with custom DataImportHandler transformer
> -------------------------------------------------------------------------
>
>                 Key: SOLR-742
>                 URL: https://issues.apache.org/jira/browse/SOLR-742
>             Project: Solr
>          Issue Type: Bug
>          Components: contrib - DataImportHandler
>    Affects Versions: 1.3
>            Reporter: Wojtek Piaseczny
>             Fix For: 1.4
>
>         Attachments: SOLR-742.patch, SOLR-742.patch
>
>
> Discussion at: http://www.nabble.com/Creating-dynamic-fields-with-DataImportHandler-to19226532.html
> Dynamic fields aren't created when specified in a DataImportHandler's transformer. 
> Reproducing the issue:
> I have defined a dynamic field (of type sdouble) in my schema called "_dynamic*". Inside the transformer's transformRow method, I am adding the name-value pair "_dynamicTest" and '1.0'. No errors are observed, but the data does not appear in the index after importing is complete.
> Interestingly, I can specify that same name-value pair combination in the DataImportHandler's config file, and it does appear in the index.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.